﻿:root {
    /* Neutrals (light-first) */
    --bg: #FFFFFF;
    --bg-soft: #F7F5FF;
    --bg-line: #EFEBFF;

    /* Deep navy for dark sections */
    --bg-navy: #0B0A24;
    --bg-navy-2: #14113A;

    /* Text */
    --text: #0F0B2A;
    --text-2: #4A4770;
    --text-3: #6A6A85;
    --text-inv: #FFFFFF;
    --text-inv-2: rgba(255,255,255,0.72);
    --text-inv-3: rgba(255,255,255,0.5);

    /* Lines */
    --line: rgba(15,11,42,0.08);
    --line-2: rgba(15,11,42,0.12);

    /* Primary indigo accent */
    --accent: #5B4EFA;
    --accent-hi: #7A6EF5;
    --accent-deep: #3A2FBE;
    --accent-soft: rgba(91,78,250,0.10);
    --accent-glow: rgba(91,78,250,0.28);

    /* Per-product override (defaults to indigo) */
    --product-color: var(--accent);
    --product-color-soft: rgba(91,78,250,0.10);
    --product-color-border: rgba(91,78,250,0.28);

    /* Motion */
    --ease: cubic-bezier(0.16, 1, 0.3, 1);

    /* Type */
    --font-display: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, 'Inter Tight', 'Söhne', system-ui, sans-serif;
    --font-sans: 'Pretendard Variable', Pretendard, -apple-system, BlinkMacSystemFont, system-ui, 'Apple SD Gothic Neo', sans-serif;
    --font-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, monospace;

    /* Layout */
    --page-max: 1280px;
    --pad-x: clamp(20px, 4.5vw, 48px);
    --nav-h: 68px;
}

/* Per-product color palettes (used for hero pill, feature icons, links) */
body[data-product="viewer"], body[data-product="designer"] {
    --product-color: #F26D22;
    --product-color-soft: rgba(242,109,34,0.10);
    --product-color-border: rgba(242,109,34,0.28);
}
body[data-product="trend"] {
    --product-color: #38BDF8;
    --product-color-soft: rgba(56,189,248,0.10);
    --product-color-border: rgba(56,189,248,0.32);
}
body[data-product="alarm"] {
    --product-color: #FBBF24;
    --product-color-soft: rgba(251,191,36,0.12);
    --product-color-border: rgba(251,191,36,0.32);
}
body[data-product="insight"] {
    --product-color: #A78BFA;
    --product-color-soft: rgba(167,139,250,0.10);
    --product-color-border: rgba(167,139,250,0.30);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--font-sans);
    font-size: 16px; line-height: 1.55;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
    letter-spacing: -0.011em;
}
::selection { background: var(--accent); color: #fff; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

.container {
    max-width: var(--page-max); margin: 0 auto;
    padding: 0 var(--pad-x); position: relative; z-index: 1;
}

/* i18n */
[data-lang]:not(.is-active) { display: none; }
[data-lang].is-active { display: revert; }
span[data-lang].is-active { display: inline; }

/* Reveal */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-visible { opacity: 1; transform: translateY(0); }
.reveal.d1 { transition-delay: 0.08s; }
.reveal.d2 { transition-delay: 0.16s; }
.reveal.d3 { transition-delay: 0.24s; }

/* Buttons */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 14px 24px;
    font-family: inherit;
    font-size: 14px; font-weight: 600;
    text-decoration: none; cursor: pointer;
    border-radius: 999px;
    border: 1px solid transparent;
    transition: all .22s var(--ease);
    white-space: nowrap;
    letter-spacing: -0.005em;
}
.btn svg { width: 14px; height: 14px; transition: transform .22s var(--ease); }
.btn:hover svg { transform: translateX(2px); }
.btn-primary { background: var(--accent); color: var(--text-inv); box-shadow: 0 10px 30px -10px var(--accent-glow); }
.btn-primary:hover { background: var(--accent-hi); transform: translateY(-1px); }
.btn-ghost { background: transparent; color: var(--text); border-color: var(--line-2); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); background: var(--accent-soft); }

/* Buttons on dark (hero) */
.p-hero .btn-primary { background: #FFFFFF; color: var(--accent-deep); box-shadow: 0 12px 30px -12px rgba(15,11,42,0.5); }
.p-hero .btn-primary:hover { background: #F5F3FF; }
.p-hero .btn-ghost { color: var(--text-inv); border-color: rgba(255,255,255,0.24); }
.p-hero .btn-ghost:hover { border-color: rgba(255,255,255,0.5); background: rgba(255,255,255,0.06); }

/* ============================================
   LANG SWITCH (fixed top-right, no nav bar)
   ============================================ */
.lang-fixed {
    position: fixed;
    top: 20px; right: clamp(16px, 3vw, 32px);
    z-index: 100;
    display: inline-flex; align-items: center;
    padding: 2px;
    background: rgba(11,10,36,0.72);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: 11px; font-weight: 600; letter-spacing: 0.06em;
    box-shadow: 0 10px 30px -12px rgba(0,0,0,0.35);
}
.lang-fixed button {
    padding: 7px 14px;
    background: transparent;
    color: var(--text-inv-2);
    border: 0; border-radius: 999px;
    font: inherit; letter-spacing: inherit;
    cursor: pointer;
    transition: all .18s var(--ease);
}
.lang-fixed button:hover { color: var(--text-inv); }
.lang-fixed button.is-active { background: var(--text-inv); color: var(--bg-navy); }

/* ============================================
   BREADCRUMB (inside .p-hero)
   ============================================ */
.crumb {
    padding: 0 0 40px;
    font-family: var(--font-mono); font-size: 11.5px;
    color: var(--text-inv-3); letter-spacing: 0.14em; text-transform: uppercase;
    display: flex; align-items: center; justify-content: flex-start; gap: 12px;
}
.crumb a { color: var(--text-inv-3); text-decoration: none; transition: color .18s var(--ease); }
.crumb a:hover { color: var(--text-inv); }
.crumb-sep { color: rgba(255,255,255,0.28); }

/* ============================================
   PRODUCT HERO (dark gradient)
   ============================================ */
.p-hero {
    position: relative;
    padding: 96px 0 100px;
    background:
        radial-gradient(1200px 700px at 50% 20%, rgba(122,110,245,0.5), transparent 60%),
        linear-gradient(180deg, #0B0A24 0%, #1A1352 30%, #3D2FB0 65%, #7A6EF5 92%, #E5E0FF 100%);
    color: var(--text-inv);
    overflow: hidden;
    isolation: isolate;
}
.p-hero::before {
    content: '';
    position: absolute; inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.05) 1px, transparent 1px);
    background-size: 60px 60px;
    background-position: center top;
    mask-image: radial-gradient(ellipse 90% 60% at 50% 30%, black 40%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse 90% 60% at 50% 30%, black 40%, transparent 80%);
    pointer-events: none;
    z-index: 0;
}
.p-hero .container { text-align: center; position: relative; z-index: 2; }
.p-hero.p-hero-crumb-in { padding-top: 0; }
.p-hero .crumb { justify-content: flex-start; }

.p-hero-tag {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 6px 14px 6px 10px;
    background: var(--product-color-soft);
    border: 1px solid var(--product-color-border);
    border-radius: 999px;
    font-family: var(--font-mono); font-size: 11px; font-weight: 600;
    color: #FFFFFF;
    letter-spacing: 0.08em; text-transform: uppercase;
    margin-bottom: 32px;
    backdrop-filter: blur(10px);
}
.p-hero-tag-dot {
    width: 6px; height: 6px; border-radius: 50%;
    background: var(--product-color);
    box-shadow: 0 0 10px var(--product-color);
    animation: pulse 2.4s ease-in-out infinite;
}
@keyframes pulse { 0%, 100% { opacity: 1 } 50% { opacity: 0.5 } }

.p-hero-title {
    font-family: var(--font-display);
    font-size: clamp(44px, 7.5vw, 96px);
    font-weight: 600;
    line-height: 1.02;
    letter-spacing: -0.038em;
    color: var(--text-inv);
    margin: 0 auto 32px;
    max-width: 1100px;
}
.p-hero-sub {
    font-size: clamp(15px, 1.35vw, 18px);
    color: var(--text-inv-2);
    line-height: 1.6;
    max-width: 720px;
    margin: 0 auto 40px;
}
.p-hero-actions { display: inline-flex; gap: 12px; flex-wrap: wrap; justify-content: center; }

/* Hero image (screenshot) */
.p-hero-image {
    margin: 80px auto 0;
    max-width: 1100px;
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 20px;
    overflow: hidden;
    background: rgba(11,10,36,0.4);
    box-shadow: 0 60px 100px -30px rgba(0,0,0,0.7);
    position: relative;
}
.p-hero-image::before {
    content: '';
    position: absolute; top: -1px; left: 15%; right: 15%; height: 1px;
    background: linear-gradient(90deg, transparent, var(--product-color) 50%, transparent);
    z-index: 3;
}
.p-hero-image img { width: 100%; height: auto; display: block; }
.p-hero-image-caption {
    padding: 14px 20px;
    border-top: 1px solid rgba(255,255,255,0.08);
    background: rgba(11,10,36,0.6);
    font-family: var(--font-mono); font-size: 11px; color: var(--text-inv-3);
    letter-spacing: 0.1em; text-transform: uppercase;
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 8px;
}
.p-hero-image-caption span:last-child { color: rgba(255,255,255,0.35); }
.p-hero-image-fallback {
    aspect-ratio: 16/9;
    display: flex; align-items: center; justify-content: center;
    color: var(--text-inv-2);
    font-family: var(--font-mono); font-size: 12px;
    letter-spacing: 0.1em; text-transform: uppercase;
    padding: 40px 20px; text-align: center;
    background: radial-gradient(ellipse at center, var(--product-color-soft), transparent 60%);
}

/* Dual-image hero (side-by-side KO + EN) */
.p-hero-image-dual {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    background: rgba(11,10,36,0.4);
}
.p-hero-image-slot {
    position: relative;
    overflow: hidden;
    display: block;
    background: rgba(11,10,36,0.4);
}
.p-hero-image-dual .p-hero-image-slot:first-child {
    border-right: 1px solid rgba(255,255,255,0.10);
}
.p-hero-image-dual img {
    width: 100%; height: auto; display: block;
}
.p-hero-image-tag {
    position: absolute;
    top: 14px; left: 14px;
    z-index: 2;
    display: inline-flex; align-items: center;
    padding: 5px 12px;
    background: rgba(11,10,36,0.85);
    backdrop-filter: blur(10px);
    border: 1px solid var(--product-color-border);
    border-radius: 999px;
    font-family: var(--font-mono);
    font-size: 10.5px; font-weight: 600;
    color: var(--product-color);
    letter-spacing: 0.14em; text-transform: uppercase;
}
@media (max-width: 900px) {
    .p-hero-image-dual { grid-template-columns: 1fr; }
    .p-hero-image-dual .p-hero-image-slot:first-child {
        border-right: 0;
        border-bottom: 1px solid rgba(255,255,255,0.10);
    }
}

/* ============================================
   SECTIONS (light)
   ============================================ */
.section {
    padding: clamp(80px, 12vh, 140px) 0;
    background: var(--bg);
    color: var(--text);
    border-bottom: 1px solid var(--line);
}
.micro {
    display: inline-flex; align-items: center; gap: 8px;
    font-family: var(--font-mono);
    font-size: 11px; font-weight: 500;
    color: var(--product-color);
    letter-spacing: 0.14em; text-transform: uppercase;
    margin-bottom: 20px;
}
.micro::before {
    content: ''; width: 22px; height: 1px; background: currentColor;
}
.section-title {
    font-family: var(--font-display);
    font-size: clamp(32px, 4.4vw, 56px);
    font-weight: 600;
    line-height: 1.04;
    letter-spacing: -0.032em;
    color: var(--text);
    max-width: 800px;
    margin-bottom: 20px;
}
.section-sub {
    font-size: clamp(15px, 1.2vw, 17px);
    color: var(--text-2);
    line-height: 1.6;
    max-width: 640px;
}

/* ============================================
   FEATURES (2x4 grid)
   ============================================ */
.features {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-top: 64px;
}
.feature {
    background: var(--bg);
    border: 1px solid var(--line);
    border-radius: 20px;
    padding: 32px;
    display: flex; flex-direction: column; gap: 14px;
    transition: transform .3s var(--ease), border-color .3s var(--ease), box-shadow .3s var(--ease);
    min-height: 260px;
}
.feature:hover {
    transform: translateY(-4px);
    border-color: var(--product-color-border);
    box-shadow: 0 24px 48px -24px rgba(15,11,42,0.15);
}
.feature-icon {
    width: 48px; height: 48px; border-radius: 12px;
    display: inline-flex; align-items: center; justify-content: center;
    background: var(--product-color-soft);
    color: var(--product-color);
    border: 1px solid var(--product-color-border);
}
.feature-icon svg { width: 22px; height: 22px; }
.feature-num {
    font-family: var(--font-mono); font-size: 11px; color: var(--text-3);
    letter-spacing: 0.12em;
}
.feature-title {
    font-family: var(--font-display);
    font-size: 22px; font-weight: 700;
    letter-spacing: -0.02em; line-height: 1.15;
    color: var(--text);
}
.feature-desc { font-size: 14.5px; color: var(--text-2); line-height: 1.6; }
.feature-list { margin-top: 8px; list-style: none; display: grid; gap: 8px; }
.feature-list li {
    position: relative; padding-left: 18px;
    font-size: 13.5px; color: var(--text-2); line-height: 1.55;
}
.feature-list li::before {
    content: ''; position: absolute; left: 0; top: 9px;
    width: 10px; height: 1px; background: var(--product-color);
}

/* ============================================
   CALLOUT (dark rounded card)
   ============================================ */
.callout {
    padding: clamp(56px, 7vw, 84px) clamp(32px, 5vw, 64px);
    background: var(--bg-navy);
    color: var(--text-inv);
    border-radius: 24px;
    display: grid; grid-template-columns: 1.1fr 1fr; gap: 48px;
    align-items: center;
    position: relative; overflow: hidden;
    margin-top: 60px;
}
.callout::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 1px;
    background: linear-gradient(90deg, transparent, var(--product-color) 20%, var(--product-color) 80%, transparent);
}
.callout-title {
    font-family: var(--font-display);
    font-size: clamp(24px, 2.6vw, 34px);
    font-weight: 600; letter-spacing: -0.022em; line-height: 1.2;
    color: var(--text-inv);
}
.callout-desc {
    font-size: 15px; color: var(--text-inv-2); line-height: 1.6;
    margin-top: 12px;
    max-width: 480px;
}
.callout-mock {
    background: rgba(255,255,255,0.03);
    border: 1px solid rgba(255,255,255,0.10);
    border-radius: 12px;
    padding: 24px;
    font-family: var(--font-mono); font-size: 12px;
    color: var(--text-inv-2); line-height: 1.7;
}
.callout-mock .row {
    display: flex; justify-content: space-between; gap: 16px;
    padding: 8px 0;
    border-bottom: 1px dashed rgba(255,255,255,0.08);
}
.callout-mock .row:last-child { border-bottom: 0; }
.callout-mock .label { color: var(--text-inv-3); }
.callout-mock .val { color: var(--product-color); }
.callout-mock .val.g { color: #34D399; }

/* Callout section wrapper (in .section) */
.section:has(> .container > .callout) { background: var(--bg-soft); }

/* ============================================
   FOOTER (hero-cta style)
   ============================================ */
.footer {
    background: var(--bg-navy);
    color: var(--text-inv-2);
    padding: 120px 0 40px;
    border-top: 1px solid rgba(255,255,255,0.06);
    position: relative;
    overflow: hidden;
}
.footer::before {
    content: '';
    position: absolute; top: 0; left: 0; right: 0; height: 60%;
    background: radial-gradient(700px 400px at 15% 0%, rgba(122,110,245,0.16), transparent 65%);
    pointer-events: none;
}
.footer .container { position: relative; z-index: 1; }

.footer-hero {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 60px;
    padding-bottom: 72px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
    flex-wrap: wrap;
}
.footer-heading {
    font-family: var(--font-display);
    font-size: clamp(34px, 5vw, 64px);
    font-weight: 600;
    letter-spacing: -0.028em;
    line-height: 1.05;
    color: var(--text-inv);
    max-width: 720px;
}
.footer-mail {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    padding: 15px 22px 15px 26px;
    background: rgba(255,255,255,0.05);
    border: 1px solid rgba(255,255,255,0.14);
    border-radius: 999px;
    color: var(--text-inv);
    text-decoration: none;
    font-family: var(--font-mono);
    font-size: 14.5px;
    font-weight: 500;
    letter-spacing: 0.01em;
    transition: all .3s var(--ease);
    white-space: nowrap;
}
.footer-mail:hover {
    background: var(--accent);
    border-color: var(--accent);
    transform: translateY(-2px);
    box-shadow: 0 14px 30px -8px var(--accent-glow);
}
.footer-mail svg { width: 16px; height: 16px; transition: transform .3s var(--ease); }
.footer-mail:hover svg { transform: translateX(4px); }

.footer-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 6px 32px;
    padding: 32px 0;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    margin-bottom: 28px;
}
.footer-nav a {
    color: var(--text-inv-2);
    text-decoration: none;
    font-size: 14px;
    letter-spacing: -0.005em;
    padding: 4px 0;
    transition: color .2s var(--ease);
    position: relative;
}
.footer-nav a::after {
    content: '';
    position: absolute; left: 0; bottom: 0; width: 0; height: 1px;
    background: var(--accent);
    transition: width .28s var(--ease);
}
.footer-nav a:hover { color: var(--text-inv); }
.footer-nav a:hover::after { width: 100%; }

.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
    font-family: var(--font-mono);
    font-size: 11.5px;
    color: var(--text-inv-3);
    letter-spacing: 0.06em;
}
.footer-bottom-right { display: inline-flex; gap: 16px; }

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
    .callout { grid-template-columns: 1fr; gap: 32px; }
    .features { grid-template-columns: 1fr; }
    .footer-hero { flex-direction: column; align-items: flex-start; gap: 32px; }
}
@media (max-width: 768px) {
    :root { --pad-x: 20px; }
    .p-hero { padding: 76px 0 60px; }
    .p-hero-title { font-size: clamp(34px, 9.5vw, 52px); }
    .p-hero-actions .btn { flex: 1 1 auto; justify-content: center; padding: 14px 18px; }
    .feature { padding: 24px; min-height: auto; }
    .footer-nav { gap: 4px 20px; }
    .footer-bottom { flex-direction: column; align-items: flex-start; }
    .lang-fixed { top: 12px; right: 12px; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; }
    .reveal { opacity: 1; transform: none; }
}
