/* =========================================================
   WhatsApp Brand Site - Global Styles (style.css)
   Theme: Monochrome + Brand Accent | Modern, Trendy, Airy
   ========================================================= */

/* --- Design Variables --- */
:root {
  /* Colors: Slate Grayscale + WhatsApp Green Accent */
  --color-bg: #ffffff;
  --color-bg-alt: #f8fafc;
  --color-surface: #ffffff;
  --color-border: #e2e8f0;
  --color-text-main: #0f172a;
  --color-text-muted: #475569;
  --color-text-faint: #94a3b8;
  
  --color-brand: #25D366;
  --color-brand-hover: #1ebd57;
  --color-brand-subtle: #dcfce7;
  
  --color-accent: #0ea5e9; /* Secondary tech blue for contrast if needed */

  /* Typography */
  --font-sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans SC", sans-serif;
  --text-base: clamp(1rem, 0.95rem + 0.25vw, 1.125rem);
  --text-xs: 0.8125rem;
  --text-sm: 0.875rem;
  --text-lg: 1.25rem;
  --text-xl: 1.5rem;
  --text-2xl: clamp(1.75rem, 1.5rem + 1vw, 2.25rem);
  --text-3xl: clamp(2rem, 1.5rem + 2.5vw, 3rem);
  
  --leading-relaxed: 1.75;
  --tracking-tight: -0.025em;

  /* Spacing & Layout */
  --container-max: 1120px;
  --space-xs: 0.5rem;
  --space-sm: 0.75rem;
  --space-md: 1.25rem;
  --space-lg: 2rem;
  --space-xl: 3.5rem;
  --space-2xl: 5rem;
  
  --radius-sm: 0.5rem;
  --radius-md: 0.75rem;
  --radius-lg: 1rem;
  --radius-xl: 1.5rem;
  --shadow-card: 0 4px 6px -1px rgb(0 0 0 / 0.05), 0 2px 4px -2px rgb(0 0 0 / 0.05);
  --shadow-float: 0 20px 25px -5px rgb(0 0 0 / 0.08), 0 8px 10px -6px rgb(0 0 0 / 0.05);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  padding: 0;
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: var(--leading-relaxed);
  color: var(--color-text-main);
  background-color: var(--color-bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img, svg { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; transition: color 0.2s ease; }
button, input, select, textarea { font: inherit; color: inherit; }

/* --- Layout Utilities --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--space-md);
}
.grid-auto { display: grid; gap: var(--space-lg); }
.grid-cols-2 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); }
.flex-center { display: flex; align-items: center; justify-content: center; }
.section { padding: var(--space-xl) 0; }
.bg-alt { background-color: var(--color-bg-alt); }

/* --- Header & Navigation --- */
.site-header {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, 0.9);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
}
.header-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 64px;
}
.brand-link { display: flex; align-items: center; gap: var(--space-sm); }
.brand-logo { width: 36px; height: 36px; object-fit: contain; }
.brand-name { font-weight: 700; font-size: var(--text-lg); letter-spacing: var(--tracking-tight); }
.nav-list { list-style: none; margin: 0; padding: 0; display: flex; gap: var(--space-lg); }
.nav-link { font-weight: 500; color: var(--color-text-muted); position: relative; }
.nav-link:hover, .nav-link[aria-current="page"] { color: var(--color-brand); }
.nav-link[aria-current="page"]::after {
  content: ""; position: absolute; bottom: -6px; left: 0; width: 100%; height: 2px;
  background: var(--color-brand); border-radius: 1px;
}
.mobile-toggle { display: none; background: none; border: none; cursor: pointer; padding: 4px; }
.mobile-toggle span { display: block; width: 24px; height: 2px; background: var(--color-text-main); margin: 5px 0; transition: 0.2s; }

@media(max-width: 768px) {
  .mobile-toggle { display: block; }
  .nav-list {
    display: none; flex-direction: column; position: absolute; top: 64px; left: 0; right: 0;
    background: var(--color-bg); border-bottom: 1px solid var(--color-border);
    padding: var(--space-md); gap: var(--space-md);
  }
  .nav-list.active { display: flex; }
}

/* --- Buttons --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: var(--space-sm);
  padding: 0.75rem 1.5rem; font-weight: 600; border-radius: var(--radius-md);
  transition: all 0.2s ease; cursor: pointer; border: 2px solid transparent;
  text-wrap: balance;
}
.btn-primary {
  background: var(--color-brand); color: #fff; box-shadow: 0 4px 14px 0 rgba(37, 211, 102, 0.3);
}
.btn-primary:hover { background: var(--color-brand-hover); transform: translateY(-1px); box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4); }
.btn-outline { border-color: var(--color-border); color: var(--color-text-main); background: transparent; }
.btn-outline:hover { border-color: var(--color-brand); color: var(--color-brand); }

/* --- Typography & Headings --- */
h1, h2, h3, h4 { line-height: 1.2; color: var(--color-text-main); letter-spacing: var(--tracking-tight); }
h1 { font-size: var(--text-3xl); margin-bottom: var(--space-md); text-wrap: balance; }
h2 { font-size: var(--text-2xl); margin-bottom: var(--space-lg); }
h3 { font-size: var(--text-xl); margin-bottom: var(--space-sm); }
p { margin: 0 0 var(--space-md) 0; }
.text-muted { color: var(--color-text-muted); }
.text-center { text-align: center; }

/* --- Cards & Components --- */
.card {
  background: var(--color-surface); border: 1px solid var(--color-border);
  border-radius: var(--radius-lg); padding: var(--space-lg);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-card); }
.icon-box {
  width: 48px; height: 48px; border-radius: var(--radius-md);
  background: var(--color-brand-subtle); color: var(--color-brand);
  display: flex; align-items: center; justify-content: center; margin-bottom: var(--space-md);
}
.icon-box svg { width: 24px; height: 24px; }

/* --- Tables --- */
.table-wrapper { overflow-x: auto; border: 1px solid var(--color-border); border-radius: var(--radius-lg); }
table { width: 100%; border-collapse: collapse; min-width: 500px; }
th, td { padding: var(--space-md); text-align: left; border-bottom: 1px solid var(--color-border); }
th { background: var(--color-bg-alt); font-weight: 600; color: var(--color-text-muted); }
tr:last-child td { border-bottom: none; }

/* --- Accordion / FAQ --- */
.faq-item { border-bottom: 1px solid var(--color-border); }
details { padding: var(--space-md) 0; }
summary {
  list-style: none; cursor: pointer; font-weight: 600; font-size: var(--text-lg);
  display: flex; justify-content: space-between; align-items: center;
}
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; font-size: 1.25rem; color: var(--color-brand); transition: transform 0.2s; }
details[open] summary::after { transform: rotate(45deg); }
details p { margin-top: var(--space-sm); color: var(--color-text-muted); }

/* --- Footer --- */
.site-footer { background: var(--color-bg-alt); border-top: 1px solid var(--color-border); padding: var(--space-xl) 0 var(--space-lg); }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: var(--space-xl); margin-bottom: var(--space-xl); }
.footer-col h4 { font-size: var(--text-sm); text-transform: uppercase; letter-spacing: 0.05em; color: var(--color-text-muted); margin-bottom: var(--space-md); }
.footer-links { list-style: none; padding: 0; margin: 0; }
.footer-links li { margin-bottom: var(--space-sm); }
.footer-links a:hover { color: var(--color-brand); }
.footer-bottom { text-align: center; color: var(--color-text-faint); font-size: var(--text-sm); border-top: 1px solid var(--color-border); padding-top: var(--space-md); }

/* --- Focus States --- */
:focus-visible { outline: 2px solid var(--color-brand); outline-offset: 2px; border-radius: 2px; }

/* --- SVG Animation Keyframes (Waveforms & Draw Effects) --- */
@keyframes wave-rise {
  0%, 100% { transform: translateY(0); opacity: 0.7; }
  50% { transform: translateY(-8px); opacity: 1; }
}
@keyframes wave-phase-shift {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(12px); }
}
@keyframes draw-path {
  from { stroke-dashoffset: 1; }
  to { stroke-dashoffset: 0; }
}
.animate-wave-1 { animation: wave-rise 4s ease-in-out infinite; }
.animate-wave-2 { animation: wave-rise 4.5s ease-in-out infinite 0.5s; }
.animate-wave-3 { animation: wave-rise 5s ease-in-out infinite 1s; }
.animate-wave-shift { animation: wave-phase-shift 6s ease-in-out infinite alternate; }
.animate-draw { animation: draw-path 2s ease forwards; }

/* Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
  .animate-wave-1, .animate-wave-2, .animate-wave-3, .animate-wave-shift, .animate-draw {
    animation: none; opacity: 1; transform: none; stroke-dashoffset: 0;
  }
}
