/* =========================================================
   DEFAULT / HOME PAGE
   File: /MainPage/mainpage.css
   Uses Site.Master theme variables: mode, accent, density, font.
========================================================= */

.cos-home-page {
    --home-accent: var(--theme-accent, #1683ff);
    --home-accent-2: var(--theme-accent-2, #005ee8);
    --home-bg: var(--theme-bg, #020817);
    --home-surface: var(--theme-surface, rgba(11, 20, 36, .96));
    --home-card: var(--theme-card, rgba(15, 23, 42, .92));
    --home-soft: var(--theme-soft, rgba(30, 41, 59, .72));
    --home-text: var(--theme-text, #f8fafc);
    --home-muted: var(--theme-muted, #a6b3c8);
    --home-border: var(--theme-border, rgba(148, 163, 184, .18));
    --home-shadow: var(--theme-shadow, rgba(0, 0, 0, .32));
    min-height: 100vh;
    overflow: hidden;
    color: var(--home-text);
    background:
        radial-gradient(circle at 14% 4%, color-mix(in srgb, var(--home-accent) 15%, transparent), transparent 31rem),
        radial-gradient(circle at 86% 18%, color-mix(in srgb, var(--home-accent-2) 14%, transparent), transparent 34rem),
        var(--home-bg);
    font-family: Inter, Aptos, "Segoe UI Variable", "Segoe UI", system-ui, -apple-system, Arial, sans-serif;
    font-size: calc(15px * var(--theme-font-scale, 1));
}

.cos-home-page *,
.cos-home-page *::before,
.cos-home-page *::after {
    box-sizing: border-box;
}

.cos-home-page a {
    color: inherit;
}

.home-container {
    width: min(1320px, calc(100% - 48px));
    margin-inline: auto;
}

.home-promo-bar {
    position: relative;
    z-index: 4;
    min-height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 8px 48px;
    color: #fff;
    background: linear-gradient(90deg, var(--home-accent-2), var(--home-accent));
    font-size: calc(13px * var(--theme-font-scale, 1));
    font-weight: 800;
}

.home-promo-bar.is-hidden {
    display: none;
}

.home-promo-bar a {
    color: #fff;
    font-weight: 950;
    text-decoration: underline;
    text-underline-offset: 3px;
}

.home-promo-bar button {
    position: absolute;
    right: 16px;
    top: 50%;
    width: 28px;
    height: 28px;
    transform: translateY(-50%);
    border: 0;
    border-radius: 999px;
    color: #fff;
    background: rgba(255,255,255,.12);
    cursor: pointer;
    font-size: 22px;
    line-height: 1;
}

.home-hero {
    position: relative;
    padding: clamp(42px, 5.2vw, 86px) 0 72px;
}

.home-hero-shape {
    position: absolute;
    pointer-events: none;
    border-radius: 999px;
    opacity: .88;
}

.home-hero-shape.shape-one {
    width: 440px;
    height: 440px;
    left: -160px;
    top: 32px;
    background: radial-gradient(circle, color-mix(in srgb, var(--home-accent) 20%, transparent), transparent 70%);
}

.home-hero-shape.shape-two {
    width: 560px;
    height: 560px;
    right: -200px;
    top: -120px;
    background: radial-gradient(circle, color-mix(in srgb, var(--home-accent-2) 22%, transparent), transparent 72%);
}

.home-hero-shape.shape-three {
    width: 220px;
    height: 220px;
    right: 26%;
    bottom: 8%;
    background: radial-gradient(circle, color-mix(in srgb, var(--home-accent) 13%, transparent), transparent 70%);
}

.hero-grid {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr);
    align-items: center;
    gap: clamp(34px, 5vw, 70px);
}

.hero-copy {
    max-width: 580px;
}

.home-kicker,
.section-heading span,
.app-banner-card span,
.story-card span {
    width: fit-content;
    display: inline-flex;
    align-items: center;
    gap: 9px;
    color: var(--home-accent);
    font-size: calc(12px * var(--theme-font-scale, 1));
    font-weight: 1000;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.home-kicker span {
    width: 11px;
    height: 11px;
    display: inline-block;
    border-radius: 999px;
    background: var(--home-accent);
    box-shadow: 0 0 0 6px color-mix(in srgb, var(--home-accent) 13%, transparent);
}

.hero-copy h1 {
    margin: 18px 0 0;
    color: var(--home-text);
    font-size: clamp(42px, 6.5vw, 78px);
    line-height: .96;
    letter-spacing: -.065em;
    font-weight: 1000;
}

.hero-copy p {
    margin: 22px 0 0;
    max-width: 560px;
    color: var(--home-muted);
    font-size: clamp(16px, 1.5vw, 19px);
    line-height: 1.68;
    font-weight: 650;
}

.hero-actions {
    margin-top: 30px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.primary-action,
.secondary-action,
.feature-card a,
.app-banner-card a {
    min-height: calc(48px * var(--theme-density-scale, 1));
    padding: 0 18px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-decoration: none;
    font-size: calc(14px * var(--theme-font-scale, 1));
    font-weight: 950;
    transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease, background .18s ease;
}

.primary-action {
    color: #fff;
    border: 1px solid color-mix(in srgb, var(--home-accent) 70%, transparent);
    background: linear-gradient(135deg, var(--home-accent), var(--home-accent-2));
    box-shadow: 0 18px 40px color-mix(in srgb, var(--home-accent) 24%, transparent);
}

.primary-action.compact {
    min-height: 44px;
    margin-top: 20px;
}

.secondary-action {
    color: var(--home-text);
    border: 1px solid color-mix(in srgb, var(--home-accent) 20%, var(--home-border));
    background: color-mix(in srgb, var(--home-surface) 86%, transparent);
}

.primary-action:hover,
.secondary-action:hover,
.feature-card a:hover,
.app-banner-card a:hover {
    transform: translateY(-2px);
}

.hero-stats {
    margin-top: 32px;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.hero-stats div {
    min-height: 86px;
    padding: 18px;
    border: 1px solid color-mix(in srgb, var(--home-accent) 13%, var(--home-border));
    border-radius: 22px;
    background: color-mix(in srgb, var(--home-surface) 74%, transparent);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
}

.hero-stats strong {
    display: block;
    color: var(--home-text);
    font-size: 24px;
    font-weight: 1000;
    letter-spacing: -.04em;
}

.hero-stats span {
    display: block;
    margin-top: 5px;
    color: var(--home-muted);
    font-size: 12px;
    font-weight: 850;
}

.hero-showcase {
    min-width: 0;
}

.hero-slide-window {
    position: relative;
    min-height: clamp(460px, 46vw, 620px);
    border: 1px solid color-mix(in srgb, var(--home-accent) 20%, var(--home-border));
    border-radius: 34px;
    overflow: hidden;
    background:
        linear-gradient(135deg, color-mix(in srgb, var(--home-accent) 11%, transparent), transparent 45%),
        color-mix(in srgb, var(--home-surface) 90%, transparent);
    box-shadow: 0 28px 90px var(--home-shadow), inset 0 1px 0 rgba(255,255,255,.055);
}

.hero-slide {
    position: absolute;
    inset: 0;
    display: grid;
    grid-template-columns: .84fr 1.16fr;
    gap: 20px;
    align-items: center;
    padding: clamp(24px, 3.2vw, 46px);
    opacity: 0;
    pointer-events: none;
    transform: translateX(32px);
    transition: opacity .44s ease, transform .44s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
    transform: translateX(0);
}

.slide-copy span {
    display: inline-block;
    color: var(--home-accent);
    font-size: 12px;
    font-weight: 1000;
    letter-spacing: .08em;
    text-transform: uppercase;
}

.slide-copy h2 {
    margin: 14px 0 0;
    color: var(--home-text);
    font-size: clamp(28px, 3.8vw, 48px);
    line-height: 1.04;
    letter-spacing: -.055em;
    font-weight: 1000;
}

.slide-copy p {
    margin: 15px 0 0;
    color: var(--home-muted);
    font-size: 15px;
    line-height: 1.7;
    font-weight: 650;
}

.slide-copy a {
    margin-top: 22px;
    min-height: 44px;
    padding: 0 16px;
    border-radius: 9px;
    display: inline-flex;
    align-items: center;
    color: #fff;
    background: var(--home-accent);
    text-decoration: none;
    font-size: 13px;
    font-weight: 950;
}

.hero-slide img {
    width: 100%;
    max-height: 520px;
    object-fit: contain;
    filter: drop-shadow(0 26px 32px rgba(0,0,0,.26));
}

.hero-slider-controls {
    margin-top: 18px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
}

.hero-slider-controls button {
    width: 44px;
    height: 44px;
    border: 1px solid color-mix(in srgb, var(--home-accent) 22%, var(--home-border));
    border-radius: 999px;
    color: var(--home-text);
    background: color-mix(in srgb, var(--home-surface) 78%, transparent);
    cursor: pointer;
    font-size: 18px;
    font-weight: 900;
    box-shadow: 0 12px 28px rgba(0,0,0,.08);
}

.slide-dots {
    min-width: 130px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.slide-dots button {
    width: 32px;
    height: 3px;
    border: 0;
    border-radius: 999px;
    background: color-mix(in srgb, var(--home-muted) 36%, transparent);
}

.slide-dots button.is-active {
    background: var(--home-accent);
}

.home-section {
    padding: clamp(56px, 7vw, 92px) 0;
}

.section-heading {
    width: min(760px, 100%);
    margin-bottom: 28px;
}

.section-heading h2 {
    margin: 12px 0 0;
    color: var(--home-text);
    font-size: clamp(30px, 4.3vw, 54px);
    line-height: 1.05;
    letter-spacing: -.06em;
    font-weight: 1000;
}

.feature-card-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 18px;
}

.feature-card {
    min-height: 420px;
    display: grid;
    grid-template-rows: 168px minmax(0, 1fr);
    border: 1px solid color-mix(in srgb, var(--home-accent) 12%, var(--home-border));
    border-radius: 24px;
    overflow: hidden;
    background: color-mix(in srgb, var(--home-surface) 90%, transparent);
    box-shadow: 0 18px 46px color-mix(in srgb, var(--home-shadow) 50%, transparent);
    transition: transform .18s ease, border-color .18s ease, box-shadow .18s ease;
}

.feature-card:hover {
    transform: translateY(-4px);
    border-color: color-mix(in srgb, var(--home-accent) 35%, var(--home-border));
    box-shadow: 0 24px 58px color-mix(in srgb, var(--home-shadow) 68%, transparent);
}

.feature-card img {
    width: 100%;
    height: 168px;
    object-fit: cover;
    background: color-mix(in srgb, var(--home-accent) 7%, var(--home-surface));
}

.feature-card div {
    padding: 22px;
    display: grid;
    align-content: start;
}

.feature-card h3 {
    margin: 0;
    color: var(--home-text);
    font-size: 21px;
    line-height: 1.18;
    font-weight: 950;
    letter-spacing: -.03em;
}

.feature-card p {
    margin: 12px 0 0;
    color: var(--home-muted);
    font-size: 14px;
    line-height: 1.62;
    font-weight: 650;
}

.feature-card a,
.app-banner-card a {
    width: fit-content;
    min-height: 40px;
    margin-top: 20px;
    color: #fff;
    background: var(--home-accent);
}

.split-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.36fr) minmax(300px, .64fr);
    gap: 20px;
}

.story-card,
.mini-story-card,
.app-banner-card,
.help-panel {
    border: 1px solid color-mix(in srgb, var(--home-accent) 14%, var(--home-border));
    background: color-mix(in srgb, var(--home-surface) 88%, transparent);
    box-shadow: 0 22px 62px color-mix(in srgb, var(--home-shadow) 60%, transparent);
}

.story-large {
    min-height: 410px;
    border-radius: 30px;
    display: grid;
    grid-template-columns: .92fr 1.08fr;
    gap: 22px;
    align-items: center;
    overflow: hidden;
    padding: clamp(26px, 4vw, 46px);
}

.story-card h2,
.app-banner-card h2,
.help-panel h2 {
    margin: 12px 0 0;
    color: var(--home-text);
    font-size: clamp(28px, 4.1vw, 52px);
    line-height: 1.04;
    letter-spacing: -.06em;
    font-weight: 1000;
}

.story-card p,
.app-banner-card p {
    margin: 16px 0 0;
    color: var(--home-muted);
    font-size: 15px;
    line-height: 1.7;
    font-weight: 650;
}

.workspace-preview {
    min-height: 290px;
    border-radius: 28px;
    border: 1px solid color-mix(in srgb, var(--home-accent) 26%, var(--home-border));
    background:
        linear-gradient(135deg, color-mix(in srgb, var(--home-accent) 18%, transparent), transparent 48%),
        color-mix(in srgb, var(--home-bg) 75%, var(--home-surface));
    padding: 24px;
    position: relative;
    overflow: hidden;
}

.workspace-top {
    height: 44px;
    border-radius: 16px;
    background: color-mix(in srgb, var(--home-text) 8%, transparent);
    margin-bottom: 20px;
}

.workspace-row {
    height: 18px;
    width: 70%;
    border-radius: 999px;
    background: color-mix(in srgb, var(--home-accent) 58%, transparent);
    margin-bottom: 14px;
}

.workspace-row.wide { width: 92%; }
.workspace-row.small { width: 48%; }

.workspace-mini-grid {
    margin-top: 28px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.workspace-mini-grid span {
    min-height: 92px;
    border-radius: 20px;
    background: color-mix(in srgb, var(--home-text) 7%, transparent);
    border: 1px solid color-mix(in srgb, var(--home-accent) 16%, transparent);
}

.story-stack {
    display: grid;
    gap: 20px;
}

.mini-story-card {
    min-height: 195px;
    border-radius: 28px;
    padding: 28px;
    display: grid;
    align-content: end;
}

.mini-story-card strong {
    color: var(--home-text);
    font-size: 28px;
    line-height: 1.08;
    letter-spacing: -.05em;
    font-weight: 1000;
}

.mini-story-card span {
    margin-top: 12px;
    color: var(--home-muted);
    font-size: 15px;
    line-height: 1.58;
    font-weight: 650;
}

.accent-card {
    color: #fff;
    background: linear-gradient(135deg, var(--home-accent), var(--home-accent-2));
}

.accent-card strong,
.accent-card span {
    color: #fff;
}

.app-banner-card {
    min-height: 380px;
    border-radius: 32px;
    display: grid;
    grid-template-columns: minmax(0, .86fr) minmax(0, 1.14fr);
    align-items: center;
    gap: 24px;
    overflow: hidden;
    padding: clamp(28px, 4.5vw, 58px);
    background:
        radial-gradient(circle at 86% 16%, color-mix(in srgb, var(--home-accent) 22%, transparent), transparent 30rem),
        color-mix(in srgb, var(--home-surface) 90%, transparent);
}

.app-banner-card img {
    width: 100%;
    max-height: 360px;
    object-fit: contain;
    filter: drop-shadow(0 26px 32px rgba(0,0,0,.26));
}

.help-panel {
    width: min(900px, 100%);
    margin-inline: auto;
    padding: clamp(26px, 4vw, 46px);
    border-radius: 32px;
    text-align: center;
    background:
        linear-gradient(135deg, color-mix(in srgb, var(--home-accent) 24%, transparent), color-mix(in srgb, var(--home-accent-2) 11%, transparent)),
        color-mix(in srgb, var(--home-surface) 88%, transparent);
}

.help-panel h2 {
    margin: 0;
}

.help-search {
    width: min(680px, 100%);
    min-height: 56px;
    margin: 24px auto 0;
    padding: 0 18px;
    border-radius: 9px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    color: var(--home-muted);
    background: var(--home-bg);
    border: 1px solid color-mix(in srgb, var(--home-accent) 28%, var(--home-border));
    text-align: left;
    font-weight: 700;
}

.help-search b {
    color: var(--home-accent);
    font-size: 22px;
}

.help-chips {
    margin-top: 20px;
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.help-chips a {
    min-height: 38px;
    padding: 0 14px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    color: var(--home-text);
    background: color-mix(in srgb, var(--home-text) 7%, transparent);
    border: 1px solid color-mix(in srgb, var(--home-accent) 15%, var(--home-border));
    font-size: 13px;
    font-weight: 850;
}

html[data-mode="light"] .cos-home-page {
    --home-bg: var(--theme-bg, #f5f7fb);
    --home-surface: var(--theme-surface, rgba(255,255,255,.96));
    --home-card: var(--theme-card, #fff);
    --home-soft: var(--theme-soft, rgba(241,245,249,.92));
    --home-text: var(--theme-text, #0f172a);
    --home-muted: var(--theme-muted, #475569);
    --home-border: var(--theme-border, rgba(15,23,42,.12));
    --home-shadow: var(--theme-shadow, rgba(15,23,42,.14));
}

html[data-mode="light"] .hero-slide-window,
html[data-mode="light"] .feature-card,
html[data-mode="light"] .story-card,
html[data-mode="light"] .mini-story-card,
html[data-mode="light"] .app-banner-card,
html[data-mode="light"] .help-panel {
    background: rgba(255,255,255,.96);
}

html[data-mode="light"] .accent-card {
    background: linear-gradient(135deg, var(--home-accent), var(--home-accent-2));
}

html[data-mode="light"] .help-search {
    background: #fff;
}

@media (max-width: 1180px) {
    .hero-grid,
    .split-grid,
    .story-large,
    .app-banner-card {
        grid-template-columns: 1fr;
    }

    .hero-copy {
        max-width: 860px;
    }

    .feature-card-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .hero-slide {
        grid-template-columns: 1fr;
        align-content: center;
    }

    .hero-slide img {
        max-height: 300px;
    }
}

@media (max-width: 720px) {
    .home-container {
        width: min(100% - 28px, 1320px);
    }

    .home-promo-bar {
        padding-inline: 42px;
        text-align: center;
        font-size: 12px;
    }

    .home-hero {
        padding-top: 34px;
    }

    .hero-copy h1 {
        font-size: clamp(36px, 12vw, 52px);
    }

    .hero-actions {
        align-items: stretch;
    }

    .primary-action,
    .secondary-action {
        width: 100%;
    }

    .hero-stats,
    .feature-card-grid {
        grid-template-columns: 1fr;
    }

    .hero-slide-window {
        min-height: 620px;
        border-radius: 26px;
    }

    .hero-slide {
        padding: 22px;
    }

    .slide-copy h2,
    .section-heading h2,
    .story-card h2,
    .app-banner-card h2,
    .help-panel h2 {
        font-size: 32px;
    }

    .feature-card {
        min-height: auto;
    }

    .story-large,
    .app-banner-card,
    .help-panel {
        border-radius: 24px;
    }

    .workspace-mini-grid {
        grid-template-columns: 1fr;
    }

    .home-section {
        padding: 54px 0;
    }
}


/* =========================================================
   DEFAULT PAGE FIXES v20260607_02
   Full-width master content, smaller headline scale,
   and SVG-only controls to avoid symbol/font issues.
========================================================= */

html.default-page-shell .cos-main,
body.default-page-active .cos-main,
.cos-main:has(.cos-home-page) {
    width: 100% !important;
    max-width: none !important;
    padding: 0 !important;
}

html.default-page-shell .cos-page,
body.default-page-active.cos-page {
    overflow-x: hidden !important;
}

.home-container {
    width: min(1720px, calc(100% - 36px));
}

.home-hero {
    padding: clamp(32px, 4vw, 58px) 0 54px;
}

.hero-grid {
    grid-template-columns: minmax(360px, .82fr) minmax(0, 1.18fr);
    gap: clamp(28px, 4vw, 56px);
}

.hero-copy {
    max-width: 610px;
}

.hero-copy h1 {
    max-width: 760px;
    font-size: clamp(34px, 4.25vw, 56px) !important;
    line-height: 1.04 !important;
    letter-spacing: -.045em !important;
    font-weight: 950 !important;
}

.hero-copy p {
    max-width: 620px;
    font-size: clamp(15px, 1.18vw, 17px) !important;
    line-height: 1.62 !important;
}

.hero-slide-window {
    min-height: clamp(410px, 39vw, 560px);
}

.slide-copy h2 {
    font-size: clamp(24px, 2.65vw, 38px) !important;
    line-height: 1.08 !important;
    letter-spacing: -.045em !important;
}

.section-heading h2,
.story-card h2,
.app-banner-card h2,
.help-panel h2 {
    font-size: clamp(26px, 3.1vw, 42px) !important;
    line-height: 1.1 !important;
    letter-spacing: -.045em !important;
}

.mini-story-card strong {
    font-size: clamp(22px, 2vw, 26px) !important;
}

.hero-slider-controls button svg,
.home-promo-bar button svg,
.action-icon,
.help-arrow {
    width: 20px;
    height: 20px;
    display: block;
    fill: none;
    stroke: currentColor;
    stroke-width: 2.25;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.home-promo-bar button {
    display: grid;
    place-items: center;
    font-size: 0 !important;
}

.hero-slider-controls button {
    display: grid;
    place-items: center;
    font-size: 0 !important;
}

#HeroPauseBtn .play-icon {
    display: none;
}

#HeroPauseBtn.is-paused .pause-icon {
    display: none;
}

#HeroPauseBtn.is-paused .play-icon {
    display: block;
}

.action-icon {
    width: 18px;
    height: 18px;
    stroke-width: 2.4;
}

.help-arrow {
    width: 22px;
    height: 22px;
    color: var(--home-accent);
}

.help-search b {
    display: none;
}

@media (min-width: 1500px) {
    .feature-card-grid {
        gap: 22px;
    }

    .feature-card {
        min-height: 400px;
    }
}

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

@media (max-width: 720px) {
    .home-container {
        width: min(100% - 24px, 1720px);
    }

    .hero-copy h1 {
        font-size: clamp(31px, 9vw, 43px) !important;
    }

    .slide-copy h2,
    .section-heading h2,
    .story-card h2,
    .app-banner-card h2,
    .help-panel h2 {
        font-size: 28px !important;
    }
}
