/* ============================================================
   NSF GLOBAL — Apple-grade custom theme
   Inspired by Apple.com, Stripe, Linear
   ============================================================ */

:root {
    --nsf-bg: #ffffff;
    --nsf-bg-soft: #fafafa;
    --nsf-fg: #1d1d1f;
    --nsf-fg-soft: #6e6e73;
    --nsf-fg-muted: #86868b;
    --nsf-border: rgba(0, 0, 0, 0.06);
    --nsf-border-strong: rgba(0, 0, 0, 0.12);
    --nsf-gold: #c9a96e;
    --nsf-gold-dark: #8b6f3f;
    --nsf-radius: 14px;
    --nsf-radius-sm: 10px;
    --nsf-radius-lg: 20px;
    --nsf-shadow-sm: 0 0 0 0.5px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.04);
    --nsf-shadow-md: 0 0 0 0.5px rgba(0,0,0,0.04), 0 1px 2px rgba(0,0,0,0.04), 0 8px 24px -12px rgba(0,0,0,0.06);
    --nsf-shadow-lg: 0 0 0 0.5px rgba(0,0,0,0.06), 0 2px 4px rgba(0,0,0,0.05), 0 16px 36px -16px rgba(0,0,0,0.12);
}

/* ===== Typography ===== */
body {
    font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Inter", "Segoe UI", system-ui, sans-serif !important;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
    color: var(--nsf-fg);
    background: var(--nsf-bg);
    line-height: 1.6;
}

h1, h2, h3, h4, h5, h6,
.entry-title, .site-title, .page-title {
    font-family: inherit !important;
    color: var(--nsf-fg);
    letter-spacing: -0.022em;
    font-weight: 700;
    line-height: 1.15;
}

h1, .entry-title { font-size: clamp(36px, 5vw, 56px); letter-spacing: -0.028em; }
h2 { font-size: clamp(28px, 3.5vw, 40px); letter-spacing: -0.025em; }
h3 { font-size: clamp(20px, 2.5vw, 28px); letter-spacing: -0.02em; }
h4 { font-size: 18px; }

p, li { color: var(--nsf-fg); font-size: 16px; line-height: 1.65; }
.lead, .hero-subtitle { font-size: 19px; color: var(--nsf-fg-soft); }

/* ===== Layout ===== */
.site, .ast-container, .entry-content > * {
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}
.entry-content { padding: 24px; }

/* ===== Header ===== */
.ast-primary-header-bar, .site-header {
    background: rgba(255, 255, 255, 0.82) !important;
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid var(--nsf-border) !important;
    box-shadow: none !important;
    position: sticky !important;
    top: 0;
    z-index: 100;
}
.site-title a {
    font-weight: 700 !important;
    letter-spacing: -0.02em !important;
    color: var(--nsf-fg) !important;
}
.main-header-menu .menu-link,
.ast-builder-menu-1 .menu-link {
    font-size: 14.5px !important;
    font-weight: 500 !important;
    color: var(--nsf-fg) !important;
    letter-spacing: -0.005em !important;
    transition: color 0.18s ease !important;
}
.main-header-menu .menu-link:hover,
.ast-builder-menu-1 .menu-link:hover {
    color: var(--nsf-gold-dark) !important;
}

/* ===== Buttons ===== */
.wp-block-button__link,
.button,
.ast-button,
button[type="submit"] {
    background: linear-gradient(180deg, #1d1d1f 0%, #000 100%) !important;
    color: #fff !important;
    border: none !important;
    padding: 12px 24px !important;
    border-radius: var(--nsf-radius-sm) !important;
    font-size: 15px !important;
    font-weight: 600 !important;
    letter-spacing: -0.01em !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.15), inset 0 1px 0 rgba(255,255,255,0.16) !important;
    transition: transform 0.12s ease, box-shadow 0.18s ease, background 0.18s ease !important;
    text-decoration: none !important;
    display: inline-flex !important;
    align-items: center !important;
    gap: 8px !important;
}
.wp-block-button__link:hover,
.button:hover,
.ast-button:hover,
button[type="submit"]:hover {
    background: linear-gradient(180deg, #2d2d2f 0%, #111 100%) !important;
    box-shadow: 0 4px 12px rgba(0,0,0,0.18), inset 0 1px 0 rgba(255,255,255,0.16) !important;
    transform: translateY(-1px);
}
.wp-block-button.is-style-outline .wp-block-button__link {
    background: rgba(120,120,128,0.10) !important;
    color: var(--nsf-fg) !important;
    box-shadow: none !important;
}

/* Gold accent button */
.wp-block-button.is-style-gold .wp-block-button__link {
    background: linear-gradient(180deg, #c9a96e 0%, #8b6f3f 100%) !important;
    color: #fff !important;
}

/* ===== Cards / sections ===== */
.wp-block-group, .wp-block-column {
    border-radius: var(--nsf-radius);
}
.nsf-card {
    background: #fff;
    border-radius: var(--nsf-radius);
    border: 1px solid var(--nsf-border);
    padding: 32px;
    box-shadow: var(--nsf-shadow-sm);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}
.nsf-card:hover {
    box-shadow: var(--nsf-shadow-lg);
    transform: translateY(-2px);
}

/* ===== Hero section ===== */
.nsf-hero {
    padding: 120px 24px 80px;
    text-align: center;
    background: linear-gradient(180deg, #fafafa 0%, #fff 100%);
}
.nsf-hero-eyebrow {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    color: var(--nsf-gold-dark);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 20px;
}
.nsf-hero h1 {
    font-size: clamp(40px, 6vw, 64px);
    letter-spacing: -0.032em;
    line-height: 1.05;
    max-width: 900px;
    margin: 0 auto;
}
.nsf-hero h1 .accent {
    background: linear-gradient(135deg, var(--nsf-gold) 0%, var(--nsf-gold-dark) 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}
.nsf-hero .lead {
    font-size: 20px;
    color: var(--nsf-fg-soft);
    margin: 24px auto 40px;
    max-width: 640px;
    line-height: 1.5;
}

/* ===== Stats strip ===== */
.nsf-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
    padding: 64px 24px;
    max-width: 1100px;
    margin: 0 auto;
    text-align: center;
}
.nsf-stat-value {
    font-size: clamp(36px, 5vw, 52px);
    font-weight: 700;
    letter-spacing: -0.028em;
    color: var(--nsf-fg);
    line-height: 1;
}
.nsf-stat-label {
    font-size: 13px;
    color: var(--nsf-fg-soft);
    margin-top: 8px;
    font-weight: 500;
    letter-spacing: 0.03em;
    text-transform: uppercase;
}

/* ===== Product grid ===== */
.nsf-product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    padding: 24px;
}
.nsf-product-card {
    background: #fff;
    border-radius: var(--nsf-radius-lg);
    overflow: hidden;
    border: 1px solid var(--nsf-border);
    box-shadow: var(--nsf-shadow-sm);
    transition: all 0.25s ease;
}
.nsf-product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--nsf-shadow-lg);
}
.nsf-product-card img {
    width: 100%;
    aspect-ratio: 4/3;
    object-fit: cover;
}
.nsf-product-card-body {
    padding: 24px;
}
.nsf-product-category {
    font-size: 11px;
    font-weight: 600;
    color: var(--nsf-gold-dark);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 8px;
}
.nsf-product-card h3 {
    margin: 0 0 8px 0;
    font-size: 19px;
    letter-spacing: -0.015em;
}

/* ===== Team grid ===== */
.nsf-team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    padding: 24px;
}
.nsf-team-card {
    text-align: center;
    padding: 24px;
    background: var(--nsf-bg-soft);
    border-radius: var(--nsf-radius);
}
.nsf-team-card img {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    object-fit: cover;
    margin: 0 auto 16px;
    box-shadow: var(--nsf-shadow-sm);
}
.nsf-team-name {
    font-weight: 600;
    font-size: 16px;
    margin: 0 0 4px;
    color: var(--nsf-fg);
}
.nsf-team-role {
    font-size: 13px;
    color: var(--nsf-fg-soft);
}

/* ===== Section spacing ===== */
.nsf-section {
    padding: 80px 24px;
}
.nsf-section-eyebrow {
    font-size: 12px;
    font-weight: 600;
    color: var(--nsf-gold-dark);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 12px;
    text-align: center;
}
.nsf-section h2 {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 16px;
}
.nsf-section .lead {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 48px;
    color: var(--nsf-fg-soft);
    font-size: 19px;
}

/* ===== Footer ===== */
.site-footer,
.ast-footer-overlay {
    background: #0a0a0b !important;
    color: #c7c7cc !important;
    padding: 64px 24px 32px !important;
}
.site-footer h2, .site-footer h3, .site-footer h4 {
    color: #ffffff !important;
    font-size: 14px !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    margin-bottom: 16px !important;
}
.site-footer a {
    color: #c7c7cc !important;
    text-decoration: none !important;
    transition: color 0.18s ease !important;
}
.site-footer a:hover {
    color: var(--nsf-gold) !important;
}
.site-footer p {
    color: #98989d !important;
    font-size: 13.5px !important;
}

/* ===== Images ===== */
img {
    max-width: 100%;
    height: auto;
    border-radius: var(--nsf-radius-sm);
}
.wp-block-image img {
    border-radius: var(--nsf-radius);
    box-shadow: var(--nsf-shadow-sm);
}

/* ===== Forms ===== */
input[type="text"], input[type="email"], input[type="tel"], textarea, select {
    background: #fff !important;
    border: 1px solid var(--nsf-border-strong) !important;
    border-radius: var(--nsf-radius-sm) !important;
    padding: 12px 14px !important;
    font-size: 15px !important;
    transition: border-color 0.15s ease, box-shadow 0.15s ease !important;
}
input[type="text"]:focus, input[type="email"]:focus, input[type="tel"]:focus, textarea:focus, select:focus {
    border-color: #0071e3 !important;
    box-shadow: 0 0 0 3.5px rgba(0, 113, 227, 0.18) !important;
    outline: none !important;
}

/* ===== WPForms refinements ===== */
.wpforms-form .wpforms-field-label {
    font-weight: 500 !important;
    color: var(--nsf-fg) !important;
    font-size: 14px !important;
    margin-bottom: 8px !important;
}

/* ===== Selection highlight ===== */
::selection { background: rgba(201, 169, 110, 0.25); color: var(--nsf-fg); }

/* ===== Smooth transitions ===== */
a, button { transition: color 0.18s ease, background 0.18s ease, transform 0.18s ease; }

/* ===== Mobile refinements ===== */
@media (max-width: 768px) {
    .nsf-hero { padding: 80px 20px 60px; }
    .nsf-section { padding: 56px 20px; }
    .nsf-stats { gap: 24px; padding: 48px 20px; }
    .entry-content { padding: 16px; }
}

/* ===== Reduced motion ===== */
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}
