/* home.css — front-page styles. Loads after store.css, so it rides the amber/black
   design tokens (:root dark, html[data-theme="light"] overrides) and reuses .product-card,
   .products-grid, .hero-grid, .hero-glow, .store-eyebrow, .store-title, .store-sub,
   .theme-toggle and the navbar/footer dark overrides already defined there.
   The homepage is now part of the dual-theme system (see kapihub_is_themed_page). */

/* ── Hero ── animated amber gradient background (replaces the old Pexels video) ── */
.home-hero {
    position: relative;
    min-height: calc(100vh - 72px);
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    background: var(--bg);
}

/* Drifting aurora blobs — two soft amber radial glows that slowly orbit. GPU-friendly
   (transform/opacity only). Disabled under prefers-reduced-motion (bottom of file). */
.hero-aurora { position: absolute; inset: -20%; pointer-events: none; z-index: 0; }
.hero-aurora::before,
.hero-aurora::after {
    content: "";
    position: absolute;
    width: 60vw;
    height: 60vw;
    max-width: 760px;
    max-height: 760px;
    border-radius: 50%;
    filter: blur(60px);
    opacity: 0.55;
    will-change: transform;
}
.hero-aurora::before {
    top: 4%; left: 8%;
    background: radial-gradient(circle, var(--amber-g) 0%, transparent 65%);
    animation: aurora-a 22s ease-in-out infinite alternate;
}
.hero-aurora::after {
    bottom: 0%; right: 6%;
    background: radial-gradient(circle, rgba(196,122,9,0.22) 0%, transparent 65%);
    animation: aurora-b 28s ease-in-out infinite alternate;
}

@keyframes aurora-a {
    0%   { transform: translate3d(0, 0, 0) scale(1); }
    100% { transform: translate3d(14vw, 8vh, 0) scale(1.18); }
}
@keyframes aurora-b {
    0%   { transform: translate3d(0, 0, 0) scale(1.1); }
    100% { transform: translate3d(-12vw, -10vh, 0) scale(0.9); }
}

/* hero-glow (from store.css) gets a gentle breathing pulse here */
.home-hero .hero-glow { animation: hero-pulse 9s ease-in-out infinite; }
@keyframes hero-pulse { 0%, 100% { opacity: 0.85; } 50% { opacity: 1; } }

.home-hero .hero-content {
    position: relative;
    z-index: 2;
    max-width: 880px;
    padding: 56px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.home-hero .store-eyebrow { display: inline-flex; align-items: center; gap: 8px; }
.home-hero .store-title { font-size: clamp(40px, 6.2vw, 76px); margin-bottom: 22px; }
.home-hero .store-sub { font-size: 17px; max-width: 620px; margin-bottom: 30px; }

/* Feature chips */
.home-hero .hero-features {
    display: inline-flex;
    align-items: center;
    gap: 18px;
    flex-wrap: wrap;
    justify-content: center;
    background: var(--surf);
    border: 1px solid var(--bdr);
    padding: 12px 26px;
    border-radius: 100px;
    margin-bottom: 34px;
    box-shadow: var(--shadow-rest);
}
.home-hero .hero-features span { display: inline-flex; align-items: center; gap: 8px; font-size: 14px; color: var(--text); font-weight: 500; }
.home-hero .hero-features i { color: var(--amber); }
.home-hero .hero-features .feature-dot { color: var(--faint); }

/* Hero buttons */
.hero-buttons { display: flex; gap: 14px; flex-wrap: wrap; justify-content: center; }
.btn-hero-primary,
.btn-hero-ghost {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    padding: 15px 32px;
    border-radius: 100px;
    font-family: var(--fb);
    font-size: 15px;
    font-weight: 600;
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, border-color 0.2s ease;
}
.btn-hero-primary {
    background: var(--amber);
    color: var(--on-amber);
    border: 1px solid var(--amber);
    box-shadow: 0 8px 24px rgba(240,160,26,0.22);
}
.btn-hero-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(240,160,26,0.32); }
.btn-hero-ghost {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--bdr);
}
.btn-hero-ghost:hover { transform: translateY(-2px); border-color: var(--amber-b); color: var(--amber); }

/* ── Shared section layout ── */
.section-inner { max-width: 1200px; margin: 0 auto; padding: 0 40px; }
.section-head { text-align: center; max-width: 640px; margin: 0 auto 44px; }
.section-head .store-eyebrow { margin-bottom: 14px; }
.section-head h2 { font-family: var(--fd); font-size: clamp(28px, 4vw, 42px); font-weight: 500; color: var(--text); line-height: 1.1; margin-bottom: 12px; letter-spacing: -0.5px; }
.section-head p { font-size: 15px; color: var(--muted); font-weight: 300; line-height: 1.6; }

/* ── Trust strip ── */
.home-trust { border-top: 1px solid var(--bdr); border-bottom: 1px solid var(--bdr); background: var(--surf); }
.trust-inner { max-width: 1100px; margin: 0 auto; padding: 22px 40px; display: flex; flex-wrap: wrap; justify-content: space-around; gap: 18px; }
.trust-item { display: inline-flex; align-items: center; gap: 12px; color: var(--muted); font-size: 14px; }
.trust-item i { color: var(--amber); font-size: 20px; }
.trust-item strong { color: var(--text); font-weight: 600; }

/* ── Services ── */
.home-services { padding: 84px 0; background: var(--bg); }
.services-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.service-card {
    background: var(--surf);
    border: 1px solid var(--bdr);
    border-radius: 14px;
    padding: 30px 26px;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-card); border-color: var(--amber-b); }
.service-icon {
    width: 52px; height: 52px;
    background: var(--amber-f);
    border: 1px solid var(--amber-b);
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 22px; color: var(--amber);
    margin-bottom: 18px;
}
.service-card h3 { font-size: 17px; font-weight: 600; color: var(--text); margin-bottom: 10px; }
.service-card p { font-size: 14px; color: var(--muted); line-height: 1.7; font-weight: 300; }

/* ── How it works ── */
.home-steps { padding: 84px 0; background: var(--surf); border-top: 1px solid var(--bdr); border-bottom: 1px solid var(--bdr); }
.steps-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
.step-card {
    position: relative;
    background: var(--bg);
    border: 1px solid var(--bdr);
    border-radius: 14px;
    padding: 34px 24px 28px;
    text-align: center;
    transition: transform 0.25s ease, border-color 0.25s ease;
}
.step-card:hover { transform: translateY(-4px); border-color: var(--amber-b); }
.step-num {
    position: absolute;
    top: -16px; left: 50%; transform: translateX(-50%);
    width: 34px; height: 34px;
    background: var(--amber); color: var(--on-amber);
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-family: var(--fb); font-weight: 700; font-size: 15px;
}
.step-icon { font-size: 30px; color: var(--amber); margin: 8px 0 16px; }
.step-card h3 { font-size: 16px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.step-card p { font-size: 13.5px; color: var(--muted); line-height: 1.6; font-weight: 300; }

/* ── Featured products ── */
.home-featured { padding: 84px 0; background: var(--bg); }
.home-featured .products-grid { margin-bottom: 0; }
.featured-cta { text-align: center; margin-top: 40px; }

/* ── Closing CTA band ── */
.home-cta { padding: 76px 40px; background: var(--surf); border-top: 1px solid var(--bdr); }
.cta-inner { max-width: 680px; margin: 0 auto; text-align: center; }
.cta-inner h2 { font-family: var(--fd); font-size: clamp(28px, 4vw, 44px); font-weight: 500; color: var(--text); margin-bottom: 14px; letter-spacing: -0.5px; }
.cta-inner p { font-size: 15px; color: var(--muted); font-weight: 300; line-height: 1.6; margin-bottom: 28px; }
.btn-cta {
    display: inline-flex; align-items: center; gap: 10px;
    padding: 16px 36px;
    background: var(--amber); color: var(--on-amber);
    border-radius: 100px;
    font-family: var(--fb); font-weight: 700; font-size: 17px;
    box-shadow: 0 8px 24px rgba(240,160,26,0.22);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn-cta:hover { transform: translateY(-2px); box-shadow: 0 12px 30px rgba(240,160,26,0.32); }

/* ── Light-theme atmospheric overrides (aurora bakes amber alphas, can't ride one token) ── */
html[data-theme="light"] .hero-aurora::before { background: radial-gradient(circle, rgba(181,114,8,0.16) 0%, transparent 65%); opacity: 0.7; }
html[data-theme="light"] .hero-aurora::after  { background: radial-gradient(circle, rgba(216,154,42,0.18) 0%, transparent 65%); opacity: 0.7; }

/* ── Responsive ── */
@media (max-width: 920px) {
    .services-grid { grid-template-columns: repeat(2, 1fr); }
    .steps-grid { grid-template-columns: repeat(2, 1fr); gap: 28px 18px; }
    .section-inner { padding: 0 24px; }
}

@media (max-width: 600px) {
    .home-hero { min-height: 88vh; }
    .home-hero .hero-content { padding: 40px 20px; }
    .services-grid { grid-template-columns: 1fr; }
    .steps-grid { grid-template-columns: 1fr; gap: 30px; }
    .hero-buttons { width: 100%; }
    .btn-hero-primary, .btn-hero-ghost { flex: 1; justify-content: center; }
    .trust-inner { gap: 14px 24px; padding: 20px 24px; }
    .trust-item { font-size: 13px; }
    .home-services, .home-steps, .home-featured { padding: 60px 0; }
}

/* ── Reduced motion: kill the drift/pulse/shine animations ── */
@media (prefers-reduced-motion: reduce) {
    .hero-aurora::before, .hero-aurora::after,
    .home-hero .hero-glow,
    .home-hero .store-title em { animation: none !important; }
}
