/* ═══════════════════════════════════════════════════════════
   Clyftor Exim — Shared Design System
   ═══════════════════════════════════════════════════════════ */

/* ─── Design Tokens ─────────────────────────────────────── */
:root {
  --green-950: #0e2018;
  --green-900: #1b3a2d;
  --green-800: #264d3b;
  --green-700: #2f6248;
  --green-400: #5a9e72;
  --green-200: #a8d5b8;
  --green-100: #d4eddf;
  --green-50:  #f0f9f4;

  --gold-700:  #a3721f;
  --gold-500:  #c8923a;
  --gold-400:  #d9a84e;
  --gold-100:  #f5e4c3;
  --gold-50:   #fdf6e7;

  --cream:     #faf8f3;
  --white:     #ffffff;
  --charcoal:  #1a1a1a;
  --gray-700:  #374151;
  --gray-500:  #6b7280;
  --gray-300:  #d1d5db;
  --gray-100:  #f3f4f6;

  --shadow-sm: 0 1px 3px rgba(0,0,0,.08), 0 1px 2px rgba(0,0,0,.06);
  --shadow-md: 0 4px 16px rgba(0,0,0,.10);
  --shadow-lg: 0 12px 40px rgba(0,0,0,.14);
  --shadow-xl: 0 24px 64px rgba(0,0,0,.18);

  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  --radius-xl: 32px;

  --t: 0.25s ease;
}

/* ─── Reset ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: var(--cream);
  color: var(--charcoal);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* ─── Utility ────────────────────────────────────────────── */
.container { width: 100%; max-width: 1200px; margin-inline: auto; padding-inline: 24px; }
.section-label {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .73rem; font-weight: 600; letter-spacing: .12em; text-transform: uppercase;
  color: var(--gold-500); margin-bottom: 16px;
}
.section-label::before {
  content: ''; display: block; width: 24px; height: 2px;
  background: var(--gold-500); border-radius: 2px;
}
.section-title {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: clamp(1.75rem, 4vw, 2.75rem);
  font-weight: 700; line-height: 1.2; color: var(--green-900);
}
.section-title span { color: var(--gold-500); }
.section-sub {
  font-size: 1.05rem; color: var(--gray-500); margin-top: 12px; max-width: 560px;
}

/* ─── Buttons ────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 13px 26px; border-radius: var(--radius-sm);
  font-size: .9rem; font-weight: 600; transition: var(--t);
  white-space: nowrap;
  /* ✅ Touch target: ensure minimum 44px tap area */
  min-height: 44px;
}
.btn-primary { background: var(--green-900); color: var(--white); }
.btn-primary:hover { background: var(--green-700); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-gold { background: var(--gold-500); color: var(--white); }
.btn-gold:hover { background: var(--gold-700); transform: translateY(-1px); box-shadow: var(--shadow-md); }
.btn-outline { background: transparent; color: var(--green-900); border: 2px solid var(--green-900); }
.btn-outline:hover { background: var(--green-900); color: var(--white); }
.btn-outline-white { background: transparent; color: var(--white); border: 2px solid rgba(255,255,255,.4); }
.btn-outline-white:hover { background: rgba(255,255,255,.1); border-color: var(--white); }
.btn-sm { padding: 9px 18px; font-size: .82rem; min-height: 44px; }

/* ─── Navigation ─────────────────────────────────────────── */
#navbar {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  transition: background var(--t), box-shadow var(--t), padding var(--t);
  padding: 18px 0;
}
#navbar.scrolled {
  background: rgba(250,248,243,.97);
  backdrop-filter: blur(14px) saturate(1.4);
  box-shadow: 0 1px 0 rgba(0,0,0,.07);
  padding: 10px 0;
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between; gap: 32px;
}

/* Logo */
.nav-logo { display: flex; align-items: center; flex-shrink: 0; }

/* White pill — makes the white-background logo legible on dark hero */
.nav-logo-pill {
  background: var(--white);
  border-radius: 8px;
  padding: 5px 10px;
  display: flex; align-items: center;
  transition: background var(--t), padding var(--t), border-radius var(--t), box-shadow var(--t);
  box-shadow: 0 2px 12px rgba(0,0,0,.18);
}
/* On scrolled (cream bg) the pill dissolves — white on cream is invisible */
#navbar.scrolled .nav-logo-pill {
  background: transparent;
  padding: 0;
  box-shadow: none;
  border-radius: 0;
}

.nav-logo-img {
  height: 52px; width: auto; object-fit: contain;
  display: block;
  transition: height var(--t);
}
#navbar.scrolled .nav-logo-img { height: 44px; }

.nav-links {
  display: flex; align-items: center; gap: 4px; flex: 1; justify-content: center;
}
.nav-links a {
  padding: 8px 14px; border-radius: var(--radius-sm);
  font-size: .88rem; font-weight: 500; color: rgba(255,255,255,.8);
  transition: var(--t);
}
.nav-links a:hover, .nav-links a.active { color: var(--white); background: rgba(255,255,255,.1); }
#navbar.scrolled .nav-links a { color: var(--gray-700); }
#navbar.scrolled .nav-links a:hover,
#navbar.scrolled .nav-links a.active { color: var(--green-900); background: var(--green-50); }

.nav-cta {
  padding: 10px 20px; border-radius: var(--radius-sm);
  font-size: .88rem; font-weight: 600; flex-shrink: 0;
  background: var(--gold-500); color: var(--white); transition: var(--t);
}
.nav-cta:hover { background: var(--gold-700); transform: translateY(-1px); }

/* Hamburger */
.nav-hamburger {
  display: none; flex-direction: column; gap: 5px; padding: 4px;
}
.nav-hamburger span {
  display: block; width: 22px; height: 2px; border-radius: 2px;
  background: var(--white); transition: var(--t);
}
#navbar.scrolled .nav-hamburger span { background: var(--green-900); }
.nav-hamburger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-hamburger.open span:nth-child(2) { opacity: 0; }
.nav-hamburger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile drawer */
.nav-mobile {
  display: none; position: fixed; inset: 0; z-index: 999;
  background: var(--green-950); padding: 96px 32px 40px;
  flex-direction: column; gap: 4px; overflow-y: auto;
}
.nav-mobile.open { display: flex; }
.nav-mobile a {
  font-size: 1.4rem; font-weight: 600; color: var(--white);
  padding: 16px 0; border-bottom: 1px solid rgba(255,255,255,.07);
  font-family: 'Playfair Display', serif; transition: var(--t);
}
.nav-mobile a:hover { color: var(--gold-400); padding-left: 8px; }
.nav-mobile .nav-cta {
  margin-top: 24px; text-align: center; font-size: 1rem;
  border-radius: var(--radius-sm);
}

/* ─── Footer ─────────────────────────────────────────────── */
#footer { background: var(--green-950); padding: 64px 0 32px; }
.footer-grid {
  display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 48px; margin-bottom: 48px;
}
/* Footer logo lives on dark bg → white card to frame the white-bg logo */
.footer-logo-wrap {
  display: inline-flex;
  background: var(--white);
  border-radius: 8px;
  padding: 8px 14px;
  margin-bottom: 20px;
}
.footer-brand .logo-img {
  height: 60px; width: auto; object-fit: contain; display: block;
}
.footer-brand p {
  font-size: .85rem; color: rgba(255,255,255,.38); line-height: 1.7; max-width: 280px;
}
.footer-col h4 {
  font-size: .73rem; font-weight: 600; text-transform: uppercase; letter-spacing: .1em;
  color: rgba(255,255,255,.4); margin-bottom: 20px;
}
.footer-col ul { display: flex; flex-direction: column; gap: 10px; }
.footer-col ul li a {
  font-size: .88rem; color: rgba(255,255,255,.4); transition: var(--t);
}
.footer-col ul li a:hover { color: var(--white); }
.footer-bottom {
  padding-top: 28px; border-top: 1px solid rgba(255,255,255,.07);
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.footer-bottom p { font-size: .8rem; color: rgba(255,255,255,.25); }
.footer-tagline { font-size: .78rem; color: var(--gold-500); font-style: italic; }

/* ─── Floating WhatsApp ───────────────────────────────────── */
.wa-float {
  position: fixed; bottom: 28px; right: 28px; z-index: 900;
  width: 56px; height: 56px; border-radius: 50%;
  background: #25d366; color: var(--white);
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 20px rgba(37,211,102,.4); transition: var(--t);
}
.wa-float:hover { transform: scale(1.1); box-shadow: 0 8px 28px rgba(37,211,102,.5); }
.wa-float::before {
  content: ''; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid rgba(37,211,102,.3); animation: wa-pulse 2.4s ease-in-out infinite;
}
@keyframes wa-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.18); opacity: 0; }
}

/* ─── Back to top ─────────────────────────────────────────── */
.back-top {
  position: fixed; bottom: 28px; left: 28px; z-index: 900;
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--green-900); color: var(--white);
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-md); transition: var(--t);
  opacity: 0; pointer-events: none;
}
.back-top.visible { opacity: 1; pointer-events: auto; }
.back-top:hover { background: var(--green-700); transform: translateY(-2px); }

/* ─── Scroll reveal ──────────────────────────────────────── */
.reveal {
  opacity: 0; transform: translateY(22px);
  transition: opacity .55s ease, transform .55s ease;
}
.reveal.visible { opacity: 1; transform: none; }
.reveal-delay-1 { transition-delay: .1s; }
.reveal-delay-2 { transition-delay: .2s; }
.reveal-delay-3 { transition-delay: .3s; }
.reveal-delay-4 { transition-delay: .4s; }

/* ─── Common section spacing ─────────────────────────────── */
.section { padding: 104px 0; }
.section-sm { padding: 72px 0; }
.section-header-centered { text-align: center; max-width: 620px; margin: 0 auto 56px; }

/* ─── Form shared styles ─────────────────────────────────── */
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group.full { grid-column: span 2; }
.form-group label {
  /* ✅ Bumped up from .75rem for mobile readability */
  font-size: clamp(.8rem, 2vw, .85rem); font-weight: 600; color: var(--gray-700);
  text-transform: uppercase; letter-spacing: .07em;
}
.form-group input,
.form-group select,
.form-group textarea {
  /* ✅ 48px min-height ensures 44px+ touch target accounting for border */
  padding: 13px 14px; border-radius: var(--radius-sm);
  border: 1.5px solid var(--gray-300);
  background: var(--white); font-family: inherit;
  font-size: 1rem; color: var(--charcoal); transition: var(--t); outline: none;
  min-height: 48px;
}
/* ✅ Custom chevron on desktop; let browser handle native on mobile (better UX on iOS/Android) */
.form-group select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%236b7280' stroke-width='1.5' stroke-linecap='round' fill='none'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px;
}
@media (max-width: 768px) {
  .form-group select { appearance: auto; background-image: none; padding-right: 14px; }
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  border-color: var(--green-700); box-shadow: 0 0 0 3px rgba(47,98,72,.1);
}
.form-group input.error,
.form-group select.error { border-color: #dc2626; }
.form-group textarea { min-height: 96px; resize: vertical; }
/* Phone field: dial-code select + number input side by side */
.phone-field { display: flex; }
.phone-field select {
  flex-shrink: 0; min-width: 105px;
  border-radius: var(--radius-sm) 0 0 var(--radius-sm);
  border-right: none;
  background-color: var(--gray-100);
  background-image: none !important;
  padding-right: 10px;
  appearance: auto;
  font-size: .88rem;
}
.phone-field input {
  flex: 1; min-width: 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}
.phone-field:focus-within select,
.phone-field:focus-within input { border-color: var(--green-700); }
.form-submit { display: flex; align-items: center; gap: 14px; margin-top: 24px; flex-wrap: wrap; }
.form-note { font-size: .78rem; color: var(--gray-500); }

/* ─── Category badge colors ──────────────────────────────── */
.badge {
  display: inline-block; font-size: .7rem; font-weight: 600;
  letter-spacing: .06em; text-transform: uppercase;
  padding: 4px 10px; border-radius: 999px;
}
.badge-oils   { background: rgba(200,146,58,.15); color: #a3721f; }
.badge-spices { background: rgba(160,64,16,.12); color: #a04010; }
.badge-cond   { background: rgba(74,104,48,.12); color: #4a6830; }
.badge-herbs  { background: rgba(27,58,45,.12); color: #1b3a2d; }
.badge-table  { background: rgba(90,101,114,.12); color: #374151; }

/* ─── Responsive shared ──────────────────────────────────── */
@media (max-width: 768px) {
  .nav-links, .nav-cta { display: none; }
  .nav-hamburger { display: flex; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .footer-bottom { flex-direction: column; text-align: center; }
  .form-grid { grid-template-columns: 1fr; }
  .form-group.full { grid-column: span 1; }
}
@media (max-width: 480px) {
  .container { padding-inline: 16px; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  /* ✅ Footer column headings slightly larger on small screens */
  .footer-col h4 { font-size: .8rem; }
}
