/* ClosOne website — theme tokens taken from the customer app design system */
:root {
    --primary: #0F4D3B;
    --primary-dark: #083A2E;
    --primary-hover: #14614A;
    --secondary: #2E7D6B;
    --accent: #C96F3D;
    --accent-text: #A4552A;
    --soft-accent: #FBE9D7;
    --background: #FCF8F3;
    --surface: #FFFFFF;
    --warm-neutral: #F4D7B5;
    --muted-sage: #E2E8D0;
    --sage-tint: #EDF5F0;
    --text: #1E2E1F;
    --text-secondary: #667280;
    --border: #E7DDD0;
    --success: #2E9B70;
    --success-text: #1F7A56;
    --error: #D95C5C;
    --error-text: #B23F3F;
    --warning: #E0A84D;
    --on-primary: #FCF8F3;
    --on-primary-muted: #9EC3B5;

    --font-body: 'DM Sans', 'Noto Sans Devanagari', 'Noto Sans Gujarati', system-ui, sans-serif;
    --font-display: 'Source Serif 4', Georgia, serif;

    --radius-sm: 8px;
    --radius: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
    --radius-pill: 99px;
    --shadow: 0 1px 2px rgba(30, 46, 31, .05), 0 8px 24px rgba(30, 46, 31, .06);
    --shadow-lg: 0 2px 4px rgba(30, 46, 31, .05), 0 24px 48px rgba(15, 77, 59, .14);
    --container: 1140px;
}

*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-family: var(--font-body);
    font-size: 16px;
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

img, svg { max-width: 100%; height: auto; display: block; }

h1, h2, h3 {
    font-family: var(--font-display);
    font-weight: 600;
    line-height: 1.2;
    letter-spacing: -.01em;
    margin: 0 0 .5em;
    text-wrap: balance;
}
h1 { font-size: clamp(2.1rem, 5vw, 3.4rem); }
h2 { font-size: clamp(1.6rem, 3.2vw, 2.25rem); }
h3 { font-size: 1.2rem; }
p { margin: 0 0 1em; }

a { color: var(--primary); text-underline-offset: 3px; }
a:hover { color: var(--secondary); }

:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 4px; }

.ms {
    font-family: 'Material Symbols Rounded';
    font-weight: normal;
    font-style: normal;
    font-size: 24px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    direction: ltr;
    -webkit-font-feature-settings: 'liga';
    font-feature-settings: 'liga';
    -webkit-font-smoothing: antialiased;
    width: 1em;
    overflow: hidden;
    flex: none;
}

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.narrow { max-width: 780px; }

.skip-link {
    position: absolute; left: 12px; top: -60px; z-index: 200;
    background: var(--primary); color: var(--on-primary);
    padding: 10px 16px; border-radius: var(--radius-sm); text-decoration: none;
}
.skip-link:focus { top: 12px; color: var(--on-primary); }

/* ---- Preloader ---------------------------------------------------------- */
.preloader {
    position: fixed; inset: 0; z-index: 300;
    display: flex; align-items: center; justify-content: center;
    background: var(--background);
    transition: opacity .35s ease, visibility .35s ease;
    /* Safety net: clears itself even if JavaScript never runs */
    animation: preloader-out .35s ease 4s forwards;
}
.preloader.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.preloader.is-skipped { display: none; }
/* Shown over the page while a form is being sent */
.preloader.is-busy { display: flex; opacity: 1; visibility: visible; animation: none; background: rgba(252, 248, 243, .82); }
@keyframes preloader-out { to { opacity: 0; visibility: hidden; } }

/* ---- Buttons ------------------------------------------------------------ */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px;
    min-height: 52px; padding: 0 26px;
    border: 1.5px solid transparent; border-radius: var(--radius-pill);
    font: 600 1rem/1 var(--font-body);
    text-decoration: none; cursor: pointer;
    transition: background-color .15s ease, color .15s ease, border-color .15s ease, transform .15s ease;
}
.btn:active { transform: scale(.98); }
.btn-sm { min-height: 44px; padding: 0 18px; font-size: .9375rem; }
.btn-block { width: 100%; }
.btn .ms { font-size: 20px; }

.btn-primary { background: var(--primary); color: var(--on-primary); }
.btn-primary:hover { background: var(--primary-hover); color: var(--on-primary); }
.btn-outline { background: transparent; color: var(--primary); border-color: var(--primary); }
.btn-outline:hover { background: var(--sage-tint); color: var(--primary); }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-text); color: #fff; }
.btn-light { background: var(--background); color: var(--primary); }
.btn-light:hover { background: #fff; color: var(--primary); }
.btn-ghost-light { background: transparent; color: var(--on-primary); border-color: rgba(252, 248, 243, .45); }
.btn-ghost-light:hover { background: rgba(252, 248, 243, .1); color: var(--on-primary); }
.btn[disabled] { opacity: .6; cursor: progress; }

/* ---- Header ------------------------------------------------------------- */
.site-header {
    position: sticky; top: 0; z-index: 100;
    background: var(--primary-dark);
    border-bottom: 1px solid rgba(252, 248, 243, .12);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 72px; }

.brand { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--text); }
.brand:hover { color: var(--text); }
.brand-mark { width: 40px; height: 40px; border-radius: 11px; background: #fff; border: 1px solid var(--border); }
.brand-name { font-family: var(--font-display); font-weight: 600; font-size: 1.45rem; letter-spacing: -.01em; }
.brand-light, .brand-light:hover { color: var(--on-primary); }
.brand-light .brand-mark { border-color: transparent; }

.site-nav { display: flex; align-items: center; gap: 28px; }
.nav-links { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.nav-links a {
    display: block; padding: 10px 14px; border-radius: var(--radius-pill);
    color: #EDF5F0; font-weight: 500; text-decoration: none;
}
.nav-links a:hover { background: rgba(252, 248, 243, .1); color: #fff; }
.nav-links a[aria-current="page"] { color: #fff; font-weight: 600; background: rgba(252, 248, 243, .14); }
.nav-actions { display: flex; gap: 10px; }

.nav-toggle {
    display: none; width: 44px; height: 44px; padding: 0;
    align-items: center; justify-content: center;
    background: transparent; color: var(--on-primary);
    border: 1px solid rgba(252, 248, 243, .3); border-radius: var(--radius); cursor: pointer;
}

@media (max-width: 960px) {
    .nav-toggle { display: inline-flex; }
    .site-nav {
        display: none;
        position: absolute; left: 0; right: 0; top: 100%;
        flex-direction: column; align-items: stretch; gap: 16px;
        padding: 16px 20px 24px;
        background: var(--primary-dark); border-bottom: 1px solid rgba(252, 248, 243, .12);
        box-shadow: var(--shadow);
    }
    .site-nav.is-open { display: flex; }
    .nav-links { flex-direction: column; }
    .nav-links a { padding: 12px 14px; }
    .nav-actions { flex-direction: column; }
    .nav-actions .btn { min-height: 48px; }
}

/* ---- Sections ----------------------------------------------------------- */
.section { padding: clamp(56px, 8vw, 96px) 0; }
.section-tint { background: var(--soft-accent); }
.section-sage { background: var(--sage-tint); }
.section-dark { background: var(--primary); color: var(--on-primary); }
.section-dark h2, .section-dark h3 { color: var(--on-primary); }
.section-dark p { color: #D5E6DE; }

.section-head { max-width: 680px; margin: 0 auto clamp(32px, 5vw, 56px); text-align: center; }
.section-head p { color: var(--text-secondary); font-size: 1.0625rem; margin: 0; }
.section-dark .section-head p { color: #D5E6DE; }

.eyebrow {
    display: inline-block; margin-bottom: 14px;
    font-size: .8125rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase;
    color: var(--accent-text);
}
.section-dark .eyebrow { color: #E8A278; }

.lead { font-size: clamp(1.0625rem, 1.6vw, 1.2rem); color: var(--text-secondary); }

/* ---- Hero --------------------------------------------------------------- */
.hero { padding: clamp(40px, 7vw, 88px) 0 clamp(56px, 8vw, 96px); overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.hero h1 em { font-style: italic; color: var(--accent); }
.hero .lead { max-width: 520px; margin-bottom: 28px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-meta { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 28px 0 0; padding: 0; list-style: none; color: var(--text-secondary); font-size: .9375rem; }
.hero-meta li { display: inline-flex; align-items: center; gap: 6px; }
.hero-meta .ms { font-size: 18px; color: var(--secondary); }

.hero-grid > * { min-width: 0; }
.hero-visual { position: relative; padding: 76px 0; }
.hero-visual::before {
    content: ''; position: absolute; inset: 0 -8% 0 8%; z-index: 0;
    background: var(--muted-sage); border-radius: 44% 56% 52% 48% / 48% 44% 56% 52%;
}
.hero-visual::after {
    content: ''; position: absolute; right: 2%; bottom: 4%; z-index: 0;
    width: 112px; height: 112px; border-radius: 50%; background: var(--warm-neutral);
}

.app-card {
    position: relative; z-index: 1; max-width: 340px; margin: 0 auto;
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius-xl); padding: 22px; box-shadow: var(--shadow-lg);
}
.app-card-head { display: flex; align-items: center; gap: 14px; margin-bottom: 16px; }
.avatar {
    width: 56px; height: 56px; border-radius: 50%; flex: none;
    display: flex; align-items: center; justify-content: center;
    background: var(--soft-accent); color: var(--accent-text);
    font: 600 1.4rem var(--font-display);
}
.app-card-name { font-weight: 600; font-size: 1.0625rem; display: flex; align-items: center; gap: 6px; }
.app-card-name .ms { font-size: 18px; color: var(--secondary); }
.status { display: inline-flex; align-items: center; gap: 6px; font-size: .875rem; color: var(--success-text); font-weight: 500; }
.status::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--success); }
.chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 18px; padding: 0; list-style: none; }
.chip { padding: 6px 12px; border-radius: var(--radius-pill); background: var(--sage-tint); color: var(--primary); font-size: .8125rem; font-weight: 500; }
.service-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 18px; }
.service-tile {
    display: flex; flex-direction: column; align-items: center; gap: 4px;
    padding: 12px 6px; border: 1px solid var(--border); border-radius: var(--radius);
    font-size: .8125rem; font-weight: 500; color: var(--text-secondary);
}
.service-tile .ms { color: var(--primary); }
.app-card-note { margin: 12px 0 0; text-align: center; font-size: .8125rem; color: var(--text-secondary); }

.bubble {
    position: absolute; z-index: 2; max-width: 210px;
    padding: 10px 14px; border-radius: 16px; font-size: .875rem; line-height: 1.4;
    box-shadow: var(--shadow);
}
.bubble-in { left: 0; top: 8px; background: var(--surface); border: 1px solid var(--border); border-bottom-left-radius: 4px; }
.bubble-out { right: 0; bottom: 8px; background: var(--primary); color: var(--on-primary); border-bottom-right-radius: 4px; }

@media (max-width: 860px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-visual { max-width: 420px; margin: 0 auto; width: 100%; }
}
@media (max-width: 480px) {
    .cta-row .btn { width: 100%; }
}

/* ---- Cards and grids ---------------------------------------------------- */
.grid { display: grid; gap: 20px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
@media (max-width: 960px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: 1fr; } }
@media (max-width: 640px) { .grid-2, .grid-4 { grid-template-columns: 1fr; } }

.card {
    background: var(--surface); border: 1px solid var(--border);
    border-radius: var(--radius-lg); padding: 26px;
}
.card h3 { margin-bottom: 8px; }
.card p { color: var(--text-secondary); margin: 0; }
.card p + p { margin-top: .75em; }

.icon-badge {
    display: inline-flex; align-items: center; justify-content: center;
    width: 48px; height: 48px; margin-bottom: 18px;
    border-radius: var(--radius); background: var(--sage-tint); color: var(--primary);
}
.icon-badge.accent { background: var(--soft-accent); color: var(--accent-text); }

.step-number {
    display: inline-flex; align-items: center; justify-content: center;
    width: 40px; height: 40px; margin-bottom: 18px;
    border-radius: 50%; background: var(--primary); color: var(--on-primary);
    font: 600 1.1rem var(--font-display);
}

.trust-strip { border-block: 1px solid var(--border); background: var(--surface); }
.trust-strip ul { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin: 0; padding: 22px 0; list-style: none; }
.trust-strip li { display: flex; align-items: center; gap: 12px; font-weight: 500; font-size: .9375rem; }
.trust-strip .ms { color: var(--accent); }
@media (max-width: 860px) { .trust-strip ul { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 420px) { .trust-strip ul { grid-template-columns: 1fr; } }

.split { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; } }

.check-list { list-style: none; margin: 0 0 28px; padding: 0; display: grid; gap: 14px; }
.check-list li { display: flex; gap: 12px; align-items: flex-start; }
.check-list .ms { color: var(--secondary); margin-top: 1px; }
.section-dark .check-list .ms { color: #E8A278; }
.section-dark .check-list li { color: #EDF5F0; }

.panel {
    background: var(--primary-dark); border-radius: var(--radius-xl);
    padding: clamp(24px, 4vw, 36px); color: var(--on-primary);
}
.panel dl { margin: 0; display: grid; gap: 18px; }
.panel dt { font-size: .8125rem; letter-spacing: .08em; text-transform: uppercase; color: var(--on-primary-muted); font-weight: 600; }
.panel dd { margin: 4px 0 0; font-size: 1.0625rem; }
.panel dd .line { display: block; }

.notice {
    display: flex; gap: 14px; align-items: flex-start;
    padding: 20px 22px; border-radius: var(--radius-lg);
    background: var(--soft-accent); border: 1px solid var(--warm-neutral);
}
.notice .ms { color: var(--accent-text); margin-top: 2px; }
.notice p { margin: 0; }
.notice strong { display: block; margin-bottom: 4px; }

.cta-band { text-align: center; }
.cta-band .cta-row { justify-content: center; margin-top: 28px; }

/* ---- Page header (inner pages) ----------------------------------------- */
.page-head { padding: clamp(40px, 6vw, 72px) 0 clamp(28px, 4vw, 44px); background: var(--sage-tint); border-bottom: 1px solid var(--border); }
.page-head h1 { font-size: clamp(2rem, 4.4vw, 2.9rem); margin-bottom: 12px; }
.page-head p { color: var(--text-secondary); font-size: 1.0625rem; max-width: 640px; margin: 0; }

/* ---- Legal / prose ------------------------------------------------------ */
.prose { max-width: 780px; }
.prose h2 { font-size: 1.45rem; margin-top: 2.2em; scroll-margin-top: 96px; }
.prose h2:first-child { margin-top: 0; }
.prose h3 { font-family: var(--font-body); font-size: 1.0625rem; font-weight: 600; margin-top: 1.6em; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: .45em; }
.prose table { width: 100%; border-collapse: collapse; margin: 0 0 1.2em; font-size: .9375rem; }
.prose th, .prose td { text-align: left; vertical-align: top; padding: 12px 14px; border: 1px solid var(--border); }
.prose th { background: var(--sage-tint); font-weight: 600; }
.table-wrap { overflow-x: auto; }
.updated { color: var(--text-secondary); font-size: .9375rem; }
.address-block { font-style: normal; padding: 18px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); }

/* ---- Forms -------------------------------------------------------------- */
.form-layout { display: grid; grid-template-columns: 1fr 340px; gap: clamp(24px, 4vw, 48px); align-items: start; }
@media (max-width: 960px) { .form-layout { grid-template-columns: 1fr; } }

.form-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-xl); padding: clamp(22px, 4vw, 36px); }
.form-card h2 { font-size: 1.35rem; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.form-grid .full { grid-column: 1 / -1; }
@media (max-width: 640px) { .form-grid { grid-template-columns: 1fr; } }

.field label, .field legend { display: block; margin-bottom: 6px; font-weight: 600; font-size: .9375rem; padding: 0; }
.field .optional { font-weight: 400; color: var(--text-secondary); }
.field .hint { margin: 6px 0 0; font-size: .8125rem; color: var(--text-secondary); }
fieldset.field { border: 0; margin: 0; padding: 0; min-width: 0; }

input[type="text"], input[type="email"], input[type="tel"], input[type="date"], select, textarea {
    width: 100%; min-height: 52px; padding: 12px 14px;
    background: var(--surface); color: var(--text);
    border: 1.5px solid var(--border); border-radius: var(--radius);
    font: 400 1rem/1.4 var(--font-body);
    transition: border-color .15s ease, box-shadow .15s ease;
}
textarea { min-height: 132px; resize: vertical; }
input:hover, select:hover, textarea:hover { border-color: #D3C6B5; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(15, 77, 59, .14); }
[aria-invalid="true"] { border-color: var(--error) !important; }

.phone-field { display: flex; }
.phone-prefix {
    display: inline-flex; align-items: center; padding: 0 14px;
    background: var(--sage-tint); color: var(--text); font-weight: 600;
    border: 1.5px solid var(--border); border-right: 0; border-radius: var(--radius) 0 0 var(--radius);
}
.phone-field input { border-radius: 0 var(--radius) var(--radius) 0; }

.choice-group { display: flex; flex-wrap: wrap; gap: 8px; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; inset: 0; width: 100%; height: 100%; margin: 0; cursor: pointer; }
.choice span {
    display: inline-flex; align-items: center; min-height: 44px; padding: 0 16px;
    border: 1.5px solid var(--border); border-radius: var(--radius-pill);
    background: var(--surface); font-weight: 500; font-size: .9375rem;
    transition: background-color .15s ease, border-color .15s ease, color .15s ease;
}
.choice input:hover + span { border-color: var(--secondary); }
.choice input:checked + span { background: var(--primary); border-color: var(--primary); color: var(--on-primary); }
.choice input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 2px; }

.field label.consent { display: flex; gap: 12px; align-items: flex-start; margin: 0; font-size: .9375rem; font-weight: 400; }
.consent input { width: 22px; height: 22px; margin: 2px 0 0; flex: none; accent-color: var(--primary); }

.field-error { margin: 6px 0 0; color: var(--error-text); font-size: .875rem; font-weight: 500; }
.form-actions { margin-top: 28px; }
.form-foot { margin: 14px 0 0; font-size: .8125rem; color: var(--text-secondary); }

.alert { display: flex; gap: 12px; align-items: flex-start; padding: 16px 18px; border-radius: var(--radius); margin-bottom: 24px; }
.alert p { margin: 0; }
.alert-error { background: #FBEDED; border: 1px solid #F0C4C4; color: #8F2F2F; }
.alert-error .ms { color: var(--error); }

.success-card { text-align: center; padding: clamp(32px, 6vw, 56px) clamp(22px, 4vw, 40px); }
.success-card:focus { outline: none; }
.success-card .success-icon {
    display: inline-flex; align-items: center; justify-content: center;
    width: 72px; height: 72px; margin-bottom: 20px; border-radius: 50%;
    background: #E3F3EC; color: var(--success-text);
}
.success-card .success-icon .ms { font-size: 38px; }
.success-card p { color: var(--text-secondary); max-width: 480px; margin-inline: auto; }
.success-card .cta-row { justify-content: center; margin-top: 24px; }

.aside-card { background: var(--sage-tint); border-radius: var(--radius-xl); padding: 26px; }
.aside-card h2 { font-size: 1.2rem; }
.aside-card ol, .aside-card ul { margin: 0; padding-left: 1.2em; color: var(--text); }
.aside-card li { margin-bottom: .6em; }
.aside-card + .aside-card { margin-top: 20px; }
.aside-card.warm { background: var(--soft-accent); }

.contact-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 18px; }
.contact-list li { display: flex; gap: 14px; align-items: flex-start; }
.contact-list .ms { color: var(--primary); margin-top: 2px; }
.contact-list strong { display: block; font-size: .8125rem; letter-spacing: .06em; text-transform: uppercase; color: var(--text-secondary); font-weight: 600; }
.contact-list a { overflow-wrap: anywhere; }

.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* ---- Footer ------------------------------------------------------------- */
.site-footer { background: var(--primary-dark); color: #D5E6DE; padding: clamp(48px, 6vw, 72px) 0 0; font-size: .9375rem; }
.footer-grid { display: grid; grid-template-columns: 1.7fr repeat(3, 1fr) 1.4fr; gap: 32px; }
.site-footer h2 { font-family: var(--font-body); font-size: .8125rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase; color: var(--on-primary-muted); margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.site-footer a { color: #EDF5F0; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.footer-about p { margin: 16px 0 0; max-width: 320px; }
.footer-note { font-size: .8125rem; color: var(--on-primary-muted); }
.footer-contact li { overflow-wrap: anywhere; }
.footer-bottom {
    display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px 24px;
    margin-top: 48px; padding-block: 22px;
    border-top: 1px solid rgba(252, 248, 243, .14);
    font-size: .8125rem; color: var(--on-primary-muted);
}
.footer-bottom p { margin: 0; }
@media (max-width: 960px) { .footer-grid { grid-template-columns: 1fr 1fr; } .footer-about { grid-column: 1 / -1; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { transition-duration: .01ms !important; }
}
