/*
Theme Name: Petros Premium
Theme URI: https://petrosecom.com/
Author: Antigravity
Author URI: https://deepmind.google/
Description: A premium, highly professional custom theme designed for Petros Ecommerce and BestBuys Seafood Market.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: petros-premium
*/

/* ==========================================================================
   CSS VARIABLES & DESIGN SYSTEM
   ========================================================================== */
:root {
  --primary: #0b192c;          /* Deep Midnight Oceanic Blue */
  --secondary: #1e3e62;        /* Deep Sea Blue */
  --accent: #008dca;           /* Fresh Water Cyan / Ice Blue */
  --accent-rgb: 0, 141, 202;
  --success: #10b981;          /* Organic Emerald Green */
  --success-rgb: 16, 185, 129;
  
  --bg-light: #f8fafc;         /* Soft Off-White */
  --bg-card: #ffffff;          /* Pure White */
  --border-color: #e2e8f0;     /* Border gray */
  
  --text-dark: #0f172a;        /* Deep Slate for Body */
  --text-medium: #475569;      /* Medium Slate for description */
  --text-muted: #94a3b8;       /* Muted Slate */
  --text-light: #f8fafc;       /* Light text */
  
  --glass-bg: rgba(255, 255, 255, 0.85);
  --glass-border: rgba(255, 255, 255, 0.4);
  --glass-shadow: 0 8px 32px 0 rgba(15, 23, 42, 0.06);
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 12px 24px -10px rgba(15, 23, 42, 0.08);
  --shadow-lg: 0 20px 40px -15px rgba(15, 23, 42, 0.12);
  
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 24px;
  --radius-full: 9999px;
  
  --font-sans: 'Inter', system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-title: 'Outfit', var(--font-sans);
  
  --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  --container-width: 1200px;
}

/* ==========================================================================
   CSS RESET & BASE STYLES
   ========================================================================== */
*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-dark);
  background-color: var(--bg-light);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden; /* Avoid side scrolling on mobile */
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-title);
  color: var(--primary);
  font-weight: 700;
  line-height: 1.25;
  margin-top: 0;
}

/* Fluid Typography */
h1 { font-size: clamp(2.25rem, 5vw, 2.75rem); }
h2 { font-size: clamp(1.85rem, 4vw, 2.25rem); }
h3 { font-size: clamp(1.35rem, 3vw, 1.75rem); }
h4 { font-size: 1.25rem; }

a {
  color: var(--accent);
  text-decoration: none;
  transition: var(--transition);
}

a:hover {
  color: var(--primary);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

p {
  margin-bottom: 1.5rem;
}

ul, ol {
  margin-bottom: 1.5rem;
}

/* ==========================================================================
   LAYOUT STRUCTURE
   ========================================================================== */
.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 1.25rem;
}

.section-padding {
  padding: clamp(3rem, 6vw, 6rem) 0;
}

/* Grids */
.grid {
  display: grid;
  gap: 1.5rem;
}

.grid-2, .grid-3, .grid-4 {
  grid-template-columns: 1fr;
}

@media (min-width: 576px) {
  .grid-2 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 768px) {
  .grid { gap: 2rem; }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
}

@media (min-width: 1024px) {
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 2rem;
  font-family: var(--font-title);
  font-weight: 600;
  border-radius: var(--radius-full);
  transition: var(--transition);
  cursor: pointer;
  border: 2px solid transparent;
  font-size: 0.95rem;
  text-align: center;
}

.btn-primary {
  background-color: var(--accent);
  color: var(--text-light);
  box-shadow: 0 4px 14px rgba(var(--accent-rgb), 0.3);
}

.btn-primary:hover {
  background-color: var(--primary);
  color: var(--text-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(var(--accent-rgb), 0.4);
}

.btn-secondary {
  background-color: transparent;
  border-color: var(--border-color);
  color: var(--primary);
}

.btn-secondary:hover {
  border-color: var(--primary);
  background-color: var(--primary);
  color: var(--text-light);
  transform: translateY(-2px);
}

.btn-success {
  background-color: var(--success);
  color: var(--text-light);
  box-shadow: 0 4px 14px rgba(var(--success-rgb), 0.3);
}

.btn-success:hover {
  background-color: var(--primary);
  color: var(--text-light);
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(var(--success-rgb), 0.4);
}

/* ==========================================================================
   HEADER & NAVIGATION
   ========================================================================== */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: var(--glass-bg);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  transition: var(--transition);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 80px;
  position: relative;
}

.site-logo a {
  font-family: var(--font-title);
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary);
  letter-spacing: -0.5px;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.site-logo span {
  color: var(--accent);
}

.main-navigation ul {
  display: flex;
  list-style: none;
  margin: 0;
  padding: 0;
  gap: 2rem;
}

.main-navigation a {
  font-family: var(--font-title);
  font-weight: 600;
  color: var(--text-medium);
  font-size: 0.95rem;
  position: relative;
  padding: 0.5rem 0;
}

.main-navigation a:hover,
.main-navigation .current-menu-item > a {
  color: var(--accent);
}

.main-navigation a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background-color: var(--accent);
  transition: var(--transition);
}

.main-navigation a:hover::after,
.main-navigation .current-menu-item > a::after {
  width: 100%;
}

/* Hamburger mobile menu button */
.menu-toggle {
  display: none;
}

@media (max-width: 768px) {
  .site-logo img,
  .site-logo a img {
    width: 60px !important;
    max-width: 60px !important;
    height: auto !important;
  }

  .menu-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(0, 141, 202, 0.08);
    border: 1px solid rgba(0, 141, 202, 0.15);
    color: var(--accent);
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    cursor: pointer;
    padding: 0;
    transition: var(--transition);
    align-self: center;
    margin-left: auto;
  }
  
  .menu-toggle:hover {
    background-color: var(--accent);
    color: var(--text-light);
  }

  .menu-toggle svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
    transition: var(--transition);
  }
  
  .main-navigation {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.96);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-lg);
    opacity: 0;
    transform: translateY(-10px);
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 999;
  }
  
  .main-navigation.active {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
  }
  
  .main-navigation ul {
    flex-direction: column;
    padding: 1.5rem;
    gap: 1rem;
  }
  
  .main-navigation a {
    display: block;
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(15, 23, 42, 0.05);
  }
  
  .main-navigation li:last-child a {
    border-bottom: none;
  }

  .main-navigation a::after {
    display: none;
  }
}

/* ==========================================================================
   HOMEPAGE (front-page.php) SPECIFIC STYLE
   ========================================================================== */
/* Hero Section */
.hero {
  position: relative;
  background: radial-gradient(circle at 10% 20%, rgba(2,132,199,0.06) 0%, rgba(255,255,255,0) 90%);
  overflow: hidden;
  padding: clamp(4rem, 8vw, 8rem) 0 clamp(3rem, 6vw, 6rem);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: 2.5rem;
}

@media (min-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1.25fr 0.75fr;
    gap: 4rem;
  }
}

.hero-content {
  animation: fadeInUp 0.8s ease;
}

.hero-tagline {
  display: inline-block;
  background-color: rgba(var(--accent-rgb), 0.1);
  color: var(--accent);
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.825rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 0.4rem 1rem;
  border-radius: var(--radius-full);
  margin-bottom: 1.25rem;
}

.hero-title {
  font-size: clamp(2.25rem, 6vw, 3.5rem);
  line-height: 1.15;
  margin-bottom: 1.5rem;
}

.hero-title span {
  background: linear-gradient(135deg, var(--primary) 30%, var(--accent) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-desc {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-medium);
  margin-bottom: 2rem;
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

@media (max-width: 480px) {
  .hero-buttons .btn {
    width: 100%;
  }
}

.hero-image {
  animation: scaleIn 0.8s ease;
  position: relative;
}

.hero-image img {
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg);
  width: 100%;
  height: auto;
}

/* Card glassmorphism styling */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  position: relative;
}

.card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(var(--accent-rgb), 0.2);
}

.card-icon {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  background-color: rgba(var(--accent-rgb), 0.1);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

/* BestBuys Section */
.seafood-section {
  background-color: var(--primary);
  color: var(--text-light);
  border-radius: var(--radius-lg);
  padding: clamp(1.5rem, 4vw, 4rem);
  box-shadow: var(--shadow-lg);
  position: relative;
  overflow: hidden;
}

.seafood-section::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: radial-gradient(circle at 90% 10%, rgba(var(--accent-rgb), 0.15) 0%, transparent 60%);
  pointer-events: none;
}

.seafood-section h2, .seafood-section h3 {
  color: var(--text-light);
}

.seafood-grid {
  display: grid;
  grid-template-columns: 1fr;
  align-items: center;
  gap: 2.5rem;
}

@media (min-width: 1024px) {
  .seafood-grid {
    grid-template-columns: 0.95fr 1.05fr;
    gap: 4rem;
  }
}

.seafood-images {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

@media (min-width: 768px) {
  .seafood-images {
    gap: 1.25rem;
  }
}

.seafood-images img {
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  width: 100%;
  height: auto;
}

.seafood-images img:hover {
  transform: scale(1.03);
}

/* Category grid items */
.category-badge {
  background-color: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.1);
  padding: 1rem 1.5rem;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: var(--transition);
}

.category-badge:hover {
  background-color: rgba(var(--accent-rgb), 0.2);
  border-color: var(--accent);
}

.category-icon {
  font-size: 1.5rem;
}

/* Testimonials */
.testimonial-card {
  padding: clamp(1.5rem, 3vw, 2.5rem);
  border-radius: var(--radius-md);
  background-color: var(--bg-card);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-color);
  position: relative;
}

.testimonial-quote {
  font-style: italic;
  font-size: clamp(0.95rem, 2vw, 1.05rem);
  color: var(--text-medium);
  margin-bottom: 1.5rem;
}

.testimonial-stars {
  color: #fbbf24; /* Amber star color */
  display: flex;
  gap: 0.2rem;
  margin-bottom: 1rem;
}

.testimonial-stars svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.testimonial-author {
  font-family: var(--font-title);
  font-weight: 700;
  color: var(--primary);
}

/* FAQ Accordion */
.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: 1rem;
  overflow: hidden;
  transition: var(--transition);
}

.faq-question {
  padding: 1.25rem 1.5rem;
  font-family: var(--font-title);
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
  user-select: none;
  gap: 1rem;
}

.faq-question svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex-shrink: 0;
  transition: var(--transition);
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
  padding: 0 1.5rem;
}

.faq-answer p {
  padding-bottom: 1.25rem;
  color: var(--text-medium);
  margin: 0;
}

.faq-item.active {
  border-color: rgba(var(--accent-rgb), 0.3);
  box-shadow: var(--shadow-md);
}

.faq-item.active .faq-question {
  color: var(--accent);
}

.faq-item.active .faq-question svg {
  transform: rotate(180deg);
}

.faq-item.active .faq-answer {
  max-height: 500px; /* high limit */
  transition: max-height 0.3s cubic-bezier(1, 0, 1, 0);
}

/* ==========================================================================
   STATIC PAGES STYLING (page.php, about, contact)
   ========================================================================== */
.page-hero {
  background-color: var(--primary);
  color: var(--text-light);
  padding: clamp(3rem, 6vw, 5rem) 0;
  text-align: center;
}

.page-hero h1 {
  color: var(--text-light);
  margin-bottom: 0;
}

.page-content-wrapper {
  background-color: var(--bg-card);
  border-radius: var(--radius-md);
  border: 1px solid var(--border-color);
  padding: clamp(1.5rem, 4vw, 3rem);
  box-shadow: var(--shadow-sm);
  margin-top: -3rem;
  position: relative;
  z-index: 10;
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 3rem;
}

@media (min-width: 1024px) {
  .contact-layout {
    grid-template-columns: 1fr 1fr;
  }
}

.contact-card {
  text-align: center;
  background-color: var(--bg-light);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 2.5rem 1.5rem;
  transition: var(--transition);
}

.contact-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}

.contact-card svg {
  width: 40px;
  height: 40px;
  margin-bottom: 1.5rem;
  fill: var(--accent);
}

.contact-card-full {
  grid-column: span 1;
}

@media (min-width: 576px) {
  .contact-card-full {
    grid-column: span 2;
  }
}

/* ==========================================================================
   BLOG LAYOUT (index.php, single.php)
   ========================================================================== */
.blog-card {
  background-color: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
}

.blog-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(var(--accent-rgb), 0.2);
}

.blog-card-image {
  height: 220px;
  overflow: hidden;
  background-color: var(--primary);
  display: flex;
  align-items: center;
  justify-content: center;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: var(--transition);
}

.blog-card:hover .blog-card-image img {
  transform: scale(1.05);
}

.blog-card-content {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.blog-card-meta {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
}

.blog-card-title {
  font-size: 1.35rem;
  margin-bottom: 1rem;
}

.blog-card-title a {
  color: var(--primary);
}

.blog-card-title a:hover {
  color: var(--accent);
}

.blog-card-excerpt {
  color: var(--text-medium);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.blog-card-link {
  font-family: var(--font-title);
  font-weight: 700;
  font-size: 0.9rem;
  margin-top: auto;
  color: var(--accent);
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
}

.blog-card-link:hover {
  gap: 0.5rem;
}

/* Single Blog Post Details */
.single-post-container {
  max-width: 800px;
  margin: 0 auto;
}

.single-post-header {
  text-align: center;
  padding: clamp(3rem, 6vw, 5rem) 0 3rem;
}

.single-post-title {
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: 1.5rem;
}

.single-post-meta {
  font-family: var(--font-title);
  color: var(--text-medium);
  font-weight: 600;
}

.single-post-content {
  font-size: clamp(1rem, 2vw, 1.1rem);
  line-height: 1.8;
  color: var(--text-dark);
}

.single-post-content p {
  margin-bottom: 2rem;
}

.single-post-content blockquote {
  font-family: var(--font-title);
  font-style: italic;
  font-size: clamp(1.2rem, 3vw, 1.5rem);
  border-left: 4px solid var(--accent);
  padding-left: 1.5rem;
  margin: 2rem 0;
  color: var(--primary);
}

/* ==========================================================================
   FOOTER STYLING
   ========================================================================== */
.site-footer {
  background-color: var(--primary);
  color: var(--text-light);
  padding: clamp(3rem, 6vw, 5rem) 0 2rem;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.site-footer h3, .site-footer h4 {
  color: var(--text-light);
  margin-bottom: 1.5rem;
}

.footer-widget-area {
  margin-bottom: 3rem;
}

.footer-logo {
  font-family: var(--font-title);
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--text-light);
  margin-bottom: 1rem;
}

.footer-logo span {
  color: var(--accent);
}

.footer-about p {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  margin-bottom: 0.75rem;
}

.footer-nav a {
  color: var(--text-muted);
  font-size: 0.95rem;
}

.footer-nav a:hover {
  color: var(--text-light);
  padding-left: 0.25rem;
}

.footer-contact p {
  color: var(--text-muted);
  font-size: 0.95rem;
  margin-bottom: 0.75rem;
}

.footer-socials {
  display: flex;
  gap: 1rem;
  margin-top: 1.5rem;
}

.footer-socials a {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background-color: rgba(255, 255, 255, 0.08);
  color: var(--text-light);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--transition);
}

.footer-socials a:hover {
  background-color: var(--accent);
  transform: translateY(-2px);
}

.site-info {
  border-top: 1px solid rgba(255, 255, 255, 0.05);
  padding-top: 2rem;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

@media (min-width: 768px) {
  .site-info {
    flex-direction: row;
  }
}

.site-info p {
  color: var(--text-muted);
  font-size: 0.85rem;
  margin: 0;
}

/* ==========================================================================
   ANIMATIONS
   ========================================================================== */
@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@keyframes scaleIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}
