/* 
 * WhatsApp Official Site - Shared Stylesheet
 * Design: Light Editorial Style with Restrained Neutral Grayscale
 * Typography: Serif Headings + Sans-serif Body
 */

:root {
    /* Brand Colors - Editorial & Professional */
    --color-primary: #00a884; /* WhatsApp Green */
    --color-primary-hover: #008f6f;
    --color-secondary: #25d366;
    --color-text-main: #111b21;
    --color-text-secondary: #54656f;
    --color-bg-body: #f0f2f5; /* Subtle warm gray background */
    --color-bg-surface: #ffffff;
    --color-border: #e9edef;
    --color-accent-light: #dcf8c6;
    
    /* Spacing & Layout */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 2rem;
    --spacing-lg: 4rem;
    --spacing-xl: 6rem;
    --container-width: 1100px;
    --radius-card: 8px;
    --radius-button: 24px;
    
    /* Typography */
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    --font-serif: 'Playfair Display', Georgia, serif;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: var(--font-sans);
    color: var(--color-text-main);
    background-color: var(--color-bg-body);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

/* Typography Scaling */
h1, h2, h3, h4, h5, h6 {
    font-family: var(--font-serif);
    color: var(--color-text-main);
    font-weight: 700;
    letter-spacing: -0.02em;
    text-wrap: balance;
}

h1 { font-size: clamp(2.5rem, 5vw, 3.5rem); line-height: 1.1; margin-bottom: var(--spacing-sm); }
h2 { font-size: clamp(2rem, 4vw, 2.5rem); margin-bottom: var(--spacing-md); }
h3 { font-size: 1.5rem; margin-bottom: var(--spacing-sm); }
p { margin-bottom: 1rem; color: var(--color-text-secondary); }

/* Layout Utilities */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 var(--spacing-sm);
}

.grid-2 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: var(--spacing-md);
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: var(--spacing-md);
}

.section-padding {
    padding: var(--spacing-xl) 0;
}

.bg-white {
    background-color: var(--color-bg-surface);
}

/* Header */
.site-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    background-color: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--color-border);
    padding: var(--spacing-sm) 0;
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand-logo {
    display: flex;
    align-items: center;
    gap: var(--spacing-xs);
    text-decoration: none;
    color: var(--color-text-main);
    font-weight: 600;
    font-size: 1.25rem;
}

.brand-logo img {
    height: 32px;
    width: auto;
}

.nav-menu {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
    list-style: none;
}

.nav-link {
    text-decoration: none;
    color: var(--color-text-secondary);
    font-weight: 500;
    transition: color 0.2s ease;
}

.nav-link:hover, .nav-link[aria-current="page"] {
    color: var(--color-primary);
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    border-radius: var(--radius-button);
    font-weight: 600;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: none;
    font-size: 1rem;
}

.btn-primary {
    background-color: var(--color-primary);
    color: #fff;
}

.btn-primary:hover {
    background-color: var(--color-primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 168, 132, 0.2);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--color-border);
    color: var(--color-text-main);
}

.btn-outline:hover {
    border-color: var(--color-primary);
    color: var(--color-primary);
}

/* Hero Section */
.hero {
    padding: var(--spacing-xl) 0;
    text-align: center;
    overflow: hidden;
    position: relative;
}

.hero-content {
    max-width: 800px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-md);
}

/* SVG Animations */
.svg-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
}

svg svg-svg-animated {
    width: 100%;
    height: auto;
    overflow: visible;
}

.orbit-ring {
    fill: none;
    stroke-width: 1.5;
    pathLength: 1;
    stroke-dasharray: 1;
    stroke-dashoffset: 0;
    opacity: 0.7;
    transform-box: fill-box;
    transform-origin: center;
}

.orbit-anim-1 { animation: orbit-pulse 6s infinite alternate cubic-bezier(0.4, 0, 0.2, 1); }
.orbit-anim-2 { animation: orbit-pulse 8s infinite alternate-reverse cubic-bezier(0.4, 0, 0.2, 1); }
.orbit-anim-3 { animation: orbit-pulse 10s infinite alternate cubic-bezier(0.4, 0, 0.2, 1); }

@keyframes orbit-pulse {
    0% { stroke-dashoffset: 1; stroke-width: 1; opacity: 0.5; }
    50% { stroke-dashoffset: 0.6; stroke-width: 2; opacity: 0.9; }
    100% { stroke-dashoffset: 0; stroke-width: 1.5; opacity: 0.6; }
}

.draw-path {
    fill: none;
    stroke: var(--color-primary);
    stroke-width: 2;
    pathLength: 1;
    stroke-dasharray: 1;
    stroke-dashoffset: 0;
}

.draw-anim { animation: draw-line 4s infinite alternate ease-in-out; }

@keyframes draw-line {
    0% { stroke-dashoffset: 1; stroke-width: 1.5; opacity: 0.6; }
    50% { stroke-dashoffset: 0.5; stroke-width: 2.5; opacity: 1; }
    100% { stroke-dashoffset: 0; stroke-width: 2; opacity: 0.8; }
}

@media (prefers-reduced-motion: reduce) {
    .orbit-anim-1, .orbit-anim-2, .orbit-anim-3, .draw-anim {
        animation: none;
    }
    .orbit-ring { stroke-dashoffset: 0; }
    .draw-path { stroke-dashoffset: 0; }
}

/* Cards */
.card {
    background: var(--color-bg-surface);
    border-radius: var(--radius-card);
    padding: var(--spacing-md);
    border: 1px solid var(--color-border);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.05);
}

.card-icon {
    width: 48px;
    height: 48px;
    color: var(--color-primary);
    margin-bottom: var(--spacing-sm);
}

.card-icon svg {
    width: 100%;
    height: 100%;
    stroke: currentColor;
    stroke-width: 1.5;
    fill: none;
}

/* Tables */
.table-wrapper {
    overflow-x: auto;
    border: 1px solid var(--color-border);
    border-radius: var(--radius-card);
    background: var(--color-bg-surface);
}

table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

th, td {
    padding: 1rem;
    border-bottom: 1px solid var(--color-border);
}

th {
    background-color: #f8f9fa;
    font-weight: 600;
    color: var(--color-text-main);
}

tr:last-child td {
    border-bottom: none;
}

/* Accordion / FAQ */
details {
    background: var(--color-bg-surface);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-card);
    margin-bottom: var(--spacing-xs);
    transition: all 0.2s ease;
}

summary {
    padding: 1rem;
    cursor: pointer;
    font-weight: 600;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

summary::-webkit-details-marker {
    display: none;
}

summary::after {
    content: "+";
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--color-primary);
    transition: transform 0.2s ease;
}

details[open] summary::after {
    transform: rotate(45deg);
}

details p {
    padding: 0 1rem 1rem 1rem;
    margin-bottom: 0;
    border-top: 1px dashed var(--color-border);
    margin-top: 0.5rem;
    padding-top: 1rem;
}

/* News & Links */
.news-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.news-date {
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    margin-bottom: var(--spacing-xs);
}

.related-list {
    list-style: none;
}

.related-list li {
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--color-border);
}

.related-list a {
    text-decoration: none;
    color: var(--color-primary);
    font-weight: 500;
}

.related-list a:hover {
    text-decoration: underline;
}

.related-desc {
    display: block;
    font-size: 0.875rem;
    color: var(--color-text-secondary);
    margin-top: 0.25rem;
}

/* Footer */
.site-footer {
    background-color: var(--color-text-main);
    color: #aebac1;
    padding: var(--spacing-lg) 0;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: var(--spacing-md);
}

.footer-col h4 {
    color: #fff;
    margin-bottom: var(--spacing-sm);
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #aebac1;
    text-decoration: none;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: #fff;
}

/* Accessibility */
:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}
