/* ============================================================
   OptiFlow Landing Page Styles
   - .optiflow-landing 클래스로 스코프 격리
   - 기존 프로젝트의 전역 CSS와 충돌 방지
   ============================================================ */

.optiflow-landing {
    --teal: #0f7b6c;
    --teal-deep: #0a4f45;
    --teal-soft: #e6f4f1;
    --ink: #0a0f1a;
    --ink-2: #1f2937;
    --muted: #5b6472;
    --line: #e5e7eb;
    --surface: #f6f8fb;
    --white: #ffffff;
    --green: #10b981;
    --amber: #f59e0b;
    --red: #ef4444;
    --shadow-md: 0 10px 30px rgba(10, 15, 26, 0.08), 0 2px 6px rgba(10, 15, 26, 0.04);
    --shadow-lg: 0 30px 60px rgba(10, 15, 26, 0.12), 0 8px 20px rgba(10, 15, 26, 0.06);
    --max: 1120px;

    font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
    color: var(--ink);
    background: var(--white);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    margin: 0;
    padding: 0;
}

.optiflow-landing *,
.optiflow-landing *::before,
.optiflow-landing *::after {
    box-sizing: border-box;
}

.optiflow-landing .wrap {
    max-width: var(--max);
    margin: 0 auto;
    padding: 0 24px;
}

/* ============ NAV ============ */
.optiflow-landing .nav {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: saturate(180%) blur(12px);
    border-bottom: 1px solid var(--line);
}

.optiflow-landing .nav-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    height: 64px;
}

.optiflow-landing .logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-family: "Fraunces", serif;
    font-weight: 600;
    font-size: 20px;
    letter-spacing: -0.01em;
    color: var(--ink);
    text-decoration: none;
}

.optiflow-landing .logo-mark {
    width: 28px;
    height: 28px;
    border-radius: 7px;
    background: linear-gradient(135deg, var(--teal) 0%, var(--teal-deep) 100%);
    display: grid;
    place-items: center;
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.25), 0 4px 10px rgba(15, 123, 108, 0.35);
}

/* ============ BUTTON ============ */
.optiflow-landing .btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 11px 20px;
    border-radius: 10px;
    font-weight: 600;
    text-decoration: none;
    font-size: 15px;
    transition: all .2s ease;
    border: 1px solid transparent;
    cursor: pointer;
    font-family: "Pretendard", "Apple SD Gothic Neo", "Malgun Gothic", sans-serif;
    letter-spacing: -0.01em;
}

.optiflow-landing .btn-primary {
    background: var(--teal);
    color: #fff;
    box-shadow: 0 6px 16px rgba(15, 123, 108, 0.3);
}

.optiflow-landing .btn-primary:hover {
    background: var(--teal-deep);
    transform: translateY(-1px);
    box-shadow: 0 10px 22px rgba(15, 123, 108, 0.4);
}

.optiflow-landing .btn-xl {
    padding: 15px 28px;
    font-size: 16px;
    border-radius: 11px;
}

.optiflow-landing .btn svg {
    width: 16px;
    height: 16px;
}

/* ============ HERO ============ */
.optiflow-landing .hero {
    position: relative;
    overflow: hidden;
    padding: 72px 0 48px;
    background: radial-gradient(900px 460px at 85% -10%, rgba(15, 123, 108, 0.10), transparent 60%),
                linear-gradient(180deg, #fbfcfe 0%, #ffffff 100%);
}

.optiflow-landing .hero-grid {
    display: grid;
    grid-template-columns: 1.05fr 1fr;
    gap: 48px;
    align-items: center;
}


.optiflow-landing h1.hero-title {
    font-family: "Fraunces", serif;
    font-weight: 500;
    font-size: clamp(36px, 4.6vw, 54px);
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin: 18px 0 18px;
}

.optiflow-landing h1.hero-title em {
    font-style: italic;
    font-weight: 500;
    color: var(--teal);
}

.optiflow-landing .hero-sub {
    font-size: 17px;
    color: var(--muted);
    max-width: 480px;
    margin: 0 0 28px;
}

.optiflow-landing .hero-ctas {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* ============ DASHBOARD MOCKUP ============ */
.optiflow-landing .hero-media {
    position: relative;
    aspect-ratio: 16 / 10;
    border-radius: 16px;
    background: #fff;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--line);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    font-size: 11px;
}

.optiflow-landing .dash-bar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 0 12px;
    height: 28px;
    background: #f7f9fc;
    border-bottom: 1px solid var(--line);
    flex-shrink: 0;
}

.optiflow-landing .dash-bar .d {
    width: 9px;
    height: 9px;
    border-radius: 50%;
}

.optiflow-landing .dash-bar .d.r { background: #ff5f57; }
.optiflow-landing .dash-bar .d.y { background: #febc2e; }
.optiflow-landing .dash-bar .d.g { background: #28c840; }

.optiflow-landing .dash-bar .url {
    margin-left: 10px;
    padding: 2px 10px;
    background: #fff;
    border: 1px solid var(--line);
    border-radius: 4px;
    font-family: "JetBrains Mono", monospace;
    font-size: 9px;
    color: var(--muted);
}

.optiflow-landing .dash-body {
    flex: 1;
    display: grid;
    grid-template-columns: 110px 1fr;
    min-height: 0;
}

.optiflow-landing .dash-side {
    background: #fafbfd;
    border-right: 1px solid var(--line);
    padding: 12px 10px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.optiflow-landing .dash-side .brand {
    font-family: "Fraunces", serif;
    font-weight: 600;
    font-size: 12px;
    color: var(--ink);
    padding: 2px 6px 10px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid var(--line);
    margin-bottom: 6px;
}

.optiflow-landing .dash-side .brand::before {
    content: "S";
    display: grid;
    place-items: center;
    width: 16px;
    height: 16px;
    border-radius: 4px;
    background: var(--teal);
    color: #fff;
    font-size: 9px;
    font-weight: 800;
    font-family: "Pretendard", sans-serif;
}

.optiflow-landing .dash-side .menu {
    padding: 5px 8px;
    border-radius: 5px;
    color: var(--muted);
    font-size: 10px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.optiflow-landing .dash-side .menu .dot {
    width: 4px;
    height: 4px;
    border-radius: 50%;
    background: currentColor;
    opacity: 0.5;
}

.optiflow-landing .dash-side .menu.active {
    background: var(--teal-soft);
    color: var(--teal-deep);
    font-weight: 600;
}

.optiflow-landing .dash-side .menu.active .dot {
    background: var(--teal);
    opacity: 1;
}

.optiflow-landing .dash-main {
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    overflow: hidden;
}

.optiflow-landing .dash-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.optiflow-landing .dash-head h5 {
    margin: 0;
    font-size: 12px;
    font-weight: 600;
    color: var(--ink);
    font-family: "Fraunces", serif;
}

.optiflow-landing .dash-head .pill {
    font-size: 9px;
    color: var(--green);
    background: rgba(16, 185, 129, 0.1);
    padding: 2px 7px;
    border-radius: 999px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.optiflow-landing .dash-head .pill::before {
    content: "";
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--green);
    animation: optiflow-pulse 1.5s ease-in-out infinite;
}

@keyframes optiflow-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.4; }
}

.optiflow-landing .kpi-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 6px;
    flex-shrink: 0;
}

.optiflow-landing .kpi-card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 7px 8px;
}

.optiflow-landing .kpi-card .lbl {
    font-size: 8px;
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.optiflow-landing .kpi-card .val {
    font-family: "Fraunces", serif;
    font-weight: 600;
    font-size: 16px;
    color: var(--ink);
    margin-top: 1px;
    display: flex;
    align-items: baseline;
    gap: 3px;
}

.optiflow-landing .kpi-card .val .unit {
    font-size: 9px;
    color: var(--muted);
    font-family: "Pretendard", sans-serif;
    font-weight: 400;
}

.optiflow-landing .kpi-card .trend {
    font-size: 8px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.optiflow-landing .kpi-card .trend.up { color: var(--green); }
.optiflow-landing .kpi-card .trend.down { color: var(--red); }

.optiflow-landing .chart-row {
    flex: 1;
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 8px;
    min-height: 0;
}

.optiflow-landing .chart-box {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 8px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-height: 0;
}

.optiflow-landing .chart-box .t {
    font-size: 9px;
    font-weight: 600;
    color: var(--ink-2);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-shrink: 0;
}

.optiflow-landing .chart-box .t .legend {
    display: inline-flex;
    gap: 8px;
    font-weight: 400;
    color: var(--muted);
    font-size: 8px;
}

.optiflow-landing .chart-box .t .legend span {
    display: inline-flex;
    align-items: center;
    gap: 3px;
}

.optiflow-landing .chart-box .t .legend i {
    width: 6px;
    height: 6px;
    border-radius: 1px;
}

.optiflow-landing .chart-svg {
    flex: 1;
    width: 100%;
    min-height: 0;
}

.optiflow-landing .bar-list {
    display: flex;
    flex-direction: column;
    gap: 5px;
    justify-content: center;
    flex: 1;
}

.optiflow-landing .bar-item {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.optiflow-landing .bar-item .bar-top {
    display: flex;
    justify-content: space-between;
    font-size: 8px;
}

.optiflow-landing .bar-item .bar-top b {
    font-weight: 600;
    color: var(--ink);
}

.optiflow-landing .bar-item .bar-top span {
    color: var(--muted);
    font-family: "JetBrains Mono", monospace;
}

.optiflow-landing .bar-track {
    height: 5px;
    background: #e5eaf1;
    border-radius: 3px;
    overflow: hidden;
}

.optiflow-landing .bar-fill {
    height: 100%;
    border-radius: 3px;
    background: linear-gradient(90deg, var(--teal), var(--teal-deep));
}

/* ============ CORE (SYSTEM OVERVIEW DIAGRAM) ============ */
.optiflow-landing .core {
    padding: 80px 0;
    background: var(--surface);
}

.optiflow-landing .core-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 56px;
    align-items: center;
}

.optiflow-landing .core-media {
    position: relative;
    aspect-ratio: 16 / 10;
    border-radius: 14px;
    overflow: hidden;
    background: #fff;
    border: 1px solid var(--line);
    box-shadow: var(--shadow-md);
    padding: 22px 18px;
    display: flex;
    flex-direction: column;
}

.optiflow-landing .diagram-title {
    font-family: "JetBrains Mono", monospace;
    font-size: 10px;
    color: var(--muted);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    margin-bottom: 14px;
}

.optiflow-landing .flow {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    align-items: stretch;
    position: relative;
}

.optiflow-landing .flow-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    position: relative;
}

.optiflow-landing .flow-box {
    width: 100%;
    background: #fff;
    border: 1.5px solid var(--line);
    border-radius: 10px;
    padding: 12px 8px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    transition: all .3s ease;
    position: relative;
    z-index: 2;
}

.optiflow-landing .flow-box .ic {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: grid;
    place-items: center;
    color: #fff;
}

.optiflow-landing .flow-box .ic svg {
    width: 20px;
    height: 20px;
}

.optiflow-landing .flow-step:nth-child(1) .flow-box .ic { background: linear-gradient(135deg, #64748b, #475569); }
.optiflow-landing .flow-step:nth-child(2) .flow-box .ic { background: linear-gradient(135deg, var(--teal), var(--teal-deep)); }
.optiflow-landing .flow-step:nth-child(3) .flow-box .ic { background: linear-gradient(135deg, #f59e0b, #d97706); }
.optiflow-landing .flow-step:nth-child(4) .flow-box .ic { background: linear-gradient(135deg, #10b981, #059669); }

.optiflow-landing .flow-box .label {
    font-family: "Fraunces", serif;
    font-weight: 600;
    font-size: 13px;
    color: var(--ink);
    text-align: center;
    line-height: 1.2;
}

.optiflow-landing .flow-box .sub {
    font-size: 9px;
    color: var(--muted);
    text-align: center;
    line-height: 1.3;
    font-family: "JetBrains Mono", monospace;
}

.optiflow-landing .flow-step .caption {
    margin-top: 8px;
    font-size: 10px;
    color: var(--muted);
    text-align: center;
    padding: 3px 6px;
    border-radius: 4px;
    background: var(--surface);
    border: 1px dashed var(--line);
    width: 100%;
}

.optiflow-landing .flow-arrow {
    position: absolute;
    top: 32px;
    right: -6px;
    width: 12px;
    height: 12px;
    z-index: 3;
    color: var(--teal);
}

.optiflow-landing .flow-arrow svg {
    width: 100%;
    height: 100%;
}

.optiflow-landing .flow-step:last-child .flow-arrow {
    display: none;
}

.optiflow-landing .flow-foot {
    margin-top: 14px;
    padding: 10px 14px;
    background: linear-gradient(135deg, rgba(15, 123, 108, 0.08), rgba(15, 123, 108, 0.03));
    border: 1px solid rgba(15, 123, 108, 0.15);
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.optiflow-landing .flow-foot .fic {
    width: 24px;
    height: 24px;
    border-radius: 6px;
    background: var(--teal);
    color: #fff;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}

.optiflow-landing .flow-foot .fic svg {
    width: 13px;
    height: 13px;
}

.optiflow-landing .flow-foot .ftxt {
    font-size: 11px;
    color: var(--ink-2);
    line-height: 1.4;
}

.optiflow-landing .flow-foot .ftxt b {
    color: var(--teal-deep);
}

/* ============ CORE TEXT ============ */
.optiflow-landing .core-text h2 {
    font-family: "Fraunces", serif;
    font-weight: 500;
    font-size: clamp(28px, 3vw, 36px);
    line-height: 1.2;
    letter-spacing: -0.015em;
    margin: 0 0 14px;
}

.optiflow-landing .core-text > p {
    font-size: 16px;
    color: var(--muted);
    margin: 0 0 28px;
    max-width: 440px;
}

.optiflow-landing .point-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.optiflow-landing .point {
    display: flex;
    gap: 14px;
    align-items: flex-start;
}

.optiflow-landing .point .ic {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 9px;
    background: rgba(15, 123, 108, 0.1);
    color: var(--teal);
    display: grid;
    place-items: center;
}

.optiflow-landing .point .ic svg {
    width: 18px;
    height: 18px;
}

.optiflow-landing .point h4 {
    font-family: "Fraunces", serif;
    font-weight: 600;
    font-size: 17px;
    margin: 2px 0 4px;
    color: var(--ink);
}

.optiflow-landing .point p {
    margin: 0;
    font-size: 14px;
    color: var(--muted);
    line-height: 1.55;
}

/* ============ FINAL CTA ============ */
.optiflow-landing .final-cta {
    padding: 96px 0;
    background: var(--white);
    position: relative;
    overflow: hidden;
}

.optiflow-landing .final-cta::before {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 50% 50%, rgba(15, 123, 108, 0.06), transparent 60%);
    pointer-events: none;
}

.optiflow-landing .final-inner {
    position: relative;
    text-align: center;
    max-width: 640px;
    margin: 0 auto;
}

.optiflow-landing .final-inner h2 {
    font-family: "Fraunces", serif;
    font-weight: 500;
    font-size: clamp(30px, 3.6vw, 42px);
    line-height: 1.2;
    letter-spacing: -0.02em;
    margin: 0 0 16px;
}

.optiflow-landing .final-inner h2 em {
    font-style: italic;
    color: var(--teal);
    font-weight: 500;
}

.optiflow-landing .final-inner p {
    font-size: 16px;
    color: var(--muted);
    margin: 0 0 28px;
}

/* ============ FOOTER ============ */
.optiflow-landing .landing-footer {
    padding: 32px 0;
    border-top: 1px solid var(--line);
    background: #fafbfc;
}

.optiflow-landing .foot-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 13px;
    color: var(--muted);
    flex-wrap: wrap;
    gap: 12px;
}

/* ============ RESPONSIVE ============ */
@media (max-width: 860px) {
    .optiflow-landing .hero { padding-top: 48px; }
    .optiflow-landing .hero-grid,
    .optiflow-landing .core-grid { grid-template-columns: 1fr; gap: 32px; }
    .optiflow-landing .core { padding: 64px 0; }
    .optiflow-landing .final-cta { padding: 72px 0; }
    .optiflow-landing .hero-ctas .btn { flex: 1; justify-content: center; }
    .optiflow-landing .kpi-row { grid-template-columns: repeat(2, 1fr); }
    .optiflow-landing .chart-row { grid-template-columns: 1fr; }
}

@media (max-width: 520px) {
    .optiflow-landing .dash-side { display: none; }
    .optiflow-landing .dash-body { grid-template-columns: 1fr; }
    .optiflow-landing .flow { grid-template-columns: repeat(2, 1fr); gap: 20px; }
    .optiflow-landing .flow-arrow { display: none !important; }
}

/* ============ REVEAL ANIMATION ============ */
.optiflow-landing .reveal {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity .7s ease, transform .7s ease;
}

.optiflow-landing .reveal.in {
    opacity: 1;
    transform: none;
}

@media (prefers-reduced-motion: reduce) {
    .optiflow-landing .reveal {
        transition: none;
        opacity: 1;
        transform: none;
    }
    .optiflow-landing .dash-head .pill::before {
        animation: none;
    }
}
