/*
Theme Name: Flavor Pet
Theme URI: https://paw-wisdom.com
Description: Premium standalone pet blog theme with AdSense zones
Version: 1.0.0
Author: Paw Wisdom
Text Domain: flavor-pet
Requires at least: 6.0
Requires PHP: 8.0
License: GNU General Public License v2 or later
*/

/* ============================================
   CSS VARIABLES
   ============================================ */
:root {
  --f-green: #2D8F4E;
  --f-green-dark: #1a6b35;
  --f-green-light: #e8f5ec;
  --f-cream: #faf7f2;
  --f-cream-alt: #f5f0e8;
  --f-dark: #1a1a2e;
  --f-dark-soft: #2c2c44;
  --f-gray: #6b7280;
  --f-gray-light: #e5e7eb;
  --f-coral: #ff6b6b;
  --f-white: #ffffff;
  --f-font: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --f-font-head: 'Nunito', -apple-system, BlinkMacSystemFont, sans-serif;
  --f-radius: 16px;
  --f-radius-sm: 10px;
  --f-shadow: 0 2px 8px rgba(0,0,0,0.06);
  --f-shadow-hover: 0 8px 30px rgba(0,0,0,0.12);
  --f-transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --f-max-width: 1200px;
  --f-content-width: 720px;
}

/* ============================================
   RESET & BASE
   ============================================ */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-font-smoothing: antialiased; }

body {
  font-family: var(--f-font);
  font-size: 1rem;
  line-height: 1.7;
  color: var(--f-dark);
  background: var(--f-cream);
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--f-green); text-decoration: none; transition: color var(--f-transition); }
a:hover { color: var(--f-green-dark); }

/* ============================================
   HEADER
   ============================================ */
.f-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: rgba(255,255,255,0.92);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid rgba(0,0,0,0.06);
  transition: box-shadow var(--f-transition);
}
.f-header.scrolled { box-shadow: 0 2px 20px rgba(0,0,0,0.08); }

.f-header-inner {
  max-width: var(--f-max-width);
  margin: 0 auto;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  height: 64px;
}
.f-header-inner::after {
  content: '';
}

.f-logo {
  font-family: var(--f-font-head);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--f-dark);
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
}
.f-logo:hover { color: var(--f-green); }
.f-logo-icon {
  width: 36px;
  height: 36px;
  background: var(--f-green);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  color: white;
  flex-shrink: 0;
}

.f-nav { display: flex; align-items: center; gap: 0; }
.f-nav a {
  padding: 0.5rem 1.25rem;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--f-gray);
  border-radius: 50px;
  transition: all var(--f-transition);
  text-decoration: none;
}
.f-nav a:hover, .f-nav a.active {
  color: var(--f-green);
  background: var(--f-green-light);
}

.f-hamburger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  width: 32px;
  height: 24px;
  flex-direction: column;
  justify-content: space-between;
}
.f-hamburger span {
  display: block;
  width: 100%;
  height: 2.5px;
  background: var(--f-dark);
  border-radius: 2px;
  transition: all var(--f-transition);
}

/* ============================================
   HERO (HOMEPAGE)
   ============================================ */
.f-hero {
  max-width: var(--f-max-width);
  margin: 2rem auto;
  padding: 0 2rem;
}
.f-hero-card {
  display: grid;
  grid-template-columns: 1fr 1fr;
  background: var(--f-white);
  border-radius: var(--f-radius);
  overflow: hidden;
  box-shadow: var(--f-shadow);
  transition: all var(--f-transition);
  text-decoration: none;
  color: inherit;
}
.f-hero-card:hover {
  box-shadow: var(--f-shadow-hover);
  transform: translateY(-2px);
  color: inherit;
}
.f-hero-img {
  width: 100%;
  height: 380px;
  object-fit: cover;
}
.f-hero-body {
  padding: 2.5rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 1rem;
}
.f-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.3rem 1rem;
  background: var(--f-green);
  color: white;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  border-radius: 50px;
  width: fit-content;
}
.f-badge-sm { font-size: 0.7rem; padding: 0.2rem 0.75rem; }
.f-hero-title {
  font-family: var(--f-font-head);
  font-size: 1.75rem;
  font-weight: 800;
  line-height: 1.25;
  color: var(--f-dark);
}
.f-hero-excerpt {
  color: var(--f-gray);
  font-size: 0.95rem;
  line-height: 1.6;
}
.f-hero-meta {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 0.85rem;
  color: var(--f-gray);
}

/* ============================================
   ARTICLE GRID
   ============================================ */
.f-section-title {
  max-width: var(--f-max-width);
  margin: 3rem auto 1.5rem;
  padding: 0 2rem;
  font-family: var(--f-font-head);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--f-dark);
}

.f-grid {
  max-width: var(--f-max-width);
  margin: 0 auto 3rem;
  padding: 0 2rem;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.5rem;
}

.f-card {
  background: var(--f-white);
  border-radius: var(--f-radius);
  overflow: hidden;
  box-shadow: var(--f-shadow);
  transition: all var(--f-transition);
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
}
.f-card:hover {
  box-shadow: var(--f-shadow-hover);
  transform: translateY(-4px);
  color: inherit;
}
.f-card-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.f-card-body {
  padding: 1.25rem 1.5rem 1.5rem;
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  flex: 1;
}
.f-card-title {
  font-family: var(--f-font-head);
  font-size: 1.05rem;
  font-weight: 700;
  line-height: 1.35;
  color: var(--f-dark);
}
.f-card-excerpt {
  font-size: 0.875rem;
  color: var(--f-gray);
  line-height: 1.55;
  flex: 1;
}
.f-card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.8rem;
  color: var(--f-gray);
  padding-top: 0.75rem;
  border-top: 1px solid var(--f-gray-light);
  margin-top: auto;
}

/* ============================================
   SINGLE ARTICLE HERO
   ============================================ */
.f-article-hero {
  position: relative;
  height: 480px;
  overflow: hidden;
  display: flex;
  align-items: flex-end;
}
.f-article-hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.f-article-hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.2) 50%, rgba(0,0,0,0.05) 100%);
}
.f-article-hero-content {
  position: relative;
  z-index: 2;
  max-width: var(--f-max-width);
  margin: 0 auto;
  padding: 3rem 2rem;
  width: 100%;
  color: white;
  text-align: center;
}
.f-article-hero-content .f-badge { margin: 0 auto 1rem; }
.f-article-hero-content h1 {
  font-family: var(--f-font-head);
  font-size: 2.5rem;
  font-weight: 800;
  line-height: 1.2;
  max-width: 800px;
  margin: 0 auto;
  text-shadow: 0 2px 8px rgba(0,0,0,0.3);
}
.f-article-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-top: 1rem;
  font-size: 0.9rem;
  opacity: 0.9;
}
.f-article-meta-sep { opacity: 0.5; }

/* Article content */
.f-article-content {
  max-width: var(--f-content-width);
  margin: 0 auto;
  padding: 2.5rem 2rem 4rem;
}

.f-breadcrumbs {
  font-size: 0.85rem;
  color: var(--f-gray);
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--f-gray-light);
}
.f-breadcrumbs a { color: var(--f-green); }

.f-article-content h2 {
  font-family: var(--f-font-head);
  font-size: 1.6rem;
  font-weight: 800;
  margin: 2.5rem 0 1rem;
  padding-top: 1.5rem;
  color: var(--f-dark);
  border-top: 2px solid var(--f-green-light);
}
.f-article-content h2:first-of-type { border-top: none; padding-top: 0; }

.f-article-content h3 {
  font-family: var(--f-font-head);
  font-size: 1.25rem;
  font-weight: 700;
  margin: 2rem 0 0.75rem;
  color: var(--f-dark-soft);
}

.f-article-content p { margin-bottom: 1.25rem; }

.f-article-content ul, .f-article-content ol {
  margin: 1rem 0 1.5rem;
  padding-left: 1.5rem;
}
.f-article-content li { margin-bottom: 0.5rem; }

.f-article-content blockquote {
  margin: 2rem 0;
  padding: 1.5rem 2rem;
  background: var(--f-green-light);
  border-left: 4px solid var(--f-green);
  border-radius: 0 var(--f-radius-sm) var(--f-radius-sm) 0;
  font-style: italic;
  color: var(--f-dark-soft);
}

.f-article-content strong { color: var(--f-dark); }

/* Section break */
.f-section-break {
  text-align: center;
  margin: 2.5rem 0;
  font-size: 1.5rem;
  opacity: 0.3;
  letter-spacing: 1rem;
}

/* Ad zone */
.f-ad-zone {
  background: var(--f-cream-alt);
  border: 2px dashed var(--f-gray-light);
  border-radius: var(--f-radius-sm);
  padding: 1.5rem;
  text-align: center;
  margin: 2rem 0;
  min-height: 90px;
}

/* Author box */
.f-author-box {
  display: flex;
  gap: 1.5rem;
  padding: 2rem;
  background: var(--f-white);
  border-radius: var(--f-radius);
  box-shadow: var(--f-shadow);
  margin: 3rem 0 2rem;
  align-items: center;
}
.f-author-avatar img {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  object-fit: cover;
}
.f-author-label {
  font-size: 0.8rem;
  color: var(--f-gray);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 600;
}
.f-author-name {
  font-family: var(--f-font-head);
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0.25rem 0;
}
.f-author-bio {
  font-size: 0.9rem;
  color: var(--f-gray);
  margin: 0;
}

/* Related posts */
.f-related {
  max-width: var(--f-max-width);
  margin: 0 auto 4rem;
  padding: 3rem 2rem 0;
}
.f-related > h3 {
  font-family: var(--f-font-head);
  font-size: 1.5rem;
  font-weight: 800;
  margin-bottom: 1.5rem;
  text-align: center;
}

/* ============================================
   FOOTER
   ============================================ */
.f-footer {
  background: var(--f-dark);
  color: rgba(255,255,255,0.7);
  padding: 3rem 2rem 2rem;
}
.f-footer-inner {
  max-width: var(--f-max-width);
  margin: 0 auto;
  text-align: center;
}
.f-footer-brand {
  font-family: var(--f-font-head);
  font-size: 1.5rem;
  font-weight: 800;
  color: white;
  margin-bottom: 0.5rem;
}
.f-footer-tagline { font-size: 0.9rem; margin-bottom: 1.5rem; opacity: 0.7; }
.f-footer-links {
  display: flex;
  justify-content: center;
  gap: 1.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}
.f-footer-links a {
  color: rgba(255,255,255,0.7);
  font-size: 0.9rem;
  transition: color var(--f-transition);
  text-decoration: none;
}
.f-footer-links a:hover { color: white; }
.f-footer-copy {
  font-size: 0.8rem;
  opacity: 0.5;
  padding-top: 1rem;
  border-top: 1px solid rgba(255,255,255,0.1);
}
.f-footer-disclosure {
  font-size: 0.75rem;
  opacity: 0.4;
  margin-top: 0.75rem;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ============================================
   PAGINATION
   ============================================ */
.f-pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.5rem;
  padding: 2rem;
  max-width: var(--f-max-width);
  margin: 0 auto;
}
.f-pagination a, .f-pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  height: 40px;
  padding: 0 0.75rem;
  border-radius: 10px;
  font-size: 0.9rem;
  font-weight: 600;
  transition: all var(--f-transition);
}
.f-pagination a {
  background: var(--f-white);
  color: var(--f-gray);
  box-shadow: var(--f-shadow);
  text-decoration: none;
}
.f-pagination a:hover {
  background: var(--f-green);
  color: white;
  transform: translateY(-1px);
}
.f-pagination .current {
  background: var(--f-green);
  color: white;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
  .f-header-inner { padding: 0 1rem; }
  .f-nav { display: none; }
  .f-hamburger { display: flex; }
  .f-header.menu-open .f-nav {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    background: white;
    padding: 1rem;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1);
    gap: 0.25rem;
  }
  .f-hero { padding: 0 1rem; margin: 1rem auto; }
  .f-hero-card { grid-template-columns: 1fr; }
  .f-hero-img { height: 220px; }
  .f-hero-body { padding: 1.5rem; }
  .f-hero-title { font-size: 1.35rem; }
  .f-grid { grid-template-columns: 1fr; gap: 1rem; padding: 0 1rem; }
  .f-section-title { padding: 0 1rem; }
  .f-article-hero { height: 320px; }
  .f-article-hero-content h1 { font-size: 1.75rem; }
  .f-article-content { padding: 1.5rem 1rem 3rem; }
  .f-author-box { flex-direction: column; text-align: center; }
  .f-related { padding: 2rem 1rem 0; }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .f-grid { grid-template-columns: repeat(2, 1fr); }
}

/* ============================================
   ANIMATIONS
   ============================================ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
.f-card { animation: fadeInUp 0.5s ease-out both; }
.f-card:nth-child(2) { animation-delay: 0.1s; }
.f-card:nth-child(3) { animation-delay: 0.2s; }
.f-card:nth-child(4) { animation-delay: 0.3s; }
.f-card:nth-child(5) { animation-delay: 0.4s; }
.f-card:nth-child(6) { animation-delay: 0.5s; }

/* Reading progress bar */
.f-progress {
  position: fixed;
  top: 64px;
  left: 0;
  width: 0%;
  height: 3px;
  background: linear-gradient(90deg, var(--f-green), var(--f-coral));
  z-index: 999;
  transition: width 0.1s linear;
}
