/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: rgba(26, 26, 46, 0.95);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--color-border);
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  display: flex;
  align-items: center;
  height: 100%;
}

.logo-img {
  height: 90%;
  width: auto;
  display: block;
}

/* Menu toggle — always visible */
.menu-toggle {
  display: flex;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 4px;
}

.menu-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--color-cream);
  transition: all var(--transition-base);
  transform-origin: center;
}

.menu-toggle.is-active span:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

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

.menu-toggle.is-active span:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* Dropdown nav */
.dropdown-nav {
  position: absolute;
  top: var(--header-height);
  left: 0;
  right: 0;
  background: rgba(22, 33, 62, 0.97);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
  max-height: 0;
  overflow: hidden;
  transition: max-height var(--transition-base);
  z-index: 99;
}

.dropdown-nav[aria-hidden="false"] {
  max-height: 500px;
}

.dropdown-nav-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--space-lg) var(--space-md);
  gap: var(--space-md);
}

.dropdown-nav a {
  font-family: 'Syncopate', sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--color-cream);
  transition: color var(--transition-fast);
  padding: var(--space-xs) 0;
}

.dropdown-nav a:hover {
  color: var(--color-gold);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: var(--space-md);
}

.lang-dropdown {
  position: relative;
}

.flag-icon {
  width: 22px;
  height: 16px;
  border-radius: 2px;
  display: inline-block;
  vertical-align: middle;
  flex-shrink: 0;
}

.lang-current {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem;
  color: var(--color-cream);
}

.lang-arrow {
  font-size: 0.6rem;
  color: var(--color-text-muted);
}

.lang-menu {
  display: none;
  position: absolute;
  top: 100%;
  right: 0;
  background: rgba(22, 33, 62, 0.97);
  backdrop-filter: blur(12px);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  padding: 0.3rem 0;
  min-width: 100px;
  z-index: 101;
  margin-top: 0.3rem;
}

.lang-menu.is-open {
  display: block;
}

.lang-option {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 0.75rem;
  font-size: 0.85rem;
  color: var(--color-text-muted);
  white-space: nowrap;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.lang-option:hover {
  color: var(--color-gold);
  background: rgba(212, 168, 67, 0.1);
}

.lang-option.active {
  color: var(--color-gold);
}

.user-header-name {
  font-size: 0.85rem;
  color: var(--color-gold);
  font-weight: 500;
  display: none;
}

.user-header-name.is-visible {
  display: inline;
}

.user-toggle,
.cart-toggle {
  background: none;
  border: none;
  color: var(--color-cream);
  cursor: pointer;
  position: relative;
}

.user-toggle:hover,
.cart-toggle:hover {
  color: var(--color-gold);
}

.cart-count {
  position: absolute;
  top: -6px;
  right: -8px;
  background: var(--color-gold);
  color: var(--color-bg-dark);
  font-size: 0.7rem;
  font-weight: 700;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}


/* Offset for fixed header */
main {
  margin-top: var(--header-height);
}

/* Hero */
.hero {
  height: 100vh;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  text-align: left;
  background:
    linear-gradient(90deg, rgba(10, 14, 28, 0.75) 0%, rgba(10, 14, 28, 0.35) 40%, rgba(10, 14, 28, 0) 70%),
    url('/assets/images/hero_background.png') center / cover no-repeat,
    var(--color-bg-dark);
  padding: calc(var(--space-xl) * 1.5) var(--space-lg);
}

.hero-content {
  max-width: 50%;
  margin-left: clamp(var(--space-lg), 6vw, calc(var(--space-xl) * 1.5));
  margin-right: 0;
}

.hero-title {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  margin-bottom: var(--space-md);
  color: var(--color-cream);
  line-height: 1.15;
}

.hero-title .hero-accent {
  color: var(--color-gold);
  background: none;
  -webkit-text-fill-color: var(--color-gold);
}

.hero-title .hero-word {
  display: inline-block;
  white-space: nowrap;
}

.hero-title .hero-letter {
  --letter-base-color: var(--color-cream);
  display: inline-block;
  color: var(--letter-base-color);
  animation: heroLetterPulse 28s ease-in-out infinite;
  will-change: color, text-shadow;
}

.hero-title .hero-accent .hero-letter {
  --letter-base-color: var(--color-gold);
}

@keyframes heroLetterPulse {
  0%, 88%, 100% {
    color: var(--letter-base-color);
    text-shadow: none;
  }
  92% {
    color: #ffffff;
    text-shadow:
      0 0 6px rgba(255, 255, 255, 0.9),
      0 0 18px rgba(255, 255, 255, 0.55),
      0 0 32px rgba(255, 240, 200, 0.35);
  }
  96% {
    color: var(--letter-base-color);
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.25);
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-title .hero-letter {
    animation: none;
  }
}

.hero-subtitle {
  font-size: clamp(1.1rem, 2.15vw, 1.45rem);
  color: #ffffff;
  margin-bottom: var(--space-lg);
  max-width: 600px;
  margin-left: 0;
  margin-right: 0;
  font-weight: 400;
}

.about-motto {
  max-width: 780px;
  margin: var(--space-lg) auto;
  text-align: center;
}

.about-motto-lead {
  font-family: var(--font-display);
  font-size: clamp(1.4rem, 2.6vw, 1.9rem);
  color: var(--color-gold);
  font-style: italic;
  margin-bottom: var(--space-md);
  line-height: 1.3;
}

.about-motto-body {
  font-size: clamp(1rem, 1.6vw, 1.1rem);
  line-height: 1.7;
  color: var(--color-text);
}

.hero .btn-primary {
  background: #ffffff;
  color: var(--color-gold);
  font-size: 1.3rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  padding: 1.1rem 2.8rem;
  border-radius: var(--radius-md);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.9),
    0 0 12px rgba(255, 255, 255, 0.85),
    0 0 28px rgba(255, 255, 255, 0.55),
    0 0 56px rgba(255, 255, 255, 0.35);
  transition: transform var(--transition-fast);
}

.hero .btn-primary:hover {
  background: #ffffff;
  color: var(--color-gold);
  transform: translateY(-2px);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.95),
    0 0 14px rgba(255, 255, 255, 0.9),
    0 0 32px rgba(255, 255, 255, 0.6),
    0 0 64px rgba(255, 255, 255, 0.4);
}

@media (max-width: 768px) {
  .hero {
    background:
      linear-gradient(180deg, rgba(10, 14, 28, 0.45) 0%, rgba(10, 14, 28, 0.2) 100%),
      url('/assets/images/hero_background.png') center / cover no-repeat,
      var(--color-bg-dark);
    justify-content: center;
    text-align: center;
  }
  .hero-content {
    max-width: 100%;
    margin-left: 0;
  }
  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }
}

/* Product Grid */
.products-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: var(--space-lg);
  margin-bottom: var(--space-lg);
}

/* Blog Grid (shared homepage + blog listing) */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-lg);
}

.blog-card {
  background: linear-gradient(180deg, var(--color-card-bg) 0%, var(--color-bg-deeper) 100%);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-base);
}

.blog-card:hover {
  transform: translateY(-6px);
  border-color: var(--color-gold);
  box-shadow: var(--card-shadow-hover);
}

.blog-card a {
  text-decoration: none;
  color: inherit;
}

.blog-card img {
  width: 100%;
  height: 200px;
  object-fit: contain;
  display: block;
  padding: 0.5rem;
  background: var(--color-bg-dark);
}

.blog-card-info {
  padding: 1rem 1.25rem;
}

.blog-card-info time {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.blog-card-info h3 {
  font-size: 1.1rem;
  margin: 0.4rem 0;
  color: var(--color-text);
}

.blog-card-info p {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  line-height: 1.5;
}

.product-card {
  background: linear-gradient(180deg, var(--color-card-bg) 0%, var(--color-bg-deeper) 100%);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-base);
}

.product-card:hover {
  transform: translateY(-6px);
  border-color: var(--color-gold);
  box-shadow: var(--card-shadow-hover);
}

.product-card-image {
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
  background: var(--color-bg-dark);
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0.5rem;
}

.badge {
  position: absolute;
  top: var(--space-sm);
  left: var(--space-sm);
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-sm);
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.badge-offer {
  background: var(--color-gold);
  color: var(--color-bg-dark);
}

.product-card-info {
  padding: var(--space-md);
}

.product-card-name {
  font-size: 1.1rem;
  margin-bottom: var(--space-sm);
}

.price-compare {
  text-decoration: line-through;
  color: var(--color-text-muted);
  margin-right: var(--space-sm);
  font-size: 0.9rem;
}

.price-current {
  color: var(--color-gold);
  font-weight: 700;
  font-size: 1.1rem;
}

/* Cart Drawer */
.cart-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 200;
  pointer-events: none;
}

.cart-drawer[aria-hidden="false"] {
  pointer-events: auto;
}

.cart-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.cart-drawer[aria-hidden="false"] .cart-overlay {
  opacity: 1;
}

.cart-panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(400px, 90vw);
  background: var(--color-bg-deeper);
  border-left: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform var(--transition-base);
}

.cart-drawer[aria-hidden="false"] .cart-panel {
  transform: translateX(0);
}

.cart-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md);
  border-bottom: 1px solid var(--color-border);
}

.cart-close {
  background: none;
  border: none;
  color: var(--color-cream);
  font-size: 1.5rem;
  cursor: pointer;
}

.cart-items {
  flex: 1;
  overflow-y: auto;
  padding: var(--space-md);
}

.cart-summary {
  padding: var(--space-md);
  border-top: 1px solid var(--color-border);
}

.cart-subtotal, .cart-shipping, .cart-total {
  display: flex;
  justify-content: space-between;
  margin-bottom: var(--space-sm);
}

.cart-total {
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--color-gold);
  border-top: 1px solid var(--color-border);
  padding-top: var(--space-sm);
}

.btn-checkout {
  width: 100%;
  margin-top: var(--space-md);
}

.cart-free-shipping-note {
  text-align: center;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-top: var(--space-sm);
}

.cart-empty {
  display: none;
  text-align: center;
  padding: var(--space-xl) var(--space-md);
}

/* User Drawer */
.user-drawer {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 200;
  pointer-events: none;
}

.user-drawer[aria-hidden="false"] {
  pointer-events: auto;
}

.user-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  opacity: 0;
  transition: opacity var(--transition-base);
}

.user-drawer[aria-hidden="false"] .user-overlay {
  opacity: 1;
}

.user-panel {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  width: min(400px, 90vw);
  background: var(--color-bg-deeper);
  border-left: 1px solid var(--color-border);
  display: flex;
  flex-direction: column;
  transform: translateX(100%);
  transition: transform var(--transition-base);
}

.user-drawer[aria-hidden="false"] .user-panel {
  transform: translateX(0);
}

.user-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: var(--space-md);
  border-bottom: 1px solid var(--color-border);
}

.user-close {
  background: none;
  border: none;
  color: var(--color-cream);
  font-size: 1.5rem;
  cursor: pointer;
}

.user-guest,
.user-registered {
  padding: var(--space-lg) var(--space-md);
  text-align: center;
}

.user-guest-icon,
.user-welcome-icon {
  color: var(--color-gold);
  margin-bottom: var(--space-md);
}

.user-guest-text {
  font-family: var(--font-display);
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: var(--space-sm);
}

.user-guest-subtext {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: var(--space-lg);
}

.user-form {
  text-align: left;
}

.user-form-group {
  margin-bottom: var(--space-md);
}

.user-form-group label {
  display: block;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 0.3rem;
  color: var(--color-cream);
}

.user-form-group .required {
  color: var(--color-gold);
}

.user-form-group input {
  width: 100%;
  padding: 0.6rem 0.8rem;
  background: var(--color-bg-dark);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-cream);
  font-size: 0.95rem;
  font-family: var(--font-body);
}

.user-form-group input:focus {
  outline: none;
  border-color: var(--color-gold);
}

.user-form-consent {
  margin-bottom: var(--space-sm);
}

.consent-label {
  display: flex;
  align-items: flex-start;
  gap: 0.5rem;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  cursor: pointer;
  line-height: 1.4;
}

.consent-label input[type="checkbox"] {
  margin-top: 0.15rem;
  flex-shrink: 0;
  accent-color: var(--color-gold);
}

.consent-label a {
  color: var(--color-gold);
  text-decoration: underline;
}

.user-form-submit {
  width: 100%;
  margin-top: var(--space-sm);
}

.user-form-note {
  text-align: center;
  font-size: 0.8rem;
  color: var(--color-text-muted);
  margin-top: var(--space-sm);
}

.user-form-error {
  color: #e74c3c;
  font-size: 0.85rem;
  text-align: center;
  margin-top: var(--space-sm);
  min-height: 1.2em;
}

.user-welcome-name {
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 600;
  color: var(--color-gold);
  margin-bottom: var(--space-sm);
}

.user-welcome-text {
  color: var(--color-text-muted);
  font-size: 0.9rem;
  margin-bottom: var(--space-lg);
  line-height: 1.5;
}

.user-logout {
  width: 100%;
}

/* Cookie Banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 300;
  background: var(--color-bg-deeper);
  border-top: 1px solid var(--color-border);
  padding: var(--space-md) var(--space-lg);
}

.cookie-banner-inner {
  max-width: 960px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: var(--space-lg);
}

.cookie-banner-inner p {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  line-height: 1.5;
  margin: 0;
}

.cookie-accept {
  flex-shrink: 0;
  white-space: nowrap;
}

@media (max-width: 768px) {
  .cookie-banner-inner {
    flex-direction: column;
    text-align: center;
    gap: var(--space-md);
  }

  .cookie-accept {
    width: 100%;
  }
}

/* Blog Grid */
.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: var(--space-lg);
  margin-bottom: var(--space-lg);
}

/* Banner */
.banner-shipping {
  background: var(--color-green);
  text-align: center;
  padding: var(--space-md);
  color: var(--color-white);
}

/* Footer */
.site-footer {
  background: var(--color-bg-deeper);
  border-top: 1px solid var(--color-border);
  padding: var(--space-xl) 0 0;
}

.footer-inner {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--space-lg);
}

.footer-col h4 {
  color: var(--color-gold);
  margin-bottom: var(--space-md);
  font-family: var(--font-display);
}

.footer-col nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-sm) var(--space-lg);
}

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

.footer-address {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: var(--space-sm);
}

.footer-bottom {
  margin-top: var(--space-lg);
  border-top: 1px solid var(--color-border);
  padding: var(--space-md) 0;
  text-align: center;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

/* Responsive */
@media (max-width: 768px) {
  .user-header-name {
    display: none !important;
  }

  .products-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }

  .dropdown-nav a {
    font-size: 0.8rem;
  }
}
