/* Google Fonts are loaded via <link> tags in each page's <head> for non-blocking load */

/*
 * TECH DEBT: Nav and footer HTML is duplicated across all 8 pages (index, about, services,
 * contact, privacy, terms, solutions/3d-printing, solutions/repair-services, solutions/custom-products).
 * Any structural change to nav or footer must be applied manually to each file.
 * Resolution requires migrating to a build tool (e.g., Vite, Eleventy, or server-side includes).
 */

/* Skip navigation link for keyboard/screen reader users */
.skip-link {
    position: absolute;
    top: -100%;
    left: 0;
    padding: 0.75rem 1.5rem;
    background: var(--brand-dark, #0F172A);
    color: white;
    font-weight: 700;
    font-size: 0.9375rem;
    text-decoration: none;
    z-index: 9999;
    border-radius: 0 0 0.5rem 0;
    transition: top 0.15s ease;
}
.skip-link:focus {
    top: 0;
}

:root {
    --brand-primary: #0ea5e9;
    --brand-dark: #0F172A;
    --brand-navy: #020617;
    --brand-glow: rgba(14, 165, 233, 0.12);
    --bg-white: #FFFFFF;
    --bg-soft: #F8FAFC;
    --text-main: #1E293B;
    --text-muted: #64748B;
    --border-light: #E2E8F0;
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
    --shadow-premium: 0 25px 50px -12px rgba(15, 23, 42, 0.15);
    --radius-lg: 1rem;
    --container-max: 1280px;
    --transition-premium: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

.brand-logo-text {
    font-family: 'Playfair Display', Georgia, serif;
    font-weight: 700;
    color: var(--brand-dark);
    font-size: 1.75rem;
    letter-spacing: -0.5px;
}

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

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-main);
    background-color: var(--bg-soft);
    line-height: 1.6;
    overflow-x: hidden;
}

h1, h2, h3, h4 {
    letter-spacing: -0.025em;
    color: var(--brand-dark);
}

.container {
    max-width: var(--container-max);
    margin: 0 auto;
    padding: 0 2rem;
}

/* Elite Spacing */
section {
    padding: 120px 0;
}

/* Premium Navigation */
.nav-main {
    height: 80px;
    display: flex;
    align-items: center;
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    z-index: 1000;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

/* Elite Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.75rem 1.5rem;
    font-weight: 600;
    border-radius: 0.75rem;
    transition: var(--transition-premium);
    cursor: pointer;
    text-decoration: none;
    font-size: 0.9375rem;
}

.btn-primary {
    /* #0369a1 on white = 5.3:1 contrast ratio — passes WCAG AA */
    background: #0369a1;
    color: white;
    border: 1px solid #0369a1;
}

.btn-primary:hover {
    background: #075985;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px -5px rgba(3, 105, 161, 0.4);
}

.btn-secondary {
    background: white;
    color: var(--brand-dark);
    border: 1px solid var(--border-light);
}

.btn-secondary:hover {
    background: var(--bg-soft);
    border-color: var(--brand-dark);
    transform: translateY(-2px);
}

/* Card Systems */
.card-enterprise {
    background: white;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    transition: var(--transition-premium);
    padding: 2.5rem;
    box-shadow: var(--shadow-sm);
    height: 100%;
}

.card-enterprise:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-premium);
    border-color: var(--brand-primary);
}

/* Icon Wrap */
.icon-box {
    width: 48px;
    height: 48px;
    background: var(--brand-glow);
    color: var(--brand-primary);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
}

/* Badge Premium */
.badge-elite,
.badge-premium {
    display: inline-block;
    padding: 0.5rem 1rem;
    background: var(--brand-glow);
    color: var(--brand-primary);
    border-radius: 100px;
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1.5rem;
}

/* Solution Grid */
.solution-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2.5rem;
}

/* ---- Mobile hamburger button ---- */
.nav-hamburger {
    display: none;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    width: 40px;
    height: 40px;
    flex-shrink: 0;
}
.nav-hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--brand-dark);
    border-radius: 2px;
    transition: all 0.3s ease;
}

/* ---- Mobile slide-down menu ---- */
.mobile-menu {
    display: none;
    position: fixed;
    top: 80px;
    left: 0;
    right: 0;
    background: white;
    border-bottom: 1px solid var(--border-light);
    padding: 1.5rem 2rem 2rem;
    flex-direction: column;
    gap: 0;
    z-index: 998;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
}
.mobile-menu.open { display: flex; }
.mobile-menu .mobile-nav-link {
    display: block;
    font-size: 1.0625rem;
    font-weight: 700;
    color: var(--brand-dark);
    text-decoration: none;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-light);
}
.mobile-menu-ctas {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    padding-top: 1.25rem;
}
.mobile-menu-ctas .btn {
    width: 100%;
    text-align: center;
    justify-content: center;
}

/* ---- Responsive breakpoints ---- */
@media (max-width: 900px) {
    /* Show hamburger, hide desktop nav items */
    .nav-hamburger { display: flex; }
    .nav-desktop-links,
    .nav-desktop-ctas { display: none !important; }

    /* Collapse ALL inline-styled CSS grids to single column */
    [style*="grid-template-columns"] {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    /* Tighten container padding */
    .container { padding: 0 1.25rem !important; }

    /* Reduce section padding */
    section { padding: 60px 0 !important; }

    /* Scale down headings */
    h1 { font-size: 2.5rem !important; letter-spacing: -1px !important; }
    h2 { font-size: 2rem !important; }
    h3 { font-size: 1.5rem !important; }
}

@media (max-width: 768px) {
    .solution-grid { grid-template-columns: 1fr; }
}

/* Animations — progressive enhancement: only hide when JS has confirmed it's ready */
.reveal {
    transition: opacity 0.6s cubic-bezier(0.4, 0, 0.2, 1), transform 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.js-ready .reveal {
    opacity: 0;
    transform: translateY(20px);
}

.js-ready .reveal.active {
    opacity: 1;
    transform: translateY(0);
}

/* ----- WOW FACTOR AESTHETICS ----- */
.gradient-text,
.text-gradient {
    background: linear-gradient(135deg, #0ea5e9 0%, #6366f1 50%, #a855f7 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-size: 200% auto;
    animation: shine 4s linear infinite;
    display: inline-block;
}

@keyframes shine {
    to { background-position: 200% center; }
}

.glow-btn {
    position: relative;
    z-index: 1;
    overflow: hidden;
    box-shadow: 0 10px 30px -5px rgba(14, 165, 233, 0.5);
}

.glow-btn::after {
    content: '';
    position: absolute;
    top: 0; left: -100%; width: 50%; height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.3) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    animation: swipe 3s infinite;
    z-index: 10;
}

@keyframes swipe {
    0% { left: -100%; }
    50% { left: 200%; }
    100% { left: 200%; }
}

.float-anim {
    animation: float 6s ease-in-out infinite;
}

@keyframes float {
    0% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
    100% { transform: translateY(0px); }
}

.custom-glass-card {
    background: rgba(255, 255, 255, 0.6);
    backdrop-filter: blur(24px);
    -webkit-backdrop-filter: blur(24px);
    border: 1px solid rgba(255, 255, 255, 0.8);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255,255,255,1);
}

.bg-hero-glow {
    background-color: #f8fafc;
    background-image: 
        radial-gradient(at 0% 0%, rgba(14, 165, 233, 0.15) 0px, transparent 50%),
        radial-gradient(at 100% 0%, rgba(168, 85, 247, 0.15) 0px, transparent 50%);
}
