:root {
    /* Apple System Colors */
    --color-bg-body: #ffffff;
    --color-bg-alt: #f5f5f7; /* Apple Store Light Gray */
    --color-text-primary: #1d1d1f;
    --color-text-secondary: #86868b;
    --color-accent: #0071e3; /* Apple Blue */
    --color-accent-hover: #0077ed;
    --color-nav-bg: rgba(22, 22, 23, 0.8); /* Dark Nav */
    --color-nav-text: #e8e8ed;
    --color-nav-text-hover: #ffffff;
    --color-border: #d2d2d7;
    
    /* Typography */
    --font-family-base: "SF Pro Text", "SF Pro Icons", "Helvetica Neue", "Helvetica", "Arial", sans-serif;
    --font-size-base: 19px;
    --font-size-h1: 64px;
    --font-size-h2: 48px;
    
    /* Layout */
    --container-width: 1200px;
    --header-height: 64px;
    --border-radius-card: 18px;
    --transition-speed: 0.3s;
}

/* Reset */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    -webkit-font-smoothing: antialiased;
}

body {
    font-family: var(--font-family-base);
    background-color: var(--color-bg-body);
    color: var(--color-text-primary);
    line-height: 1.47059;
    font-weight: 400;
    letter-spacing: -0.022em;
}

a {
    text-decoration: none;
    color: var(--color-accent);
    transition: color 0.2s ease;
}

a:hover {
    text-decoration: underline;
}

ul { list-style: none; }
img { display: block; max-width: 100%; height: auto; }

/* Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 22px;
}

/* Header - Apple.com Global Nav Style */
.header {
    position: sticky;
    top: 0;
    z-index: 9999;
    height: var(--header-height);
    background-color: var(--color-nav-bg);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    width: 100%;
}

.header__container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    max-width: 84%;
    margin: 0 auto;
    padding: 0 22px;
}

.header__logo {
    color: var(--color-nav-text);
    font-size: 24px;
    font-weight: 600;
    letter-spacing: -0.01em;
    transition: opacity 0.2s;
}

.header__logo:hover {
    opacity: 0.8;
    text-decoration: none;
}

.header__logo-highlight {
    color: #fff;
}

.header__nav {
    height: 100%;
    display: flex;
}

.header__menu {
    display: flex;
    height: 100%;
    align-items: center;
    gap: 32px;
}

.header__link {
    color: var(--color-nav-text);
    font-size: 16px;
    font-weight: 400;
    letter-spacing: -0.01em;
    opacity: 0.8;
    transition: opacity 0.2s;
}

.header__link:hover {
    color: var(--color-nav-text-hover);
    opacity: 1;
    text-decoration: none;
}

.header__cta {
    font-size: 14px;
    background: #fff;
    color: #000 !important;
    padding: 8px 20px;
    border-radius: 980px;
    opacity: 1;
}

.header__cta:hover {
    background: #f5f5f7;
    text-decoration: none;
}

/* Dropdown Menu */
.header__menu-item {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

.header__dropdown {
    position: absolute;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    background-color: rgba(22, 22, 23, 0.95);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: 1000;
    margin-top: 10px;
    border: 1px solid rgba(255,255,255,0.1);
}

.header__menu-item:hover .header__dropdown {
    opacity: 1;
    visibility: visible;
    margin-top: 0;
}

.header__dropdown-inner {
    display: flex;
    flex-direction: column;
    gap: 12px;
    text-align: center;
}

.dropdown-link {
    color: var(--color-nav-text);
    font-size: 14px;
    white-space: nowrap;
    transition: color 0.2s;
    display: block;
}

.dropdown-link:hover {
    color: var(--color-accent);
    text-decoration: none;
}

.header__dropdown::before {
    content: '';
    position: absolute;
    top: -6px;
    left: 50%;
    transform: translateX(-50%);
    border-left: 6px solid transparent;
    border-right: 6px solid transparent;
    border-bottom: 6px solid rgba(22, 22, 23, 0.95);
}

/* Mobile Toggle */
.header__toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    flex-direction: column;
    gap: 4px;
}

.header__toggle-bar {
    width: 18px;
    height: 1px;
    background-color: var(--color-nav-text);
    transition: 0.3s;
}

/* Global Button Styles */
.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 14px 30px;
    border-radius: 980px;
    font-size: 19px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
    cursor: pointer;
    border: 1px solid transparent;
    line-height: 1.2;
}

.button:active {
    transform: scale(0.98);
}

.button--primary {
    background-color: var(--color-accent);
    color: #fff;
}

.button--primary:hover {
    background-color: var(--color-accent-hover);
    text-decoration: none;
}

.button--outline {
    background-color: transparent;
    border-color: var(--color-accent);
    color: var(--color-accent);
}

.button--outline:hover {
    background-color: var(--color-accent);
    color: #fff;
    text-decoration: none;
}

.button--sm {
    font-size: 16px;
    padding: 8px 20px;
}

.button--text {
    background: none;
    color: var(--color-accent);
    padding: 0;
    font-size: 14px;
}

.button--text:hover {
    text-decoration: underline;
}

/* Footer - Apple Style */
.footer {
    background-color: var(--color-bg-alt);
    padding: 60px 0 40px;
    font-size: 12px;
    color: var(--color-text-secondary);
    border-top: 1px solid var(--color-border);
    text-align: center;
}

.footer__cta {
    text-align: center;
    margin-bottom: 60px;
    padding-bottom: 60px;
    border-bottom: 1px solid var(--color-border);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.footer__cta h3 {
    font-size: 40px;
    color: var(--color-text-primary);
    margin-bottom: 30px;
    font-weight: 700;
    letter-spacing: -0.01em;
}

.footer__cta .button {
    padding: 14px 40px;
    font-size: 18px;
}

.footer__links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.footer__links a {
    color: var(--color-text-secondary);
}

.footer__links a:hover {
    text-decoration: underline;
    color: var(--color-text-primary);
}

.footer__copyright {
    text-align: center;
}

/* Animations */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.8s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Responsive */
@media (max-width: 1023px) {
    :root {
        --font-size-h1: 40px;
    }
}

@media (max-width: 767px) {
    :root {
        --font-size-h1: 32px;
        --header-height: 48px;
    }

    .header__toggle {
        display: flex;
    }

    .header__nav {
        position: fixed;
        top: var(--header-height);
        left: 0;
        width: 100%;
        height: 0;
        background-color: rgba(22, 22, 23, 0.95);
        backdrop-filter: blur(20px);
        overflow: hidden;
        transition: height 0.4s cubic-bezier(0.4, 0, 0.2, 1);
        flex-direction: column;
        padding: 0;
    }

    .header__nav.active {
        height: calc(100vh - var(--header-height));
        padding: 40px 20px;
        overflow-y: auto;
    }

    .header__menu {
        flex-direction: column;
        width: 100%;
        height: auto;
        gap: 0;
    }

    .header__menu-item {
        width: 100%;
        height: auto;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        flex-direction: column;
        align-items: flex-start;
    }

    .header__link {
        display: block;
        width: 100%;
        padding: 16px 0;
        font-size: 17px;
        color: #fff;
        opacity: 1;
    }

    .header__cta {
        display: inline-block;
        margin-top: 20px;
        width: 100%;
        text-align: center;
    }

    /* Mobile Dropdown */
    .header__dropdown {
        position: static;
        transform: none;
        background: transparent;
        box-shadow: none;
        border: none;
        padding: 0 0 16px 20px;
        opacity: 1;
        visibility: visible;
        display: none; /* Hidden by default on mobile, maybe toggle? */
        min-width: auto;
        margin-top: 0;
    }
    
    .header__menu-item:hover .header__dropdown {
        display: block; /* Show on hover/click simulation */
    }

    .header__dropdown::before {
        display: none;
    }

    .dropdown-link {
        color: #86868b;
        padding: 8px 0;
        text-align: left;
    }

    /* Toggle Animation */
    .header__toggle.active .header__toggle-bar:nth-child(1) {
        transform: translateY(5px) rotate(45deg);
    }
    .header__toggle.active .header__toggle-bar:nth-child(2) {
        opacity: 0;
    }
    .header__toggle.active .header__toggle-bar:nth-child(3) {
        transform: translateY(-5px) rotate(-45deg);
    }
}
