/* public/assets/css/style.css */

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;500;700&family=Plus+Jakarta+Sans:wght@400;500;600&display=swap');

:root {
  /* Brand Colors - Premium Honey & Nature */
  --color-primary: #FFB303;
  /* Vibrant Honey */
  --color-primary-dark: #DA8E00;
  /* Darker Amber */
  --color-secondary: #2D2720;
  /* Soft Black/Brown */
  --color-accent: #865D36;
  /* Wood/Earth */
  --color-bg: #FFFCF5;
  /* Very Light Cream */
  --color-bg-card: #FFFFFF;
  --color-surface: #F9F5EC;
  /* Secondary Background */

  --color-text: #3D352E;
  --color-text-light: #756C62;
  --color-border: #EBE5D9;

  --color-success: #388E3C;
  --color-error: #D32F2F;

  /* Typography */
  --font-heading: 'Outfit', sans-serif;
  --font-body: 'Plus Jakarta Sans', sans-serif;

  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 4rem;
  --spacing-xl: 6rem;

  /* Border Radius */
  --radius-sm: 8px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-full: 999px;

  /* Shadows */
  --shadow-sm: 0 4px 6px -1px rgba(0, 0, 0, 0.02), 0 2px 4px -1px rgba(0, 0, 0, 0.02);
  --shadow-md: 0 10px 15px -3px rgba(45, 39, 32, 0.05), 0 4px 6px -2px rgba(45, 39, 32, 0.02);
  --shadow-lg: 0 20px 25px -5px rgba(45, 39, 32, 0.08), 0 10px 10px -5px rgba(45, 39, 32, 0.03);
}

/* Reset & Base */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--font-heading);
  color: var(--color-secondary);
  line-height: 1.2;
  font-weight: 700;
  margin-bottom: var(--spacing-sm);
}

h1 {
  font-size: 3.5rem;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 2.5rem;
  letter-spacing: -0.01em;
}

h3 {
  font-size: 1.5rem;
}

a {
  text-decoration: none;
  color: inherit;
  transition: all 0.2s ease;
}

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

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 32px;
  border-radius: var(--radius-full);
  font-weight: 600;
  cursor: pointer;
  border: none;
  font-size: 1rem;
  letter-spacing: 0.01em;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  font-family: var(--font-heading);
}

.btn-primary {
  background-color: var(--color-primary);
  color: #2D2720;
}

.btn-primary:hover {
  background-color: var(--color-primary-dark);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 179, 3, 0.3);
}

.btn-outline {
  border: 2px solid var(--color-secondary);
  color: var(--color-secondary);
  background: transparent;
  padding: 12px 30px;
  /* Adjust for border */
}

.btn-outline:hover {
  background-color: var(--color-secondary);
  color: #fff;
  transform: translateY(-2px);
}

/* Layout */
.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 var(--spacing-md);
}

/* Header */
.site-header {
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(10px);
  position: sticky;
  top: 0;
  z-index: 1000;
  border-bottom: 1px solid rgba(0, 0, 0, 0.03);
  padding: 1.2rem 0;
}

.nav-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.brand-logo {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--color-secondary);
  font-family: var(--font-heading);
  letter-spacing: -0.03em;
}

.main-nav ul,
.nav-list {
  display: flex;
  gap: 2rem;
  list-style: none;
  margin: 0;
  padding: 0;
  align-items: center;
}

.main-nav a {
  font-weight: 600;
  color: var(--color-text);
  font-size: 0.95rem;
  position: relative;
}

.main-nav a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--color-primary);
  transition: width 0.3s ease;
}

.main-nav a:hover::after {
  width: 100%;
}

.nav-icons {
  display: flex;
  gap: 1.5rem;
  align-items: center;
  font-weight: 600;
}

/* Mobile Toggle - Default Hidden */
.mobile-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  flex-direction: column;
  gap: 5px;
  padding: 5px;
  z-index: 1001;
}

.mobile-toggle span {
  display: block;
  width: 25px;
  height: 2.5px;
  background-color: var(--color-secondary);
  border-radius: 2px;
  transition: all 0.3s ease;
}

.mobile-toggle.active span:nth-child(1) {
  transform: rotate(45deg) translate(5px, 5px);
}

.mobile-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-toggle.active span:nth-child(3) {
  transform: rotate(-45deg) translate(5px, -6px);
}

.mobile-only-link {
  display: none;
}

/* Mobile Navigation */
@media (max-width: 900px) {
  .mobile-toggle {
    display: flex;
  }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: rgba(255, 255, 255, 0.98);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    padding: 0;
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.4s ease-out;
    box-shadow: var(--shadow-md);
  }

  .main-nav.active {
    max-height: 400px;
    /* Adjust as needed */
  }

  .main-nav ul,
  .nav-list {
    flex-direction: column;
    align-items: center;
    /* Center items as per user preference seen in image */
    gap: 0;
    padding: 1rem 0;
  }

  .main-nav li {
    width: 100%;
    /* border-bottom: 1px solid rgba(0, 0, 0, 0.05);  <-- Removed for cleaner look */
  }

  .main-nav li:last-child {
    border-bottom: none;
  }

  .main-nav a {
    display: block;
    padding: 0.8rem 0;
    /* Reduced padding for better spacing */
    font-size: 1.1rem;
    text-align: center;
  }

  .mobile-only-link {
    display: block;
  }

  /* Hide Desktop Icons except Cart/Search if crowded, but usually keep icons */
  /* Maybe hide specific account icon to prefer menu link */
  .nav-icons a[title="My Account"],
  .nav-icons a[title="Logout"],
  .nav-icons a[title="Login"] {
    display: none;
    /* Move to menu on mobile */
  }
}

/* Hero Section */
.hero-section {
  position: relative;
  overflow: hidden;
  border-radius: 0 0 40px 40px;
}

/* Cards */
.product-card {
  background: var(--color-bg-card);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  border: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  height: 100%;
}

.product-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--shadow-lg);
  border-color: var(--color-primary);
}

.product-image {
  aspect-ratio: 1;
  background: var(--color-surface);
  border-radius: var(--radius-md) var(--radius-md) 0 0;
  position: relative;
  overflow: hidden;
}

.product-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

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

.product-info {
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.product-title {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
  min-height: 2.4em;
}

.product-price {
  font-size: 1.25rem;
  color: var(--color-primary-dark);
  font-weight: 700;
  margin-top: auto;
}

/* Form inputs modernized */
input,
select,
textarea {
  width: 100%;
  padding: 14px 20px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  background: var(--color-bg-card);
  transition: all 0.2s;
  font-family: inherit;
  font-size: 1rem;
}

input:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(255, 179, 3, 0.1);
}

/* Footer modernize */
.site-footer {
  background: var(--color-secondary);
  color: #F9F5EC;
  padding: 5rem 0 2rem;
  margin-top: 5rem;
  border-radius: 40px 40px 0 0;
}

.footer-col h4 {
  color: var(--color-primary);
  margin-bottom: 1.5rem;
}

.footer-col ul li {
  margin-bottom: 0.8rem;
}

/* Trust Badges modern */
.trust-row {
  background: var(--color-surface);
  padding: 3rem 0;
}

.trust-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 1rem;
}

.trust-item strong {
  font-family: var(--font-heading);
  font-size: 1.1rem;
  color: var(--color-secondary);
  margin-bottom: 0.25rem;
}

/* --- Product Page Specifics --- */

.product-detail-layout {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 4rem;
  padding: 4rem 0;
  align-items: start;
}

@media (max-width: 900px) {
  .product-detail-layout {
    grid-template-columns: 1fr;
    gap: 3rem;
  }
}

/* Gallery */
.gallery-wrapper {
  position: sticky;
  top: 100px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.main-image-container {
  aspect-ratio: 1;
  background: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  position: relative;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-sm);
  display: flex;
  align-items: center;
  justify-content: center;
}

.main-image-container img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  transition: opacity 0.3s ease;
}

.gallery-thumbs {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 1rem;
}

.thumb-img {
  aspect-ratio: 1;
  border-radius: var(--radius-sm);
  cursor: pointer;
  overflow: hidden;
  border: 2px solid transparent;
  transition: all 0.2s;
  background: white;
}

.thumb-img img {
  height: 100%;
  width: 100%;
  object-fit: cover;
}

.thumb-img:hover {
  transform: translateY(-2px);
}

.thumb-img.active-thumb {
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(255, 179, 3, 0.1);
}

/* Product Info Column */
.product-meta-category {
  color: var(--color-primary-dark);
  font-weight: 700;
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  margin-bottom: 0.5rem;
}

.product-details-title {
  font-size: 3rem;
  line-height: 1.1;
  margin-bottom: 1.5rem;
  color: var(--color-secondary);
}

.product-price-block {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
  padding-bottom: 2rem;
  border-bottom: 1px solid var(--color-border);
}

.current-price {
  font-size: 2.5rem;
  font-weight: 800;
  color: var(--color-secondary);
  font-family: var(--font-heading);
}

.review-badge {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--color-surface);
  padding: 8px 16px;
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  font-weight: 600;
}

.product-description-text {
  font-size: 1.05rem;
  color: var(--color-text-light);
  line-height: 1.8;
  margin-bottom: 2.5rem;
}

/* Variants */
.variant-selector {
  margin-bottom: 2.5rem;
}

.variant-label {
  display: block;
  font-weight: 700;
  margin-bottom: 1rem;
  font-family: var(--font-heading);
  color: var(--color-secondary);
}

.variant-options {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

/* Hide actual radio */
.variant-option input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.variant-option-label {
  display: flex;
  align-items: center;
  padding: 12px 24px;
  background: white;
  border: 2px solid var(--color-border);
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 600;
  transition: all 0.2s;
  user-select: none;
}

.variant-option input:checked+.variant-option-label {
  border-color: var(--color-primary);
  background: var(--color-surface);
  color: var(--color-secondary);
  box-shadow: 0 4px 12px rgba(255, 179, 3, 0.15);
}

.variant-option-label:hover {
  border-color: #ccc;
}

/* Stock / Actions */
.add-to-cart-wrapper {
  display: flex;
  gap: 1rem;
  margin-top: 2rem;
}

.qty-input {
  width: 80px;
  text-align: center;
  font-weight: 700;
  font-size: 1.2rem;
}

/* Accordions */
.product-accordion details {
  border-bottom: 1px solid var(--color-border);
  margin-bottom: 1rem;
}

.product-accordion summary {
  padding: 1.2rem 0;
  font-weight: 700;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-family: var(--font-heading);
  font-size: 1.1rem;
  color: var(--color-secondary);
}

.product-accordion summary::-webkit-details-marker {
  display: none;
}

.product-accordion details[open] summary {
  color: var(--color-primary-dark);
}

.product-accordion .content {
  padding-bottom: 1.5rem;
  color: var(--color-text-light);
  line-height: 1.7;
}

/* Reviews */
.reviews-section {
  background: white;
  border-radius: var(--radius-lg);
  padding: 3rem;
  margin-top: 4rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
}

.review-card {
  padding: 2rem 0;
  border-bottom: 1px solid var(--color-border);
}

.review-card:last-child {
  border-bottom: none;
}

.review-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.8rem;
}

.review-author {
  font-weight: 700;
  font-family: var(--font-heading);
  font-size: 1.1rem;
}

.review-date {
  font-size: 0.85rem;
  color: #999;
}

.review-body {
  color: var(--color-text-light);
  line-height: 1.6;
}

/* --- Cart & Checkout Refined --- */

.cart-layout,
.checkout-layout {
  display: grid;
  grid-template-columns: 1fr 420px;
  /* Slightly wider summary */
  gap: 3rem;
  padding: 4rem 0;
  align-items: start;
}

@media (max-width: 900px) {

  .cart-layout,
  .checkout-layout {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
}

.cart-table-wrapper {
  background: white;
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  overflow: hidden;
}

.cart-table th {
  background: #FAFAFA;
  padding: 1.5rem;
  font-weight: 600;
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  color: var(--color-text);
}

.cart-table td {
  padding: 2rem 1.5rem;
}

.summary-card {
  background: white;
  padding: 2.5rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  border: 1px solid var(--color-border);
  position: sticky;
  top: 120px;
  /* Ensure it doesn't hit header */
}

/* Checkout Forms */
.form-section {
  background: white;
  padding: 3rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--color-border);
  margin-bottom: 2.5rem;
}

.form-section h3 {
  font-size: 1.4rem;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--color-border);
  color: var(--color-secondary);
}

.checkout-form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  /* Strict 2 columns */
  gap: 2rem;
}

.form-group {
  /* No margin bottom here, handled by grid gap */
  display: flex;
  flex-direction: column;
}

.span-2 {
  grid-column: span 2;
}

@media (max-width: 600px) {
  .checkout-form-grid {
    grid-template-columns: 1fr;
  }

  .span-2 {
    grid-column: span 1;
  }
}

.form-group label {
  display: block;
  margin-bottom: 0.8rem;
  font-weight: 600;
  font-size: 0.9rem;
  color: var(--color-text);
  letter-spacing: 0.02em;
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="tel"] {
  width: 100%;
  /* Ensure full width of cell */
  height: 52px;
  padding: 0 1.2rem;
  font-size: 1rem;
  border: 1px solid #E0E0E0;
  border-radius: var(--radius-sm);
  background: #FAFAFA;
  transition: all 0.2s;
}

input:focus {
  background: #fff;
  border-color: var(--color-primary);
  box-shadow: 0 0 0 4px rgba(255, 179, 3, 0.1);
  outline: none;
}

/* Payment Radio */
.payment-option {
  display: flex;
  align-items: flex-start;
  /* Align top */
  gap: 1.2rem;
  padding: 1.5rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s;
  margin-bottom: 1.2rem;
}

.payment-option:hover {
  background: #FCFCFC;
  border-color: #CCC;
}

.payment-option input {
  margin-top: 4px;
  /* Align with first line of text */
  width: 20px;
  height: 20px;
  accent-color: var(--color-primary);
}

.payment-option strong {
  font-size: 1.05rem;
  color: var(--color-secondary);
}

/* --- Home Page Specific Styles (Desktop Defaults) --- */

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

.categories-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 3rem;
}

.story-block {
  grid-column: span 2;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
}

/* Trust Section */
.trust-grid {
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.08);
  padding: 3rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 2rem;
  align-items: center;
}

.trust-item {
  text-align: center;
}

.trust-item.bordered {
  border-left: 1px solid #eee;
}

/* Newsletter Form */
.newsletter-form {
  display: flex;
  gap: 0;
  width: 100%;
  max-width: 550px;
  margin: 0 auto;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 99px;
  padding: 6px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

/* --- Mobile Responsiveness (Small Screens / iPhone SE) --- */
@media (max-width: 650px) {

  /* Global Container Padding */
  .container {
    padding-left: 1.25rem;
    padding-right: 1.25rem;
  }

  /* Hero Section */
  .hero-section {
    padding: 3rem 0 5rem !important;
  }

  .hero-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 2rem;
  }

  .hero-grid h1 {
    font-size: 2.2rem !important;
    line-height: 1.2;
  }

  .hero-grid>div:first-child>div {
    /* Button Container */
    justify-content: center;
    flex-direction: column;
    width: 100%;
    gap: 0.8rem !important;
  }

  .hero-grid .btn {
    width: 100%;
    padding: 0.9rem 1rem !important;
  }

  /* Trust Badges */
  .trust-grid {
    grid-template-columns: 1fr 1fr;
    padding: 1.5rem !important;
    gap: 1.5rem;
  }

  .trust-item {
    padding: 0.5rem;
  }

  .trust-item.bordered {
    border-left: none;
  }

  /* Categories */
  .categories-grid {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .categories-grid>a {
    grid-column: span 1 !important;
    padding: 2rem !important;
    min-height: 280px !important;
    background-position: center !important;
  }

  /* Story Block */
  .story-block {
    grid-column: span 1 !important;
    grid-template-columns: 1fr;
    gap: 2rem;
    text-align: center;
  }

  /* Newsletter Form Stacking */
  .newsletter-form {
    flex-direction: column;
    background: transparent;
    border: none;
    box-shadow: none;
    padding: 0;
    gap: 1rem;
    border-radius: 0;
  }

  .newsletter-form input {
    width: 100%;
    text-align: center;
    background: rgba(255, 255, 255, 0.08) !important;
    border: 1px solid rgba(255, 255, 255, 0.2) !important;
    border-radius: 50px;
    margin-bottom: 0.5rem;
  }

  .newsletter-form button {
    width: 100%;
  }

  /* Footer Stacking */
  .site-footer .container {
    flex-direction: column;
    gap: 2.5rem;
    text-align: center !important;
  }

  .footer-col {
    width: 100%;
  }
}

@media (max-width: 400px) {
  .trust-grid {
    grid-template-columns: 1fr;
  }

  h1 {
    font-size: 2rem !important;
  }
}