:root {
    color-scheme: light;
    --ink-950: #122033;
    --ink-900: #18263a;
    --ink-800: #27364c;
    --ink-700: #435067;
    --ink-600: #647084;
    --ink-500: #8993a5;
    --line: #dde5ee;
    --line-soft: #edf2f7;
    --surface: #ffffff;
    --surface-muted: #f6f8fb;
    --surface-strong: #e9eef5;
    --accent: #20c878;
    --accent-dark: #119458;
    --accent-soft: #e9fbf2;
    --blue: #3478f6;
    --blue-soft: #ebf3ff;
    --purple: #8b5cf6;
    --purple-soft: #f2edff;
    --amber: #9a6510;
    --amber-soft: #fff2d7;
    --danger: #b64545;
    --danger-soft: #fbe8e7;
    --sidebar-width: 248px;
    --topbar-height: 72px;
    --radius: 8px;
    --shadow-soft: 0 12px 30px rgba(18, 32, 51, 0.07);
}

@media (max-width: 1180px) {
    .campaign-studio-body {
        grid-template-columns: 180px minmax(380px, 1fr) 270px;
    }

    .campaign-editor-section {
        padding: 20px;
    }

    .campaign-preview-panel {
        padding: 14px;
    }
}

@media (max-width: 980px) {
    .template-studio-grid {
        grid-template-columns: minmax(0, 1fr) 290px;
    }

    .campaign-command-bar {
        grid-template-columns: repeat(2, 1fr);
    }

    .campaign-command-bar article:nth-child(2) {
        border-inline-end: 0;
    }

    .campaign-command-bar article:nth-child(-n + 2) {
        border-bottom: 1px solid var(--line);
    }

    .campaign-studio-body {
        grid-template-columns: 150px minmax(0, 1fr);
    }

    .campaign-preview-panel {
        grid-column: 1 / -1;
        grid-template-columns: minmax(240px, 300px) 1fr;
        gap: 18px;
        border-top: 1px solid var(--line);
        border-inline-start: 0;
    }

    .campaign-preview-heading,
    .preview-health,
    .campaign-test-link {
        grid-column: 2;
    }

    .campaign-preview-heading {
        grid-row: 1;
    }

    .whatsapp-preview-phone {
        grid-column: 1;
        grid-row: 1 / 5;
    }

    .whatsapp-preview-wallpaper {
        min-height: 300px;
    }

    .campaign-list-heading,
    .campaign-list-tools {
        align-items: stretch;
    }

    .campaign-list-heading,
    .campaign-list-tools {
        display: grid;
    }
}

@media (max-width: 700px) {
    .app-shell,
    .workspace-shell,
    .workspace-content {
        max-width: 100%;
        overflow-x: clip;
    }

    .campaign-page-heading .heading-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .template-studio-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .template-builder {
        padding: 0 16px;
    }

    .template-live-preview {
        border-top: 1px solid var(--line);
        border-inline-start: 0;
    }

    .template-builder-actions {
        display: grid;
    }

    .template-builder-actions .button {
        width: 100%;
        justify-content: center;
    }

    .campaign-command-bar {
        grid-template-columns: 1fr 1fr;
    }

    .campaign-command-bar article {
        min-height: 80px;
        grid-template-columns: 34px 1fr;
        padding: 10px;
    }

    .campaign-metric-icon {
        width: 32px;
        height: 32px;
    }

    .campaign-command-bar strong {
        font-size: 18px;
    }

    .campaign-studio-body {
        grid-template-columns: 1fr;
    }

    .campaign-stepper {
        display: grid;
        grid-template-columns: repeat(3, 1fr);
        border-inline-end: 0;
        border-bottom: 1px solid var(--line);
        padding: 8px;
    }

    .campaign-stepper button {
        min-height: 60px;
        grid-template-columns: 28px 1fr;
        gap: 6px;
        padding: 8px 5px;
    }

    .campaign-stepper button::after,
    .campaign-stepper small {
        display: none;
    }

    .campaign-stepper button > span {
        width: 26px;
        height: 26px;
    }

    .campaign-stepper strong {
        font-size: 9px;
    }

    .campaign-editor-title {
        display: grid;
    }

    .campaign-editor-title > small {
        text-align: start;
    }

    .campaign-form-grid,
    .schedule-options,
    .campaign-review-summary {
        grid-template-columns: 1fr;
    }

    .audience-source-tabs {
        grid-template-columns: 1fr;
    }

    .audience-source-tabs button {
        justify-content: flex-start;
        padding-inline: 12px;
    }

    .audience-validation {
        grid-template-columns: repeat(3, 1fr);
    }

    .campaign-editor-actions {
        display: grid;
    }

    .campaign-editor-actions > div,
    .campaign-editor-actions .button {
        width: 100%;
    }

    .campaign-editor-actions > div .button {
        flex: 1;
    }

    .campaign-preview-panel {
        display: grid;
        grid-template-columns: 1fr;
    }

    .campaign-preview-heading,
    .whatsapp-preview-phone,
    .preview-health,
    .campaign-test-link {
        grid-column: 1;
        grid-row: auto;
    }

    .whatsapp-preview-phone {
        width: min(100%, 320px);
        margin-inline: auto;
    }

    .campaign-list-tools {
        width: 100%;
    }

    .campaign-status-filter {
        width: 100%;
        overflow-x: auto;
    }

    .campaign-status-filter button {
        flex: 1;
        min-width: max-content;
    }

    .campaign-list-tools .small-search {
        width: 100%;
    }
}

* {
    box-sizing: border-box;
}

html,
body {
    min-height: 100%;
}

html {
    background: var(--surface-muted);
}

body {
    margin: 0;
    background: var(--surface-muted);
    color: var(--ink-950);
    font-family: "SF Arabic", "Noto Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.5;
    letter-spacing: 0;
}

button,
input,
select,
textarea {
    color: inherit;
    font: inherit;
    letter-spacing: 0;
}

button,
a {
    -webkit-tap-highlight-color: transparent;
}

button {
    border: 0;
}

a {
    color: inherit;
    text-decoration: none;
}

svg {
    display: block;
}

h1,
h2,
h3,
p {
    margin: 0;
}

h1:focus {
    outline: none;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.public-shell {
    min-height: 100vh;
    background:
        radial-gradient(circle at 10% 0%, rgba(32, 200, 120, 0.13), transparent 28%),
        radial-gradient(circle at 92% 8%, rgba(52, 120, 246, 0.12), transparent 26%),
        var(--surface-muted);
}

.client-hero,
.client-section {
    width: min(1180px, calc(100% - 36px));
    margin-inline: auto;
}

.client-hero {
    padding: 24px 0 26px;
}

.client-topbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    min-height: 72px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.88);
    padding: 12px 14px;
    box-shadow: var(--shadow-soft);
}

.client-brand {
    display: flex;
    align-items: center;
    gap: 11px;
}

.client-brand-mark {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 8px;
    background: var(--accent);
    color: #ffffff;
}

.client-brand-mark svg {
    width: 21px;
    height: 21px;
}

.client-brand span:last-child {
    display: grid;
    line-height: 1.15;
}

.client-brand strong {
    font-size: 18px;
}

.client-brand small {
    color: var(--ink-500);
    font-size: 12px;
}

.client-nav-actions,
.client-hero-actions,
.client-submit-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 10px;
}

.client-hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
    gap: 18px;
    align-items: stretch;
    padding: 34px 0 8px;
}

.client-hero-copy,
.client-status-panel,
.client-section {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-soft);
}

.client-hero-copy {
    display: grid;
    align-content: center;
    gap: 18px;
    min-height: 390px;
    padding: 42px;
}

.client-hero-copy h1 {
    max-width: 760px;
    color: var(--ink-950);
    font-size: clamp(34px, 5.5vw, 64px);
    line-height: 1.08;
}

.client-hero-copy p {
    max-width: 700px;
    color: var(--ink-600);
    font-size: 18px;
}

.client-status-panel {
    display: grid;
    align-content: start;
    gap: 18px;
    padding: 28px;
}

.client-status-panel h2 {
    font-size: 24px;
}

.client-status-panel dl {
    display: grid;
    gap: 10px;
    margin: 0;
}

.client-status-panel dl div,
.permission-matrix article,
.client-links-grid a {
    border: 1px solid var(--line-soft);
    border-radius: 8px;
    background: var(--surface-muted);
}

.client-status-panel dl div {
    padding: 14px;
}

.client-status-panel dt {
    color: var(--ink-500);
    font-size: 12px;
    font-weight: 800;
}

.client-status-panel dd {
    margin: 4px 0 0;
    font-weight: 800;
}

.client-section {
    margin-top: 18px;
    padding: 28px;
}

.client-section-heading {
    display: grid;
    gap: 7px;
    margin-bottom: 20px;
}

.client-section-heading h2 {
    font-size: 30px;
}

.client-section-heading p {
    color: var(--ink-600);
}

.client-requirements-grid,
.permission-matrix,
.client-links-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.client-requirements-grid article {
    display: grid;
    gap: 10px;
    min-height: 172px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    padding: 18px;
}

.requirement-icon {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 8px;
    background: var(--blue-soft);
    color: var(--blue);
}

.requirement-icon svg {
    width: 21px;
    height: 21px;
}

.client-requirements-grid p,
.permission-matrix p {
    color: var(--ink-600);
}

.client-flow {
    display: grid;
    gap: 12px;
}

.client-flow article {
    display: grid;
    grid-template-columns: 58px minmax(0, 1fr);
    gap: 15px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    padding: 16px;
}

.flow-step-number {
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    border-radius: 8px;
    background: var(--ink-950);
    color: #ffffff;
    font-size: 15px;
    font-weight: 900;
}

.client-flow h3 {
    font-size: 18px;
}

.client-flow p {
    margin-top: 4px;
    color: var(--ink-600);
}

.client-flow a,
.client-links-grid a {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    color: var(--accent-dark);
    font-weight: 800;
}

.client-flow a svg,
.client-links-grid a svg {
    width: 17px;
    height: 17px;
}

.permission-matrix article {
    min-height: 150px;
    padding: 17px;
}

.permission-matrix span {
    color: var(--ink-500);
    font-size: 12px;
    font-weight: 900;
}

.permission-matrix strong {
    display: block;
    margin-top: 6px;
    font-size: 17px;
}

.permission-matrix p {
    margin-top: 8px;
}

.client-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.field-wide {
    grid-column: 1 / -1;
}

.client-submit-row {
    margin-top: 18px;
}

.client-links-grid a {
    justify-content: space-between;
    min-height: 86px;
    margin-top: 0;
    padding: 16px;
}

.client-links-grid span {
    display: grid;
    gap: 4px;
}

.client-links-grid small {
    color: var(--ink-500);
    font-weight: 500;
}

.client-hero-simple .client-hero-copy {
    min-height: 470px;
}

.semsem-landing {
    width: 100%;
    margin-inline: 0;
    padding-top: 0;
}

.semsem-landing .client-topbar,
.semsem-landing .client-hero-grid {
    width: min(1180px, calc(100% - 36px));
    margin-inline: auto;
}

.semsem-landing .client-topbar {
    position: relative;
    top: 24px;
    z-index: 2;
    border-color: rgba(255, 255, 255, 0.13);
    background: rgba(8, 14, 24, 0.82);
    color: #ffffff;
}

.semsem-landing .client-brand small {
    color: rgba(255, 255, 255, 0.68);
}

.semsem-landing .button-secondary {
    border-color: rgba(255, 255, 255, 0.2);
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.client-hero-grid-simple {
    grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
}

.semsem-landing .client-hero-grid-simple {
    width: 100%;
    min-height: 720px;
    align-items: center;
    background:
        radial-gradient(circle at 45% 115%, rgba(32, 200, 120, 0.38), transparent 33%),
        radial-gradient(circle at 72% 15%, rgba(52, 120, 246, 0.2), transparent 31%),
        linear-gradient(135deg, #070b12 0%, #101a26 52%, #07100c 100%);
    padding: 112px max(36px, calc((100vw - 1180px) / 2)) 70px;
}

.semsem-landing .client-hero-copy {
    border: 0;
    background: transparent;
    box-shadow: none;
    color: #ffffff;
    padding: 0;
}

.semsem-landing .client-hero-copy .eyebrow {
    color: #7df0b5;
}

.semsem-landing .client-hero-copy h1 {
    color: #ffffff;
    font-size: clamp(42px, 6vw, 78px);
}

.semsem-landing .client-hero-copy p {
    color: rgba(255, 255, 255, 0.72);
}

.hero-proof-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 10px;
    max-width: 720px;
    margin-top: 8px;
}

.hero-proof-strip span {
    display: grid;
    min-height: 78px;
    align-content: center;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.06);
    padding: 12px;
}

.hero-proof-strip strong {
    color: #ffffff;
    font-size: 23px;
}

.hero-proof-strip small {
    color: rgba(255, 255, 255, 0.62);
}

.semsem-device-stage {
    position: relative;
    display: grid;
    min-height: 520px;
    place-items: center;
}

.phone-mockup {
    position: relative;
    width: min(310px, 82vw);
    min-height: 560px;
    border: 10px solid #151b24;
    border-radius: 34px;
    background: #f8fbff;
    padding: 30px 18px 18px;
    box-shadow: 0 30px 80px rgba(0, 0, 0, 0.38);
}

.phone-speaker {
    position: absolute;
    top: 13px;
    left: 50%;
    width: 74px;
    height: 6px;
    border-radius: 999px;
    background: #303947;
    transform: translateX(-50%);
}

.phone-chat-header {
    display: flex;
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--line);
    padding-bottom: 14px;
}

.mini-avatar {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 50%;
    background: var(--accent);
    color: #ffffff;
    font-weight: 900;
}

.phone-chat-header div {
    display: grid;
}

.phone-chat-header small {
    color: var(--accent-dark);
}

.phone-message {
    width: fit-content;
    max-width: 88%;
    margin-top: 22px;
    border-radius: 8px;
    padding: 12px;
    font-size: 13px;
    line-height: 1.55;
}

.phone-message-in {
    background: var(--surface-strong);
}

.phone-message-out {
    margin-inline-start: auto;
    background: var(--accent);
    color: #ffffff;
}

.phone-mini-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 34px;
}

.phone-mini-stats span {
    display: grid;
    border-radius: 8px;
    background: var(--surface-muted);
    padding: 14px;
}

.phone-mini-stats strong {
    font-size: 22px;
}

.phone-mini-stats small {
    color: var(--ink-500);
}

.floating-dashboard-card {
    position: absolute;
    right: 0;
    bottom: 36px;
    display: grid;
    gap: 8px;
    width: min(280px, 70vw);
    border: 1px solid rgba(255, 255, 255, 0.18);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.92);
    padding: 16px;
    box-shadow: var(--shadow-soft);
}

.floating-dashboard-card small {
    color: var(--ink-600);
}

.mini-bars {
    display: flex;
    align-items: end;
    gap: 7px;
    height: 56px;
}

.mini-bars i {
    width: 100%;
    border-radius: 999px 999px 0 0;
    background: var(--accent);
}

.mini-bars i:nth-child(1) { height: 36%; }
.mini-bars i:nth-child(2) { height: 62%; }
.mini-bars i:nth-child(3) { height: 48%; }
.mini-bars i:nth-child(4) { height: 86%; }

.client-outcome-card {
    background: var(--ink-950);
    color: #ffffff;
}

.client-outcome-card h2 {
    color: #ffffff;
}

.outcome-list,
.plans-grid article ul {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.outcome-list li,
.plans-grid article li {
    display: flex;
    align-items: flex-start;
    gap: 9px;
}

.outcome-list svg,
.plans-grid article li svg {
    width: 18px;
    height: 18px;
    flex: 0 0 auto;
    color: var(--accent);
}

.customer-steps-grid,
.plans-grid,
.faq-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.customer-steps-grid article,
.plans-grid article,
.faq-grid article {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--surface);
    padding: 20px;
}

.customer-steps-grid article {
    min-height: 190px;
}

.customer-steps-grid span {
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    border-radius: 8px;
    background: var(--accent-soft);
    color: var(--accent-dark);
    font-weight: 900;
}

.customer-steps-grid h3,
.plans-grid h3,
.faq-grid h3 {
    margin-top: 14px;
    font-size: 20px;
}

.customer-steps-grid p,
.plans-grid p,
.faq-grid p {
    margin-top: 8px;
    color: var(--ink-600);
}

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

.plans-grid article {
    display: grid;
    align-content: start;
    gap: 14px;
    min-height: 330px;
}

.plans-grid article > span {
    width: fit-content;
    border-radius: 999px;
    background: var(--surface-strong);
    color: var(--ink-700);
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 900;
}

.plans-grid article.featured {
    border-color: #b7ebcf;
    background: var(--accent-soft);
}

.plans-grid article.featured > span {
    background: var(--accent);
    color: #ffffff;
}

.plans-grid article ul {
    margin-top: 2px;
}

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

.faq-grid article {
    min-height: 140px;
}

/* Semsem public site: adapted from the licensed Aptify composition. */
.aptify-semsem {
    --aptify-black: #080708;
    --aptify-ink: #111012;
    --aptify-muted: #716b72;
    --aptify-pink: #ed52df;
    --aptify-pink-deep: #b32ec6;
    --aptify-pink-soft: #fff1fd;
    --aptify-line: #eadfea;
    overflow: hidden;
    background: #fff;
    color: var(--aptify-ink);
    direction: rtl;
}

.aptify-semsem h1,
.aptify-semsem h2,
.aptify-semsem h3,
.aptify-semsem strong,
.aptify-semsem .aptify-title-line {
    font-family: "SF Arabic", "Noto Sans Arabic", "Segoe UI", Tahoma, Arial, sans-serif;
    letter-spacing: 0;
}

.aptify-hero {
    position: relative;
    min-height: 820px;
    overflow: hidden;
    background:
        linear-gradient(180deg, rgba(8, 7, 8, .05) 52%, rgba(98, 19, 104, .54) 78%, #fff 99%),
        url("images/aptify/overlay-hero.png") center bottom / 100% 52% no-repeat,
        var(--aptify-black);
    color: #fff;
}

.aptify-hero::after,
.aptify-footer::before {
    position: absolute;
    inset-inline: 0;
    bottom: -3px;
    height: 150px;
    background: linear-gradient(180deg, transparent, #fff 88%);
    content: "";
    pointer-events: none;
}

.aptify-nav {
    position: relative;
    z-index: 20;
    display: grid;
    width: min(1280px, calc(100% - 64px));
    min-height: 84px;
    margin-inline: auto;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 36px;
    border-bottom: 1px solid rgba(255, 255, 255, .09);
}

.aptify-logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    width: fit-content;
    color: inherit;
}

.aptify-logo-orb {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 50%;
    background: linear-gradient(135deg, #7d176f, var(--aptify-pink) 55%, #fff 140%);
    box-shadow: 0 0 26px rgba(237, 82, 223, .48);
    color: #fff;
    font-size: 17px;
    font-weight: 900;
}

.aptify-logo strong {
    font-size: 22px;
}

.aptify-nav-links {
    display: flex;
    align-items: center;
    gap: 28px;
    font-size: 13px;
    font-weight: 700;
}

.aptify-nav-links a {
    position: relative;
    color: rgba(255, 255, 255, .72);
    transition: color .25s ease;
}

.aptify-nav-links a::after {
    position: absolute;
    right: 0;
    bottom: -9px;
    width: 0;
    height: 2px;
    background: var(--aptify-pink);
    content: "";
    transition: width .25s ease;
}

.aptify-nav-links a:hover {
    color: #fff;
}

.aptify-nav-links a:hover::after {
    width: 100%;
}

.aptify-outline-button {
    justify-self: end;
    border: 1px solid rgba(255, 255, 255, .42);
    border-radius: 999px;
    padding: 11px 22px;
    color: #fff;
    font-size: 13px;
    font-weight: 800;
    transition: background .25s ease, border-color .25s ease, transform .25s ease;
}

.aptify-outline-button:hover {
    border-color: var(--aptify-pink);
    background: var(--aptify-pink);
    transform: translateY(-2px);
}

.aptify-hero-inner {
    position: relative;
    z-index: 2;
    display: grid;
    width: min(1280px, calc(100% - 64px));
    min-height: 650px;
    margin-inline: auto;
    grid-template-columns: 1fr minmax(390px, .82fr) .55fr;
    align-items: center;
}

.aptify-hero-title {
    position: relative;
    z-index: 3;
    display: grid;
    align-content: center;
    padding-top: 18px;
}

.aptify-title-line {
    display: block;
    font-size: clamp(72px, 8vw, 126px);
    font-weight: 800;
    line-height: .9;
}

.aptify-title-line-left {
    margin-inline-start: 1.25em;
    color: #fff;
}

.aptify-hero-title p {
    width: min(460px, 100%);
    margin-top: 36px;
    color: rgba(255, 255, 255, .66);
    font-size: 17px;
    line-height: 1.85;
}

.aptify-scroll-cue {
    display: grid;
    width: 58px;
    height: 58px;
    margin-top: 30px;
    place-items: center;
    border: 1px solid rgba(255, 255, 255, .34);
    border-radius: 50%;
    color: #fff;
    transition: background .25s ease, transform .25s ease;
}

.aptify-scroll-cue:hover {
    background: var(--aptify-pink);
    transform: translateY(4px);
}

.aptify-scroll-cue svg {
    width: 20px;
    height: 20px;
}

.aptify-phone-scene {
    position: relative;
    height: 580px;
    direction: ltr;
}

.aptify-phone-glow {
    position: absolute;
    inset: 17% 4% 8%;
    border-radius: 50%;
    background: rgba(229, 51, 213, .34);
    filter: blur(54px);
}

.aptify-phone-image {
    position: absolute;
    z-index: 2;
    left: 50%;
    bottom: 8px;
    width: 540px;
    max-width: none;
    transform: translateX(-50%) rotate(-5deg);
    filter: saturate(.18) brightness(.66) contrast(1.16) drop-shadow(0 38px 35px rgba(0, 0, 0, .42));
    animation: aptify-phone-float 5.5s ease-in-out infinite;
}

.aptify-phone-screen {
    position: absolute;
    z-index: 4;
    left: 47.7%;
    top: 95px;
    width: 188px;
    height: 406px;
    overflow: hidden;
    border-radius: 26px;
    background: linear-gradient(155deg, #261027 0%, #0d0c0e 58%, #1a0c1b 100%);
    padding: 27px 14px 16px;
    transform: translateX(-50%) rotate(-5deg);
    color: #fff;
    animation: aptify-phone-float-screen 5.5s ease-in-out infinite;
}

.aptify-rear-phone-brand {
    position: absolute;
    z-index: 5;
    left: 71%;
    top: 206px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    background: rgba(8, 7, 8, .93);
    color: #fff;
    width: 126px;
    min-height: 54px;
    justify-content: center;
    padding: 10px 14px;
    transform: translateX(-50%) rotate(6deg);
    box-shadow: 0 8px 20px rgba(0, 0, 0, .3);
    font-size: 9px;
}

.aptify-rear-phone-brand span {
    display: grid;
    width: 18px;
    height: 18px;
    place-items: center;
    border-radius: 50%;
    background: var(--aptify-pink);
    font-weight: 900;
}

.aptify-phone-brand {
    display: flex;
    align-items: center;
    gap: 7px;
    font-size: 10px;
}

.aptify-phone-brand span {
    display: grid;
    width: 21px;
    height: 21px;
    place-items: center;
    border-radius: 50%;
    background: var(--aptify-pink);
    font-weight: 900;
}

.aptify-phone-balance {
    display: grid;
    gap: 4px;
    margin-top: 30px;
}

.aptify-phone-balance small,
.aptify-phone-contacts small {
    color: rgba(255, 255, 255, .5);
    font-size: 8px;
}

.aptify-phone-balance strong {
    font-size: 34px;
    line-height: 1;
}

.aptify-phone-balance span {
    width: fit-content;
    border-radius: 999px;
    background: rgba(237, 82, 223, .16);
    color: #ff9df5;
    padding: 4px 7px;
    font-size: 7px;
}

.aptify-phone-chart,
.aptify-preview-chart {
    display: flex;
    height: 86px;
    align-items: end;
    gap: 5px;
    margin-top: 17px;
}

.aptify-phone-chart i,
.aptify-preview-chart i {
    width: 100%;
    border-radius: 4px 4px 0 0;
    background: linear-gradient(180deg, #ff8bf4, var(--aptify-pink-deep));
}

.aptify-phone-chart i:nth-child(1), .aptify-preview-chart i:nth-child(1) { height: 22%; }
.aptify-phone-chart i:nth-child(2), .aptify-preview-chart i:nth-child(2) { height: 48%; }
.aptify-phone-chart i:nth-child(3), .aptify-preview-chart i:nth-child(3) { height: 38%; }
.aptify-phone-chart i:nth-child(4), .aptify-preview-chart i:nth-child(4) { height: 74%; }
.aptify-phone-chart i:nth-child(5), .aptify-preview-chart i:nth-child(5) { height: 58%; }
.aptify-phone-chart i:nth-child(6), .aptify-preview-chart i:nth-child(6) { height: 91%; }
.aptify-preview-chart i:nth-child(7) { height: 68%; }

.aptify-phone-contacts {
    display: grid;
    gap: 9px;
    margin-top: 18px;
}

.aptify-phone-contacts span {
    display: grid;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
    padding-bottom: 7px;
    font-size: 8px;
}

.aptify-hero-stat {
    display: grid;
    align-content: center;
    justify-content: end;
    padding-bottom: 110px;
}

.aptify-hero-stat strong {
    font-size: clamp(46px, 5vw, 72px);
    line-height: 1;
}

.aptify-hero-stat strong span {
    color: var(--aptify-pink);
}

.aptify-hero-stat small {
    margin-top: 8px;
    color: rgba(255, 255, 255, .55);
}

.aptify-trust-strip {
    display: flex;
    min-height: 86px;
    align-items: center;
    justify-content: center;
    gap: 30px;
    border-bottom: 1px solid var(--aptify-line);
    color: #7f7780;
    font-size: 13px;
    font-weight: 700;
}

.aptify-trust-strip i {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: var(--aptify-pink);
}

.aptify-section {
    width: min(1180px, calc(100% - 48px));
    margin-inline: auto;
    padding-block: 112px;
}

.aptify-section-heading {
    max-width: 720px;
}

.aptify-section-heading > span,
.aptify-showcase-copy > span,
.aptify-segments-title > span,
.aptify-cta-copy > span {
    display: block;
    margin-bottom: 14px;
    color: var(--aptify-pink-deep);
    font-size: 12px;
    font-weight: 900;
}

.aptify-section-heading h2,
.aptify-showcase-copy h2,
.aptify-segments-title h2,
.aptify-cta-copy h2 {
    font-size: clamp(38px, 5.4vw, 68px);
    font-weight: 800;
    line-height: 1.04;
}

.aptify-section-heading p,
.aptify-showcase-copy p,
.aptify-plan > p,
.aptify-cta-copy p {
    color: var(--aptify-muted);
    font-size: 16px;
    line-height: 1.85;
}

.aptify-section-heading p {
    max-width: 620px;
    margin-top: 22px;
}

.aptify-service-row {
    display: grid;
    margin-top: 64px;
    grid-template-columns: repeat(3, 1fr);
    gap: 44px;
}

.aptify-service-item {
    position: relative;
    padding-top: 96px;
}

.aptify-service-item::after {
    position: absolute;
    inset-inline: 0;
    bottom: -30px;
    height: 1px;
    background: var(--aptify-line);
    content: "";
    transition: background .3s ease;
}

.aptify-service-item:hover::after {
    background: var(--aptify-pink);
}

.aptify-service-item img {
    position: absolute;
    top: -6px;
    right: -20px;
    width: 128px;
    height: 128px;
    object-fit: contain;
    transition: transform .45s cubic-bezier(.2, .8, .2, 1);
}

.aptify-service-item:hover img {
    transform: translateY(-9px) rotate(5deg);
}

.aptify-service-number {
    color: var(--aptify-pink);
    font-size: 12px;
    font-weight: 900;
}

.aptify-service-item h3 {
    margin-top: 12px;
    font-size: 24px;
}

.aptify-service-item p,
.aptify-capability p,
.aptify-process-step p {
    margin-top: 10px;
    color: var(--aptify-muted);
    line-height: 1.8;
}

.aptify-showcase {
    display: grid;
    grid-template-columns: 1fr .9fr;
    align-items: center;
    gap: 90px;
}

.aptify-showcase-media {
    position: relative;
    min-height: 560px;
    border-radius: 3px;
    background: linear-gradient(145deg, #fbe5fa, #fff 55%, #f7e6fa);
}

.aptify-showcase-media::before {
    position: absolute;
    inset: 9% -6% -7% 10%;
    border: 1px solid rgba(211, 53, 202, .2);
    content: "";
    transform: rotate(-4deg);
}

.aptify-dashboard-preview {
    position: absolute;
    inset: 12% -8% 10% 9%;
    z-index: 2;
    border: 1px solid rgba(29, 20, 28, .08);
    border-radius: 7px;
    background: #fff;
    padding: 32px;
    box-shadow: 0 32px 80px rgba(67, 15, 67, .17);
    transform: rotate(3deg);
    transition: transform .5s cubic-bezier(.2, .8, .2, 1);
}

.aptify-showcase-media:hover .aptify-dashboard-preview {
    transform: rotate(0) translateY(-8px);
}

.aptify-preview-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 28px;
}

.aptify-preview-brand {
    font-weight: 900;
}

.aptify-live-dot {
    border-radius: 999px;
    background: #e9fbf2;
    color: #119458;
    padding: 5px 10px;
    font-size: 11px;
    font-weight: 800;
}

.aptify-dashboard-preview > strong {
    font-size: 28px;
}

.aptify-preview-grid {
    display: grid;
    margin-top: 28px;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}

.aptify-preview-grid div {
    display: grid;
    gap: 7px;
    border: 1px solid var(--aptify-line);
    padding: 18px;
}

.aptify-preview-grid span {
    color: var(--aptify-muted);
    font-size: 12px;
}

.aptify-preview-grid b {
    font-size: 24px;
}

.aptify-preview-chart {
    height: 150px;
    gap: 11px;
}

.aptify-showcase-copy p {
    margin-top: 26px;
}

.aptify-inline-stats {
    display: grid;
    margin-top: 38px;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.aptify-inline-stats span {
    display: grid;
    gap: 6px;
    border-top: 1px solid var(--aptify-line);
    padding-top: 18px;
}

.aptify-inline-stats strong {
    font-size: 34px;
}

.aptify-inline-stats small {
    color: var(--aptify-muted);
}

.aptify-process-band {
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(180deg, rgba(8, 7, 8, .95), rgba(36, 5, 35, .96)),
        url("images/aptify/wave-overlay-section-2.png") center / cover;
    color: #fff;
}

.aptify-process-band::after {
    position: absolute;
    right: -16%;
    top: 12%;
    width: 450px;
    height: 450px;
    border-radius: 50%;
    background: rgba(237, 82, 223, .18);
    content: "";
    filter: blur(90px);
}

.aptify-process {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: .8fr 1.2fr;
    gap: 90px;
}

.aptify-section-heading-light h2 {
    color: #fff;
}

.aptify-process-list {
    display: grid;
}

.aptify-process-step {
    display: grid;
    grid-template-columns: 64px 1fr;
    gap: 24px;
    border-bottom: 1px solid rgba(255, 255, 255, .12);
    padding: 26px 0;
}

.aptify-process-step > span {
    color: var(--aptify-pink);
    font-size: 22px;
    font-weight: 900;
}

.aptify-process-step h3 {
    color: #fff;
    font-size: 22px;
}

.aptify-process-step p {
    color: rgba(255, 255, 255, .57);
}

.aptify-capabilities .aptify-section-heading {
    max-width: 790px;
}

.aptify-capability-list {
    display: grid;
    margin-top: 56px;
    grid-template-columns: repeat(2, 1fr);
    border-top: 1px solid var(--aptify-line);
}

.aptify-capability {
    position: relative;
    display: grid;
    min-height: 230px;
    grid-template-columns: 64px 1fr 38px;
    align-content: center;
    column-gap: 22px;
    border-bottom: 1px solid var(--aptify-line);
    padding: 28px 28px 28px 0;
    transition: background .3s ease, padding .3s ease;
}

.aptify-capability:nth-child(odd) {
    border-inline-end: 1px solid var(--aptify-line);
    padding-inline-end: 36px;
}

.aptify-capability:hover {
    background: var(--aptify-pink-soft);
    padding-inline-start: 22px;
}

.aptify-capability > span {
    display: grid;
    width: 58px;
    height: 58px;
    place-items: center;
    border-radius: 50%;
    background: var(--aptify-pink-soft);
    color: var(--aptify-pink-deep);
}

.aptify-capability > span svg {
    width: 24px;
    height: 24px;
}

.aptify-capability h3 {
    align-self: end;
    font-size: 21px;
}

.aptify-capability p {
    grid-column: 2;
    align-self: start;
}

.aptify-capability > i {
    grid-column: 3;
    grid-row: 1 / 3;
    align-self: center;
    color: var(--aptify-pink-deep);
}

.aptify-capability > i svg {
    width: 20px;
    height: 20px;
}

.aptify-centered {
    margin-inline: auto;
    text-align: center;
}

.aptify-centered p {
    margin-inline: auto;
}

.aptify-plan-row {
    display: grid;
    margin-top: 60px;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.aptify-plan {
    display: grid;
    min-height: 470px;
    align-content: start;
    border: 1px solid var(--aptify-line);
    padding: 34px;
    transition: transform .35s ease, box-shadow .35s ease;
}

.aptify-plan:hover {
    transform: translateY(-10px);
    box-shadow: 0 26px 60px rgba(65, 18, 64, .12);
}

.aptify-plan.featured {
    border-color: var(--aptify-pink);
    box-shadow: 0 24px 70px rgba(214, 54, 203, .12);
}

.aptify-plan > span {
    color: var(--aptify-pink-deep);
    font-size: 11px;
    font-weight: 900;
}

.aptify-plan h3 {
    margin-top: 18px;
    font-size: 30px;
}

.aptify-plan > p {
    margin-top: 12px;
}

.aptify-plan ul {
    display: grid;
    gap: 14px;
    margin: 28px 0 34px;
    padding: 0;
    list-style: none;
}

.aptify-plan li {
    display: flex;
    align-items: center;
    gap: 9px;
    color: #4d464e;
}

.aptify-plan li svg {
    width: 17px;
    height: 17px;
    color: var(--aptify-pink-deep);
}

.aptify-plan > a,
.aptify-cta-copy > a {
    display: flex;
    min-height: 52px;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin-top: auto;
    border-radius: 999px;
    background: var(--aptify-pink);
    color: #fff;
    padding: 0 22px;
    font-weight: 900;
    transition: background .25s ease, transform .25s ease;
}

.aptify-plan.featured > a {
    background: var(--aptify-black);
}

.aptify-plan > a:hover,
.aptify-cta-copy > a:hover {
    background: var(--aptify-pink-deep);
    transform: translateX(-3px);
}

.aptify-plan > a svg,
.aptify-cta-copy > a svg {
    width: 18px;
    height: 18px;
}

.aptify-segments {
    padding-bottom: 90px;
}

.aptify-segments-title {
    display: grid;
    max-width: 1000px;
    margin-inline: auto;
    text-align: center;
}

.aptify-segment-marquee {
    display: flex;
    width: max-content;
    margin-top: 58px;
    gap: 14px;
    direction: ltr;
    animation: aptify-marquee 26s linear infinite;
}

.aptify-segment-marquee:hover {
    animation-play-state: paused;
}

.aptify-segment-marquee span {
    display: flex;
    min-height: 58px;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--aptify-line);
    border-radius: 999px;
    background: #fff;
    padding: 0 24px;
    direction: rtl;
    white-space: nowrap;
    font-weight: 800;
}

.aptify-segment-marquee svg {
    width: 19px;
    height: 19px;
    color: var(--aptify-pink-deep);
}

.aptify-faq {
    display: grid;
    grid-template-columns: .8fr 1.2fr;
    gap: 90px;
}

.aptify-faq-list {
    border-top: 1px solid var(--aptify-line);
}

.aptify-faq details {
    border-bottom: 1px solid var(--aptify-line);
    padding: 25px 0;
}

.aptify-faq summary {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    cursor: pointer;
    font-size: 18px;
    font-weight: 800;
    list-style: none;
}

.aptify-faq summary::-webkit-details-marker {
    display: none;
}

.aptify-faq summary svg {
    width: 20px;
    height: 20px;
    color: var(--aptify-pink-deep);
    transition: transform .25s ease;
}

.aptify-faq details[open] summary svg {
    transform: rotate(45deg);
}

.aptify-faq details p {
    max-width: 620px;
    margin-top: 16px;
    color: var(--aptify-muted);
    line-height: 1.8;
}

.aptify-cta {
    position: relative;
    display: grid;
    width: min(1120px, calc(100% - 48px));
    min-height: 440px;
    margin: 40px auto -54px;
    overflow: hidden;
    grid-template-columns: .9fr 1.1fr;
    align-items: center;
    background: linear-gradient(135deg, #fde9fb, #fff 62%, #f6e1f7);
    padding: 54px 70px;
}

.aptify-cta::after {
    position: absolute;
    inset: auto -10% -42% auto;
    width: 400px;
    height: 400px;
    border-radius: 50%;
    background: rgba(237, 82, 223, .13);
    content: "";
}

.aptify-cta-phone {
    position: relative;
    align-self: stretch;
}

.aptify-cta-phone img {
    position: absolute;
    left: 42%;
    bottom: -160px;
    width: 520px;
    max-width: none;
    transform: translateX(-50%) rotate(7deg);
    filter: saturate(.3) brightness(.76) contrast(1.1) drop-shadow(0 28px 24px rgba(65, 18, 64, .18));
}

.aptify-cta-copy {
    position: relative;
    z-index: 2;
}

.aptify-cta-copy p {
    max-width: 560px;
    margin-top: 22px;
}

.aptify-cta-copy > a {
    width: min(250px, 100%);
    margin-top: 28px;
}

.aptify-footer {
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(0deg, rgba(88, 11, 83, .7), transparent 38%),
        url("images/aptify/overlay-hero.png") center bottom / cover no-repeat,
        var(--aptify-black);
    color: #fff;
    padding: 145px max(30px, calc((100vw - 1180px) / 2)) 34px;
}

.aptify-footer::before {
    top: 0;
    bottom: auto;
    height: 70px;
    background: linear-gradient(180deg, #fff, transparent);
}

.aptify-footer-main {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: 2fr 1fr 1.2fr;
    gap: 90px;
    padding-bottom: 70px;
}

.aptify-footer-main > div {
    display: grid;
    align-content: start;
    gap: 13px;
}

.aptify-footer-main p {
    max-width: 460px;
    color: rgba(255, 255, 255, .55);
    line-height: 1.8;
}

.aptify-footer-main > div:not(:first-child) > strong {
    margin-bottom: 8px;
    font-size: 15px;
}

.aptify-footer-main a:not(.aptify-logo),
.aptify-footer-main span {
    color: rgba(255, 255, 255, .57);
    font-size: 14px;
}

.aptify-footer-main a:not(.aptify-logo):hover {
    color: var(--aptify-pink);
}

.aptify-footer-bottom {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    border-top: 1px solid rgba(255, 255, 255, .14);
    padding-top: 28px;
    color: rgba(255, 255, 255, .46);
    font-size: 12px;
}

.aptify-reveal {
    animation: aptify-reveal both;
    animation-timeline: view();
    animation-range: entry 8% cover 34%;
}

@keyframes aptify-reveal {
    from { opacity: 0; transform: translateY(42px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes aptify-phone-float {
    0%, 100% { transform: translateX(-50%) rotate(-5deg) translateY(0); }
    50% { transform: translateX(-50%) rotate(-3deg) translateY(-16px); }
}

@keyframes aptify-phone-float-screen {
    0%, 100% { transform: translateX(-50%) rotate(-5deg) translateY(0); }
    50% { transform: translateX(-50%) rotate(-3deg) translateY(-16px); }
}

@keyframes aptify-marquee {
    from { transform: translateX(0); }
    to { transform: translateX(-50%); }
}

@media (max-width: 980px) {
    .aptify-nav {
        grid-template-columns: 1fr 1fr;
    }

    .aptify-nav-links {
        display: none;
    }

    .aptify-hero-inner {
        grid-template-columns: 1fr 1fr;
    }

    .aptify-hero-stat {
        display: none;
    }

    .aptify-title-line {
        font-size: clamp(58px, 9vw, 84px);
    }

    .aptify-title-line-left {
        margin-inline-start: .35em;
    }

    .aptify-service-row,
    .aptify-plan-row {
        gap: 18px;
    }

    .aptify-showcase,
    .aptify-process,
    .aptify-faq {
        gap: 48px;
    }

    .aptify-capability {
        grid-template-columns: 52px 1fr 26px;
        padding-inline: 16px;
    }

    .aptify-cta {
        padding-inline: 42px;
    }
}

@media (max-width: 700px) {
    .aptify-hero {
        min-height: 880px;
        background-size: auto 45%, 160% 48%, auto;
    }

    .aptify-nav {
        width: min(100% - 28px, 1280px);
        min-height: 70px;
    }

    .aptify-logo strong {
        font-size: 19px;
    }

    .aptify-outline-button {
        padding: 9px 17px;
    }

    .aptify-hero-inner {
        width: min(100% - 28px, 1280px);
        min-height: 790px;
        grid-template-columns: 1fr;
        align-content: start;
        padding-top: 62px;
    }

    .aptify-title-line {
        font-size: clamp(54px, 17vw, 76px);
    }

    .aptify-title-line-left {
        margin-inline-start: 0;
    }

    .aptify-hero-title p {
        margin-top: 24px;
        font-size: 15px;
    }

    .aptify-scroll-cue {
        width: 48px;
        height: 48px;
        margin-top: 20px;
    }

    .aptify-phone-scene {
        height: 400px;
        margin-top: -28px;
    }

    .aptify-phone-image {
        width: 410px;
        bottom: -46px;
    }

    .aptify-phone-screen {
        top: 54px;
        width: 143px;
        height: 309px;
        border-radius: 20px;
        padding: 20px 10px 10px;
    }

    .aptify-rear-phone-brand {
        left: 71%;
        top: 124px;
        width: 94px;
        min-width: 94px;
        min-height: 42px;
        padding: 4px 7px;
        font-size: 7px;
    }

    .aptify-rear-phone-brand span {
        width: 14px;
        height: 14px;
    }

    .aptify-phone-balance {
        margin-top: 20px;
    }

    .aptify-phone-balance strong {
        font-size: 25px;
    }

    .aptify-phone-chart {
        height: 54px;
    }

    .aptify-phone-contacts {
        margin-top: 10px;
    }

    .aptify-trust-strip {
        flex-wrap: wrap;
        gap: 12px 16px;
        padding: 22px 18px;
        text-align: center;
    }

    .aptify-section {
        width: min(100% - 28px, 1180px);
        padding-block: 76px;
    }

    .aptify-section-heading h2,
    .aptify-showcase-copy h2,
    .aptify-segments-title h2,
    .aptify-cta-copy h2 {
        font-size: 38px;
    }

    .aptify-service-row,
    .aptify-showcase,
    .aptify-process,
    .aptify-capability-list,
    .aptify-plan-row,
    .aptify-faq,
    .aptify-cta,
    .aptify-footer-main {
        grid-template-columns: 1fr;
    }

    .aptify-service-row {
        gap: 46px;
    }

    .aptify-service-item {
        min-height: 200px;
        padding-top: 88px;
    }

    .aptify-service-item img {
        width: 116px;
        height: 116px;
    }

    .aptify-showcase {
        gap: 64px;
    }

    .aptify-showcase-media {
        min-height: 430px;
    }

    .aptify-dashboard-preview {
        inset: 10% -3% 9% 4%;
        padding: 22px;
    }

    .aptify-dashboard-preview > strong {
        font-size: 21px;
    }

    .aptify-preview-chart {
        height: 104px;
    }

    .aptify-process {
        gap: 30px;
    }

    .aptify-capability-list {
        border-top: 0;
    }

    .aptify-capability,
    .aptify-capability:nth-child(odd) {
        min-height: 210px;
        border-top: 1px solid var(--aptify-line);
        border-inline-end: 0;
        padding-inline: 0;
    }

    .aptify-capability:hover {
        padding-inline-start: 12px;
    }

    .aptify-plan-row {
        gap: 22px;
    }

    .aptify-plan {
        min-height: 440px;
        padding: 28px;
    }

    .aptify-faq {
        gap: 34px;
    }

    .aptify-cta {
        width: min(100% - 28px, 1120px);
        min-height: 630px;
        margin-top: 20px;
        padding: 44px 24px;
    }

    .aptify-cta-phone {
        min-height: 280px;
        order: 2;
    }

    .aptify-cta-phone img {
        left: 50%;
        bottom: -190px;
        width: 450px;
    }

    .aptify-footer {
        padding-top: 130px;
    }

    .aptify-footer-main {
        gap: 42px;
    }

    .aptify-footer-bottom {
        display: grid;
    }
}

@media (prefers-reduced-motion: reduce) {
    .aptify-reveal,
    .aptify-phone-image,
    .aptify-phone-screen,
    .aptify-segment-marquee {
        animation: none;
    }

    .aptify-reveal {
        opacity: 1;
        transform: none;
    }
}

.app-shell {
    min-height: 100vh;
}

.sidebar {
    position: fixed;
    inset-block: 0;
    inset-inline-start: 0;
    z-index: 20;
    display: flex;
    width: var(--sidebar-width);
    flex-direction: column;
    overflow-y: auto;
    border-inline-end: 1px solid var(--line);
    background: #ffffff;
    color: var(--ink-900);
    padding: 24px 16px 18px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 11px;
    min-height: 44px;
    padding-inline: 8px;
}

.brand-mark {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border: 1px solid #c9f2dd;
    border-radius: 8px;
    background: var(--accent);
}

.brand-mark svg {
    width: 20px;
    height: 20px;
}

.brand > span:last-child {
    display: grid;
    line-height: 1.1;
}

.brand strong {
    font-size: 17px;
}

.brand small {
    margin-top: 4px;
    color: var(--ink-500);
    font-size: 12px;
}

.primary-nav,
.secondary-nav {
    display: grid;
    gap: 4px;
    margin-top: 30px;
}

.secondary-nav {
    margin-top: 8px;
}

.primary-nav a,
.secondary-nav a {
    position: relative;
    display: grid;
    min-height: 44px;
    grid-template-columns: 22px minmax(0, 1fr) auto;
    align-items: center;
    gap: 11px;
    border-radius: 7px;
    color: var(--ink-600);
    padding: 9px 12px;
    transition: background-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.primary-nav a:hover,
.secondary-nav a:hover {
    background: var(--surface-muted);
    color: var(--ink-950);
    transform: translateX(-2px);
}

.primary-nav a.active {
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.primary-nav a.active::before {
    position: absolute;
    inset-block: 10px;
    inset-inline-start: -16px;
    width: 3px;
    border-radius: 0 3px 3px 0;
    background: var(--accent);
    content: "";
}

.nav-icon {
    display: grid;
    place-items: center;
}

.nav-icon svg {
    width: 19px;
    height: 19px;
}

.nav-count {
    display: grid;
    min-width: 22px;
    height: 22px;
    place-items: center;
    border-radius: 50%;
    background: var(--accent);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
}

.nav-label {
    margin: 32px 12px 0;
    color: var(--ink-500);
    font-size: 11px;
    font-weight: 700;
}

.sidebar-account {
    display: grid;
    grid-template-columns: 36px minmax(0, 1fr) 32px;
    align-items: center;
    gap: 10px;
    margin-top: auto;
    border-top: 1px solid var(--line);
    padding: 18px 4px 0;
}

.account-copy {
    display: grid;
    min-width: 0;
}

.account-copy strong,
.account-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.account-copy strong {
    font-size: 13px;
}

.account-copy small {
    color: #819087;
    font-size: 11px;
}

.workspace-shell {
    min-height: 100vh;
    margin-inline-start: var(--sidebar-width);
}

.topbar {
    position: sticky;
    inset-block-start: 0;
    z-index: 15;
    display: flex;
    height: var(--topbar-height);
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--line);
    background: rgba(255, 255, 255, 0.94);
    padding: 0 30px;
    backdrop-filter: blur(14px);
}

.workspace-switcher {
    display: grid;
    grid-template-columns: 34px auto 16px;
    align-items: center;
    gap: 10px;
}

.workspace-switcher > svg {
    width: 15px;
    height: 15px;
    color: var(--ink-500);
}

.workspace-switcher > span:nth-child(2) {
    display: grid;
}

.workspace-switcher strong {
    font-size: 13px;
}

.workspace-switcher small {
    color: var(--ink-500);
    font-size: 11px;
}

.workspace-symbol {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 7px;
    background: var(--ink-950);
    color: #ffffff;
    font-weight: 800;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.global-search,
.small-search,
.rail-search {
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--surface-muted);
    color: var(--ink-500);
}

.global-search {
    width: min(330px, 32vw);
    height: 40px;
    padding: 0 11px;
}

.global-search svg,
.small-search svg,
.rail-search svg {
    flex: 0 0 auto;
    width: 17px;
    height: 17px;
}

.global-search input,
.small-search input,
.rail-search input {
    width: 100%;
    min-width: 0;
    border: 0;
    outline: 0;
    background: transparent;
}

.global-search kbd {
    border: 1px solid var(--line);
    border-radius: 4px;
    background: #ffffff;
    color: var(--ink-500);
    font-family: inherit;
    font-size: 10px;
    padding: 1px 5px;
}

.icon-button {
    position: relative;
    display: inline-grid;
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #ffffff;
    color: var(--ink-700);
    cursor: pointer;
    transition: border-color 150ms ease, background-color 150ms ease, color 150ms ease;
}

.icon-button:hover {
    border-color: #b8c3bd;
    background: var(--surface-muted);
    color: var(--ink-950);
}

.icon-button svg,
.send-button svg {
    width: 18px;
    height: 18px;
}

.icon-button-dark {
    border-color: transparent;
    background: transparent;
    color: #7f8b85;
}

.notification-dot {
    position: absolute;
    inset-block-start: 7px;
    inset-inline-end: 7px;
    width: 6px;
    height: 6px;
    border: 1px solid #ffffff;
    border-radius: 50%;
    background: #df5e53;
}

.help-link {
    display: flex;
    height: 38px;
    align-items: center;
    gap: 7px;
    color: var(--ink-600);
    font-size: 13px;
    padding: 0 6px;
}

.help-link svg {
    width: 17px;
    height: 17px;
}

.workspace-content {
    width: 100%;
    max-width: 1640px;
    margin: 0 auto;
    padding: 30px;
}

.page-heading {
    display: flex;
    min-height: 84px;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    margin-bottom: 24px;
}

.page-heading-compact {
    min-height: 72px;
    margin-bottom: 18px;
}

.page-heading h1 {
    font-size: 28px;
    font-weight: 760;
    line-height: 1.25;
}

.page-heading p {
    max-width: 650px;
    margin-top: 6px;
    color: var(--ink-600);
    font-size: 14px;
}

.eyebrow {
    display: block;
    margin-bottom: 4px;
    color: var(--accent-dark);
    font-size: 11px;
    font-weight: 800;
}

.heading-actions {
    display: flex;
    align-items: center;
    gap: 9px;
    padding-top: 5px;
}

.button {
    display: inline-flex;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid transparent;
    border-radius: 7px;
    cursor: pointer;
    font-size: 13px;
    font-weight: 720;
    padding: 9px 14px;
    transition: background-color 150ms ease, border-color 150ms ease, transform 150ms ease;
}

.button:hover {
    transform: translateY(-1px);
}

.button svg {
    width: 17px;
    height: 17px;
}

.button:disabled,
.send-button:disabled {
    cursor: not-allowed;
    opacity: 0.5;
    transform: none;
}

.button-primary {
    background: var(--accent);
    color: #ffffff;
}

.button-primary:hover {
    background: var(--accent-dark);
}

.button-secondary {
    border-color: var(--line);
    background: #ffffff;
    color: var(--ink-800);
}

.button-secondary:hover {
    border-color: #b8c3bd;
}

.button-small {
    min-height: 34px;
    padding: 6px 10px;
}

.status-band {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 13px;
    border: 1px solid #bedfce;
    border-radius: var(--radius);
    background: #f0faf5;
    margin-bottom: 20px;
    padding: 14px 16px;
}

.status-band-mark {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 7px;
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.status-band-mark svg {
    width: 22px;
    height: 22px;
}

.status-band > div:nth-child(2) {
    display: grid;
}

.status-band strong {
    font-size: 14px;
}

.status-band span {
    color: var(--ink-600);
    font-size: 12px;
}

.live-indicator,
.channel-health {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    color: var(--accent-dark) !important;
    font-weight: 750;
}

.live-indicator i,
.channel-health i,
.status-pill i,
.chat-header small i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: #22a76d;
    box-shadow: 0 0 0 4px rgba(34, 167, 109, 0.12);
}

.metric-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border-block: 1px solid var(--line);
    margin-bottom: 26px;
}

.welcome-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(460px, 0.75fr);
    align-items: center;
    gap: 24px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: var(--shadow-soft);
    margin-bottom: 22px;
    padding: 28px;
}

.welcome-copy {
    display: flex;
    align-items: center;
    gap: 14px;
}

.welcome-line {
    width: 3px;
    height: 58px;
    border-radius: 4px;
    background: var(--blue);
}

.welcome-copy strong {
    display: block;
    font-size: 18px;
}

.welcome-copy small {
    display: inline-flex;
    margin-top: 8px;
    border: 1px solid var(--line);
    border-radius: 999px;
    background: var(--surface-muted);
    color: var(--ink-600);
    font-size: 11px;
    padding: 5px 10px;
}

.quick-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.quick-stats article {
    display: grid;
    min-height: 116px;
    align-content: center;
    border: 1px solid var(--line);
    border-top: 3px solid var(--blue);
    border-radius: var(--radius);
    background: #ffffff;
    padding: 16px;
}

.quick-stats article:nth-child(2) {
    border-top-color: var(--accent);
}

.quick-stats article:nth-child(3) {
    border-top-color: var(--purple);
}

.quick-icon,
.summary-icon {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 8px;
    background: var(--blue-soft);
    color: var(--blue);
}

.quick-icon.green,
.summary-icon {
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.quick-icon.purple {
    background: var(--purple-soft);
    color: var(--purple);
}

.quick-icon svg,
.summary-icon svg {
    width: 18px;
    height: 18px;
}

.quick-stats strong {
    margin-top: 10px;
    font-size: 22px;
}

.quick-stats small {
    color: var(--ink-500);
    font-size: 10px;
    font-weight: 760;
    text-transform: uppercase;
}

.metric {
    position: relative;
    display: grid;
    min-height: 126px;
    align-content: center;
    border-inline-end: 1px solid var(--line);
    padding: 18px 24px;
}

.metric:last-child {
    border-inline-end: 0;
}

.metric > span {
    color: var(--ink-600);
    font-size: 12px;
}

.metric strong {
    margin-top: 3px;
    font-size: 31px;
    font-weight: 760;
    line-height: 1.2;
}

.metric small {
    position: absolute;
    inset-block-end: 20px;
    inset-inline-end: 20px;
    font-size: 11px;
    font-weight: 750;
}

.positive {
    color: var(--accent-dark);
}

.negative {
    color: var(--danger);
}

.dashboard-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.5fr) minmax(320px, 0.75fr);
    gap: 20px;
}

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

.dashboard-section {
    min-width: 0;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    box-shadow: 0 8px 24px rgba(18, 32, 51, 0.04);
}

.dashboard-section-wide {
    grid-column: span 1;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    padding: 18px;
}

.summary-grid article {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    min-height: 74px;
}

.summary-grid strong {
    font-size: 18px;
}

.summary-grid small {
    display: block;
    color: var(--ink-500);
    font-size: 11px;
}

.ai-card,
.draft-preview {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 14px;
    padding: 20px;
}

.ai-card > span {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 8px;
    background: var(--purple-soft);
    color: var(--purple);
}

.ai-card svg,
.draft-preview svg {
    width: 21px;
    height: 21px;
}

.ai-card p,
.draft-preview p {
    margin-top: 5px;
    color: var(--ink-600);
    font-size: 13px;
    line-height: 1.75;
}

.growth-panel {
    display: grid;
    grid-template-columns: 210px minmax(0, 1fr);
    gap: 20px;
    padding: 20px;
}

.donut-card {
    display: grid;
    align-content: center;
    gap: 10px;
}

.donut {
    display: grid;
    width: 142px;
    height: 142px;
    place-items: center;
    justify-self: center;
    border: 22px solid var(--accent);
    border-radius: 50%;
    background: #ffffff;
}

.donut strong,
.donut span {
    grid-area: 1 / 1;
}

.donut strong {
    margin-top: -12px;
    font-size: 22px;
}

.donut span {
    margin-top: 26px;
    color: var(--ink-500);
    font-size: 9px;
    font-weight: 760;
    text-transform: uppercase;
}

.donut-card p {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    color: var(--ink-600);
    font-size: 12px;
}

.donut-card i {
    width: 8px;
    height: 22px;
    border-radius: 4px;
}

.legend-whatsapp {
    background: var(--accent);
}

.legend-telegram {
    background: var(--blue);
}

.flat-chart {
    display: flex;
    height: 240px;
    align-items: end;
    gap: 12px;
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    background:
        linear-gradient(to top, var(--line-soft) 1px, transparent 1px) 0 0 / 100% 25%,
        #ffffff;
    padding: 16px;
}

.flat-chart i {
    flex: 1;
    min-width: 8px;
    border-radius: 6px 6px 0 0;
    background: var(--accent);
}

.broadcast-empty {
    display: grid;
    min-height: 220px;
    place-items: center;
    align-content: center;
    gap: 8px;
    color: var(--ink-500);
    text-align: center;
    padding: 28px;
}

.broadcast-empty svg {
    width: 48px;
    height: 48px;
    color: #c9d3df;
}

.broadcast-empty strong {
    color: var(--ink-800);
}

.section-heading {
    display: flex;
    min-height: 76px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid var(--line-soft);
    padding: 16px 19px;
}

.section-heading h2 {
    font-size: 16px;
}

.section-heading p {
    margin-top: 3px;
    color: var(--ink-500);
    font-size: 12px;
}

.section-heading > a {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--accent-dark);
    font-size: 12px;
    font-weight: 720;
}

.section-heading > a svg {
    width: 14px;
    height: 14px;
}

.table-wrap {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    text-align: start;
}

.data-table th,
.data-table td {
    border-bottom: 1px solid var(--line-soft);
    padding: 14px 18px;
    vertical-align: middle;
    white-space: nowrap;
}

.data-table th {
    background: #fafbfa;
    color: var(--ink-500);
    font-size: 11px;
    font-weight: 760;
}

.data-table td {
    color: var(--ink-700);
    font-size: 12px;
}

.data-table tbody tr:last-child td {
    border-bottom: 0;
}

.data-table tbody tr {
    transition: background-color 140ms ease;
}

.data-table tbody tr:hover {
    background: #fbfcfb;
}

.data-table td:first-child {
    min-width: 210px;
}

.data-table td strong,
.data-table td small {
    display: block;
}

.data-table td strong {
    color: var(--ink-950);
    font-size: 13px;
}

.data-table td small {
    margin-top: 2px;
    color: var(--ink-500);
    font-size: 10px;
}

.status-pill {
    display: inline-flex;
    min-height: 25px;
    align-items: center;
    gap: 6px;
    border-radius: 999px;
    font-size: 10px;
    font-weight: 780;
    padding: 4px 9px;
}

.status-pill.success {
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.status-pill.active {
    background: var(--blue-soft);
    color: var(--blue);
}

.status-pill.pending {
    background: var(--amber-soft);
    color: var(--amber);
}

.status-pill.muted {
    background: var(--surface-strong);
    color: var(--ink-600);
}

.progress-cell {
    display: grid;
    grid-template-columns: 34px 72px;
    align-items: center;
    gap: 8px;
}

.progress-cell i {
    display: block;
    height: 4px;
    overflow: hidden;
    border-radius: 4px;
    background: var(--surface-strong);
}

.progress-cell b {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--accent);
}

.compact-conversations {
    display: grid;
}

.compact-conversations > a {
    display: grid;
    min-height: 68px;
    grid-template-columns: 38px minmax(0, 1fr) auto;
    align-items: center;
    gap: 11px;
    border-bottom: 1px solid var(--line-soft);
    padding: 10px 17px;
    transition: background-color 140ms ease;
}

.compact-conversations > a:last-child {
    border-bottom: 0;
}

.compact-conversations > a:hover {
    background: var(--surface-muted);
}

.avatar {
    display: grid;
    width: 38px;
    height: 38px;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 50%;
    background: #dfe8e3;
    color: var(--ink-800);
    font-size: 11px;
    font-style: normal;
    font-weight: 780;
}

.avatar-dark {
    width: 36px;
    height: 36px;
    background: #2a3931;
    color: #dfe8e3;
}

.avatar-large {
    width: 44px;
    height: 44px;
    font-size: 12px;
}

.avatar-xl {
    width: 64px;
    height: 64px;
    font-size: 16px;
}

.conversation-copy {
    display: grid;
    min-width: 0;
}

.conversation-copy > span {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.conversation-copy strong,
.conversation-copy small {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.conversation-copy strong {
    font-size: 12px;
}

.conversation-copy small {
    color: var(--ink-500);
    font-size: 11px;
}

.conversation-meta {
    display: grid;
    justify-items: end;
    gap: 7px;
}

.conversation-meta time {
    color: var(--ink-500);
    font-size: 10px;
}

.conversation-meta b,
.unread-count {
    display: grid;
    min-width: 20px;
    height: 20px;
    place-items: center;
    border-radius: 50%;
    background: var(--accent);
    color: #ffffff;
    font-size: 10px;
}

.channel-list {
    display: grid;
}

.channel-list article {
    display: grid;
    min-height: 70px;
    grid-template-columns: 40px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    border-bottom: 1px solid var(--line-soft);
    padding: 12px 17px;
}

.channel-list article:last-child {
    border-bottom: 0;
}

.channel-list article > span:nth-child(2) {
    display: grid;
}

.channel-list strong {
    font-size: 12px;
}

.channel-list small {
    color: var(--ink-500);
    font-size: 11px;
}

.channel-icon,
.connection-logo {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border-radius: 7px;
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.channel-icon svg,
.connection-logo svg {
    width: 20px;
    height: 20px;
}

.channel-health {
    font-size: 10px;
}

.inbox-workspace {
    display: grid;
    height: calc(100vh - var(--topbar-height) - 154px);
    min-height: 620px;
    grid-template-columns: 310px minmax(380px, 1fr) 260px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
}

.conversation-rail,
.contact-inspector {
    min-width: 0;
    overflow: hidden;
    background: #fbfcfb;
}

.conversation-rail {
    display: flex;
    flex-direction: column;
    border-inline-end: 1px solid var(--line);
}

.rail-search {
    height: 40px;
    flex: 0 0 auto;
    margin: 14px;
    padding: 0 11px;
}

.rail-tabs {
    display: grid;
    grid-template-columns: 1fr 1fr;
    border-bottom: 1px solid var(--line);
    padding-inline: 14px;
}

.rail-tabs button {
    position: relative;
    display: flex;
    height: 42px;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: transparent;
    color: var(--ink-500);
    cursor: pointer;
    font-size: 11px;
}

.rail-tabs button.active {
    color: var(--ink-950);
    font-weight: 750;
}

.rail-tabs button.active::after {
    position: absolute;
    inset-block-end: -1px;
    inset-inline: 10px;
    height: 2px;
    background: var(--accent);
    content: "";
}

.rail-tabs span {
    color: var(--ink-500);
}

.conversation-list {
    overflow-y: auto;
}

.conversation-row {
    position: relative;
    display: grid;
    width: 100%;
    min-height: 86px;
    grid-template-columns: 40px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    border-bottom: 1px solid var(--line-soft);
    background: transparent;
    text-align: start;
    padding: 12px 14px;
    cursor: pointer;
    transition: background-color 140ms ease;
}

.conversation-row:hover,
.conversation-row.selected {
    background: #f0f6f2;
}

.conversation-row.selected::before {
    position: absolute;
    inset-block: 0;
    inset-inline-start: 0;
    width: 3px;
    background: var(--accent);
    content: "";
}

.conversation-row time {
    flex: 0 0 auto;
    color: var(--ink-500);
    font-size: 9px;
}

.conversation-row em {
    display: flex;
    min-width: 0;
    align-items: center;
    gap: 5px;
    margin-top: 5px;
    color: var(--ink-500);
    font-size: 9px;
    font-style: normal;
}

.conversation-row em svg {
    width: 12px;
    height: 12px;
}

.conversation-row em b {
    border-radius: 999px;
    background: var(--surface-strong);
    color: var(--ink-600);
    font-size: 8px;
    padding: 2px 6px;
}

.unread-count {
    position: absolute;
    inset-inline-end: 14px;
    inset-block-end: 11px;
}

.chat-panel {
    display: grid;
    min-width: 0;
    grid-template-rows: 68px minmax(0, 1fr) 70px;
    background: #f3f6f4;
}

.chat-header {
    display: grid;
    grid-template-columns: 44px minmax(0, 1fr) auto;
    align-items: center;
    gap: 11px;
    border-bottom: 1px solid var(--line);
    background: #ffffff;
    padding: 10px 15px;
}

.chat-header > span:nth-child(2) {
    display: grid;
}

.chat-header strong {
    font-size: 13px;
}

.chat-header small {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--ink-500);
    font-size: 10px;
}

.chat-header small i {
    width: 6px;
    height: 6px;
    box-shadow: none;
}

.chat-actions {
    display: flex;
    gap: 6px;
}

.chat-stream {
    display: flex;
    flex-direction: column;
    gap: 8px;
    overflow-y: auto;
    padding: 20px 28px;
}

.day-separator {
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 4px 0 10px;
}

.day-separator span {
    border: 1px solid var(--line);
    border-radius: 999px;
    background: #ffffff;
    color: var(--ink-500);
    font-size: 9px;
    padding: 4px 9px;
}

.chat-bubble {
    width: fit-content;
    max-width: min(68%, 560px);
    border: 1px solid var(--line);
    border-radius: 8px;
    background: #ffffff;
    padding: 10px 12px 7px;
    box-shadow: 0 4px 12px rgba(16, 21, 18, 0.04);
    animation: message-in 180ms ease-out both;
}

.chat-bubble.outgoing {
    align-self: flex-start;
    border-color: #b9dfcc;
    background: #e8f7ef;
}

.chat-bubble.incoming {
    align-self: flex-end;
}

.chat-bubble p {
    font-size: 13px;
    line-height: 1.65;
}

.chat-bubble footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 4px;
    margin-top: 4px;
    color: var(--ink-500);
    direction: ltr;
    font-size: 9px;
}

.chat-bubble footer svg {
    width: 13px;
    height: 13px;
    color: var(--accent);
}

.message-composer {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr) 38px 42px;
    align-items: center;
    gap: 8px;
    border-top: 1px solid var(--line);
    background: #ffffff;
    padding: 12px 14px;
}

.message-composer input {
    width: 100%;
    height: 42px;
    border: 1px solid var(--line);
    border-radius: 7px;
    outline: none;
    background: var(--surface-muted);
    padding: 0 13px;
}

.message-composer input:focus {
    border-color: #8abca4;
    background: #ffffff;
    box-shadow: 0 0 0 3px rgba(22, 138, 91, 0.09);
}

.send-button {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 7px;
    background: var(--accent);
    color: #ffffff;
    cursor: pointer;
}

.contact-inspector {
    border-inline-start: 1px solid var(--line);
    overflow-y: auto;
    padding: 20px 16px;
}

.inspector-identity {
    display: grid;
    justify-items: center;
    border-bottom: 1px solid var(--line);
    padding: 6px 0 20px;
}

.inspector-identity strong {
    margin-top: 9px;
    font-size: 13px;
}

.inspector-identity small {
    color: var(--ink-500);
    font-size: 10px;
}

.contact-facts {
    display: grid;
    gap: 12px;
    margin: 18px 0;
}

.contact-facts div {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
}

.contact-facts dt {
    color: var(--ink-500);
    font-size: 10px;
}

.contact-facts dd {
    margin: 0;
    font-size: 10px;
    font-weight: 700;
}

.inspector-section {
    border-top: 1px solid var(--line);
    padding-top: 15px;
    margin-top: 15px;
}

.inspector-section h3 {
    font-size: 11px;
}

.tag-list {
    display: flex;
    gap: 7px;
    margin-top: 10px;
}

.tag-list span {
    border-radius: 999px;
    background: var(--blue-soft);
    color: var(--blue);
    font-size: 9px;
    padding: 4px 8px;
}

.tag-list button {
    display: grid;
    width: 24px;
    height: 24px;
    place-items: center;
    border: 1px dashed #bcc6c1;
    border-radius: 50%;
    background: transparent;
    color: var(--ink-500);
    cursor: pointer;
}

.tag-list svg {
    width: 12px;
    height: 12px;
}

.inspector-section textarea {
    width: 100%;
    min-height: 92px;
    resize: vertical;
    border: 1px solid var(--line);
    border-radius: 7px;
    outline: 0;
    background: #ffffff;
    margin-top: 9px;
    padding: 10px;
    font-size: 11px;
}

.campaign-overview {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border-block: 1px solid var(--line);
    margin-bottom: 20px;
}

.meta-identity-grid,
.compliance-strip {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    margin-bottom: 20px;
}

.meta-identity-grid article {
    display: grid;
    min-height: 104px;
    align-content: center;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    padding: 16px;
}

.meta-identity-grid span,
.meta-identity-grid small {
    color: var(--ink-500);
    font-size: 11px;
}

.meta-identity-grid strong {
    margin: 4px 0;
    color: var(--ink-950);
    font-size: 15px;
    overflow-wrap: anywhere;
}

.compliance-strip {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.compliance-strip article {
    display: grid;
    min-height: 58px;
    grid-template-columns: 28px minmax(0, 1fr);
    align-items: center;
    gap: 10px;
    border: 1px solid #cfdded;
    border-radius: var(--radius);
    background: #f7fbff;
    color: var(--blue);
    padding: 12px 14px;
}

.compliance-strip svg {
    width: 18px;
    height: 18px;
}

.compliance-strip span {
    color: var(--ink-700);
    font-size: 12px;
    font-weight: 720;
}

.campaign-overview article {
    display: grid;
    min-height: 92px;
    align-content: center;
    border-inline-end: 1px solid var(--line);
    padding: 12px 22px;
}

.campaign-overview article:last-child {
    border-inline-end: 0;
}

.campaign-overview span {
    color: var(--ink-500);
    font-size: 11px;
}

.campaign-overview strong {
    margin-top: 2px;
    font-size: 23px;
}

.campaign-layout {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
}

.campaign-layout.composer-open {
    grid-template-columns: minmax(0, 1fr) 340px;
}

.campaign-table-section {
    min-width: 0;
}

.small-search {
    width: 230px;
    height: 36px;
    padding: 0 10px;
}

.campaign-composer {
    align-self: start;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    box-shadow: var(--shadow-soft);
    padding: 18px;
    animation: panel-in 180ms ease-out both;
}

.campaign-composer header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
    border-bottom: 1px solid var(--line);
    margin-bottom: 17px;
    padding-bottom: 15px;
}

.campaign-composer h2 {
    font-size: 17px;
}

.field {
    display: grid;
    gap: 6px;
    margin-bottom: 13px;
}

.field > span {
    color: var(--ink-700);
    font-size: 11px;
    font-weight: 720;
}

.field > .field-hint {
    color: var(--ink-500);
    font-size: 10px;
    line-height: 1.5;
}

.field input,
.field select,
.field textarea {
    width: 100%;
    border: 1px solid var(--line);
    border-radius: 7px;
    outline: 0;
    background: #ffffff;
    padding: 0 10px;
    font-size: 12px;
}

.field input,
.field select {
    height: 40px;
}

.field textarea {
    min-height: 150px;
    resize: vertical;
    padding: 10px;
    line-height: 1.7;
}

.field input:focus,
.field select:focus,
.field textarea:focus {
    border-color: #8abca4;
    box-shadow: 0 0 0 3px rgba(22, 138, 91, 0.08);
}

.ai-workbench {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr);
    gap: 20px;
}

.ai-form {
    padding: 18px;
}

.template-actions {
    display: flex;
    justify-content: flex-end;
    gap: 9px;
    border-top: 1px solid var(--line-soft);
    padding: 16px 18px;
}

.template-actions-inline {
    justify-content: stretch;
    border-top: 0;
    padding: 4px 0 0;
}

.template-actions-inline .button {
    flex: 1 1 0;
}

.send-summary {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    gap: 8px;
    border: 1px solid #cfdded;
    border-radius: 7px;
    background: #f2f6fb;
    color: var(--blue);
    margin-top: 16px;
    padding: 11px;
}

.send-summary svg {
    width: 17px;
    height: 17px;
}

.send-summary p {
    font-size: 10px;
    line-height: 1.6;
}

.readiness-list {
    display: grid;
    gap: 12px;
    padding: 18px;
}

.readiness-list article {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    align-items: center;
    gap: 12px;
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    padding: 12px;
}

.readiness-list small {
    display: block;
    margin-top: 2px;
    color: var(--ink-500);
    font-size: 11px;
}

.ai-suggestion {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    align-items: start;
    gap: 8px;
    border: 1px solid #ded5ff;
    border-radius: var(--radius);
    background: var(--purple-soft);
    color: var(--ink-700);
    margin-top: 10px;
    padding: 10px;
}

.ai-suggestion svg {
    width: 17px;
    height: 17px;
    color: var(--purple);
}

.ai-suggestion span {
    font-size: 11px;
    line-height: 1.6;
}

.campaign-composer footer {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    border-top: 1px solid var(--line);
    margin-top: 18px;
    padding-top: 15px;
}

.campaign-page-heading {
    margin-bottom: 18px;
}

.campaign-notice {
    display: grid;
    min-height: 46px;
    grid-template-columns: 22px 1fr 34px;
    align-items: center;
    gap: 10px;
    border: 1px solid #f0d9a4;
    border-radius: var(--radius);
    background: #fff9ea;
    color: #7a5911;
    margin-bottom: 16px;
    padding: 8px 10px 8px 14px;
}

.campaign-notice.success {
    border-color: #bde8d0;
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.campaign-notice > svg {
    width: 19px;
    height: 19px;
}

.campaign-notice span {
    font-size: 12px;
    font-weight: 700;
}

.campaign-command-bar {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    border-block: 1px solid var(--line);
    background: #fff;
    margin-bottom: 14px;
}

.campaign-command-bar article {
    display: grid;
    min-height: 94px;
    grid-template-columns: 42px 1fr;
    align-items: center;
    gap: 12px;
    border-inline-end: 1px solid var(--line);
    padding: 14px 20px;
}

.campaign-command-bar article:last-child {
    border-inline-end: 0;
}

.campaign-command-bar article > div {
    display: grid;
}

.campaign-command-bar small {
    color: var(--ink-500);
    font-size: 11px;
}

.campaign-command-bar strong {
    font-size: 22px;
}

.campaign-command-bar .quality-value {
    color: var(--accent-dark);
    font-size: 16px;
}

.campaign-metric-icon {
    display: grid;
    width: 38px;
    height: 38px;
    place-items: center;
    border-radius: 7px;
}

.campaign-metric-icon svg {
    width: 18px;
    height: 18px;
}

.campaign-metric-icon.sent { background: var(--blue-soft); color: var(--blue); }
.campaign-metric-icon.delivered { background: var(--accent-soft); color: var(--accent-dark); }
.campaign-metric-icon.read { background: var(--purple-soft); color: var(--purple); }
.campaign-metric-icon.quality { background: #edf9f1; color: #168a58; }

.campaign-safety-rail {
    display: flex;
    min-height: 48px;
    align-items: center;
    gap: 0;
    overflow-x: auto;
    border: 1px solid #dce8e1;
    border-radius: var(--radius);
    background: #f8fbf9;
    margin-bottom: 18px;
}

.campaign-safety-rail span {
    display: flex;
    min-width: max-content;
    align-items: center;
    gap: 7px;
    border-inline-end: 1px solid #dce8e1;
    color: var(--ink-700);
    padding: 0 16px;
    font-size: 11px;
    font-weight: 700;
}

.campaign-safety-rail span:last-child {
    border-inline-end: 0;
}

.campaign-safety-rail svg {
    width: 15px;
    height: 15px;
    color: var(--accent-dark);
}

.campaign-studio {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: 0 18px 50px rgba(18, 32, 51, .09);
    margin-bottom: 20px;
    animation: panel-in 200ms ease-out both;
}

.campaign-studio-header {
    display: flex;
    min-height: 82px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid var(--line);
    padding: 15px 20px;
}

.campaign-studio-header h2 {
    font-size: 19px;
}

.campaign-studio-header p {
    margin-top: 2px;
    color: var(--ink-500);
    font-size: 11px;
}

.campaign-studio-body {
    display: grid;
    min-height: 650px;
    grid-template-columns: 210px minmax(420px, 1fr) 310px;
}

.campaign-stepper {
    display: flex;
    flex-direction: column;
    border-inline-end: 1px solid var(--line);
    background: #fbfcfd;
    padding: 18px 12px;
}

.campaign-stepper button {
    position: relative;
    display: grid;
    min-height: 78px;
    grid-template-columns: 32px 1fr;
    align-items: start;
    gap: 10px;
    border-radius: 7px;
    background: transparent;
    color: var(--ink-600);
    padding: 12px 10px;
    text-align: start;
    cursor: pointer;
}

.campaign-stepper button::after {
    position: absolute;
    top: 50px;
    right: 25px;
    width: 1px;
    height: 40px;
    background: var(--line);
    content: "";
}

.campaign-stepper button:last-child::after {
    display: none;
}

.campaign-stepper button > span {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border: 1px solid var(--line);
    border-radius: 50%;
    background: #fff;
    font-size: 11px;
    font-weight: 900;
}

.campaign-stepper button > div {
    display: grid;
    gap: 3px;
}

.campaign-stepper strong {
    font-size: 12px;
}

.campaign-stepper small {
    color: var(--ink-500);
    font-size: 9px;
    line-height: 1.5;
}

.campaign-stepper button.active {
    background: #fff;
    color: var(--ink-950);
    box-shadow: 0 6px 18px rgba(18, 32, 51, .06);
}

.campaign-stepper button.active > span,
.campaign-stepper button.complete > span {
    border-color: var(--accent);
    background: var(--accent);
    color: #fff;
}

.campaign-editor {
    display: grid;
    min-width: 0;
    grid-template-rows: 1fr auto;
}

.campaign-editor-section {
    padding: 24px;
}

.campaign-editor-title {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid var(--line-soft);
    margin-bottom: 22px;
    padding-bottom: 16px;
}

.campaign-editor-title > div {
    display: flex;
    align-items: center;
    gap: 10px;
}

.campaign-editor-title > div > span {
    color: var(--accent-dark);
    font-size: 11px;
    font-weight: 900;
}

.campaign-editor-title h3 {
    font-size: 17px;
}

.campaign-editor-title > small {
    max-width: 310px;
    color: var(--ink-500);
    font-size: 10px;
    text-align: end;
}

.campaign-form-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 2px 14px;
}

.campaign-form-grid .field-wide {
    grid-column: 1 / -1;
}

.audience-source-tabs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-bottom: 16px;
}

.audience-source-tabs button {
    display: flex;
    min-height: 46px;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #fff;
    color: var(--ink-600);
    cursor: pointer;
    font-size: 11px;
    font-weight: 700;
}

.audience-source-tabs button.active {
    border-color: #9fdbc0;
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.audience-source-tabs svg {
    width: 16px;
    height: 16px;
}

.campaign-upload-zone {
    display: grid;
    min-height: 180px;
    place-items: center;
    align-content: center;
    gap: 7px;
    border: 1px dashed #9bbdaa;
    border-radius: 7px;
    background: #fafdfb;
    color: var(--ink-700);
    cursor: pointer;
    text-align: center;
}

.campaign-upload-zone input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    opacity: 0;
}

.campaign-upload-zone svg {
    width: 34px;
    height: 34px;
    color: var(--accent-dark);
}

.campaign-upload-zone strong {
    font-size: 13px;
}

.campaign-upload-zone span {
    color: var(--ink-500);
    font-size: 10px;
}

.saved-audience-list {
    display: grid;
    gap: 8px;
}

.saved-audience {
    display: grid;
    min-height: 62px;
    grid-template-columns: 18px 1fr auto;
    align-items: center;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 10px 12px;
    cursor: pointer;
}

.saved-audience.selected {
    border-color: #9fdbc0;
    background: var(--accent-soft);
}

.saved-audience > span {
    display: grid;
}

.saved-audience strong,
.saved-audience b {
    font-size: 12px;
}

.saved-audience small {
    color: var(--ink-500);
    font-size: 9px;
}

.audience-validation {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
    margin-top: 14px;
}

.audience-validation > span {
    display: grid;
    border: 1px solid var(--line-soft);
    border-radius: 7px;
    background: #fbfcfd;
    padding: 9px 11px;
}

.audience-validation small {
    color: var(--ink-500);
    font-size: 9px;
}

.audience-validation strong {
    font-size: 16px;
}

.consent-check {
    display: grid;
    grid-template-columns: 18px 1fr;
    align-items: start;
    gap: 10px;
    border: 1px solid #eedba7;
    border-radius: 7px;
    background: #fffaf0;
    margin-top: 14px;
    padding: 12px;
    cursor: pointer;
}

.consent-check > span {
    display: grid;
    gap: 2px;
}

.consent-check strong {
    font-size: 11px;
}

.consent-check small {
    color: #846f43;
    font-size: 9px;
}

.schedule-options {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 10px;
}

.schedule-option {
    display: grid;
    min-height: 100px;
    grid-template-columns: 18px 32px 1fr;
    align-items: center;
    gap: 9px;
    border: 1px solid var(--line);
    border-radius: 7px;
    padding: 14px;
    cursor: pointer;
}

.schedule-option.selected {
    border-color: #9fdbc0;
    background: var(--accent-soft);
}

.schedule-option > svg {
    width: 22px;
    height: 22px;
    color: var(--accent-dark);
}

.schedule-option > span {
    display: grid;
}

.schedule-option strong {
    font-size: 12px;
}

.schedule-option small {
    color: var(--ink-500);
    font-size: 9px;
}

.campaign-schedule-field {
    max-width: 320px;
    margin-top: 16px;
}

.campaign-review-summary {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--line);
    margin-top: 18px;
}

.campaign-review-summary > div {
    display: grid;
    min-height: 66px;
    align-content: center;
    background: #fff;
    padding: 10px 13px;
}

.campaign-review-summary span {
    color: var(--ink-500);
    font-size: 9px;
}

.campaign-review-summary strong {
    margin-top: 3px;
    font-size: 12px;
}

.campaign-editor-actions {
    display: flex;
    min-height: 72px;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    border-top: 1px solid var(--line);
    padding: 12px 18px;
}

.campaign-editor-actions > div {
    display: flex;
    gap: 8px;
}

.campaign-preview-panel {
    display: grid;
    align-content: start;
    border-inline-start: 1px solid var(--line);
    background: #f8faf9;
    padding: 18px;
}

.campaign-preview-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.campaign-preview-heading span {
    font-size: 12px;
    font-weight: 800;
}

.campaign-preview-heading small {
    color: var(--accent-dark);
    font-size: 10px;
    font-weight: 800;
}

.whatsapp-preview-phone {
    overflow: hidden;
    border: 7px solid #17221d;
    border-radius: 26px;
    background: #efeae2;
    box-shadow: 0 18px 36px rgba(20, 42, 31, .15);
}

.whatsapp-preview-topbar {
    display: flex;
    min-height: 58px;
    align-items: center;
    gap: 9px;
    background: #075e54;
    color: #fff;
    padding: 8px 12px;
}

.whatsapp-preview-topbar .avatar {
    display: grid;
    width: 34px;
    height: 34px;
    place-items: center;
    border-radius: 50%;
    background: #fff;
    color: #075e54;
    font-size: 13px;
    font-weight: 900;
}

.whatsapp-preview-topbar > div {
    display: grid;
}

.whatsapp-preview-topbar strong {
    font-size: 11px;
}

.whatsapp-preview-topbar small {
    color: rgba(255, 255, 255, .72);
    font-size: 8px;
}

.whatsapp-preview-wallpaper {
    display: flex;
    min-height: 350px;
    align-items: flex-end;
    background:
        linear-gradient(rgba(239, 234, 226, .92), rgba(239, 234, 226, .92)),
        radial-gradient(circle at 20% 30%, #cdc3b4 1px, transparent 1px);
    background-size: auto, 18px 18px;
    padding: 13px;
}

.whatsapp-template-bubble {
    width: 92%;
    border-radius: 7px;
    background: #fff;
    padding: 11px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, .08);
}

.template-preview-label {
    color: #7a807d;
    font-size: 8px;
    font-weight: 800;
    text-transform: uppercase;
}

.whatsapp-template-bubble p {
    margin-top: 7px;
    font-size: 10px;
    line-height: 1.7;
}

.whatsapp-template-bubble > small {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 3px;
    color: #7a807d;
    font-size: 7px;
}

.whatsapp-template-bubble > small svg {
    width: 11px;
    height: 11px;
    color: #34b7f1;
}

.whatsapp-template-bubble button {
    width: 100%;
    border-top: 1px solid #edf0ef;
    background: transparent;
    color: #168bd2;
    margin-top: 9px;
    padding-top: 9px;
    font-size: 9px;
}

.preview-health {
    display: grid;
    gap: 7px;
    margin: 14px 0;
}

.preview-health span {
    display: flex;
    align-items: center;
    gap: 7px;
    color: var(--ink-600);
    font-size: 10px;
}

.preview-health i {
    width: 7px;
    height: 7px;
    border-radius: 50%;
}

.preview-health i.healthy { background: var(--accent); }
.preview-health i.warning { background: #e3a32c; }

.campaign-test-link {
    justify-content: center;
}

.campaign-list-section {
    min-width: 0;
}

.campaign-list-heading {
    align-items: flex-end;
}

.campaign-list-tools {
    display: flex;
    align-items: center;
    gap: 10px;
}

.campaign-status-filter {
    display: inline-flex;
    min-height: 36px;
    align-items: center;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #f7f9fb;
    padding: 3px;
}

.campaign-status-filter button {
    min-height: 28px;
    border-radius: 5px;
    background: transparent;
    color: var(--ink-500);
    padding: 0 11px;
    cursor: pointer;
    font-size: 10px;
    font-weight: 700;
}

.campaign-status-filter button.active {
    background: #fff;
    color: var(--ink-950);
    box-shadow: 0 2px 7px rgba(18, 32, 51, .08);
}

.campaign-table-detailed td {
    vertical-align: middle;
}

.campaign-progress {
    width: 92px;
    height: 5px;
    overflow: hidden;
    border-radius: 999px;
    background: var(--surface-strong);
}

.campaign-progress i {
    display: block;
    height: 100%;
    border-radius: inherit;
    background: var(--accent);
}

.template-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-block: 1px solid var(--line);
    margin-bottom: 18px;
    padding: 12px 0;
}

.segmented-control {
    display: inline-flex;
    height: 36px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #ffffff;
    padding: 3px;
}

.segmented-control button {
    min-width: 70px;
    border-radius: 5px;
    background: transparent;
    color: var(--ink-500);
    cursor: pointer;
    font-size: 11px;
}

.segmented-control button.active {
    background: var(--ink-950);
    color: #ffffff;
}

.template-studio {
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #fff;
    box-shadow: var(--shadow-soft);
    margin-bottom: 20px;
    animation: panel-in 180ms ease-out both;
}

.template-studio-header {
    display: flex;
    min-height: 82px;
    align-items: center;
    justify-content: space-between;
    gap: 18px;
    border-bottom: 1px solid var(--line);
    padding: 15px 20px;
}

.template-studio-header h2 {
    font-size: 19px;
}

.template-studio-header p {
    margin-top: 2px;
    color: var(--ink-500);
    font-size: 11px;
}

.template-studio-grid {
    display: grid;
    grid-template-columns: minmax(480px, 1fr) 330px;
}

.template-builder {
    display: grid;
    gap: 0;
    padding: 0 24px;
}

.template-builder > section {
    border-bottom: 1px solid var(--line-soft);
    padding: 22px 0;
}

.template-builder-title {
    display: grid;
    grid-template-columns: 28px 1fr;
    align-items: start;
    gap: 10px;
    margin-bottom: 17px;
}

.template-builder-title > span {
    display: grid;
    width: 26px;
    height: 26px;
    place-items: center;
    border-radius: 50%;
    background: var(--accent-soft);
    color: var(--accent-dark);
    font-size: 9px;
    font-weight: 900;
}

.template-builder-title h3 {
    font-size: 14px;
}

.template-builder-title p {
    margin-top: 2px;
    color: var(--ink-500);
    font-size: 10px;
}

.template-builder .field small {
    color: var(--ink-500);
    font-size: 9px;
    text-align: end;
}

.template-variable-warning {
    border: 1px solid #f3d59a;
    border-radius: 7px;
    margin: 18px 0 0;
    padding: 12px;
}

.template-builder-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding: 18px 0;
}

.template-live-preview {
    display: grid;
    align-content: start;
    border-inline-start: 1px solid var(--line);
    background: #f8faf9;
    padding: 18px;
}

.template-preview-phone .whatsapp-preview-wallpaper {
    min-height: 390px;
}

.template-preview-header {
    display: block;
    margin-bottom: 7px;
    font-size: 11px;
}

.template-preview-footer {
    display: block;
    margin-top: 8px;
    color: #7a807d;
    font-size: 8px;
}

.template-preview-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--line);
    margin: 14px 0 0;
}

.template-preview-meta > div {
    display: grid;
    min-height: 54px;
    align-content: center;
    background: #fff;
    padding: 8px 10px;
}

.template-preview-meta dt {
    color: var(--ink-500);
    font-size: 8px;
}

.template-preview-meta dd {
    overflow-wrap: anywhere;
    margin: 2px 0 0;
    font-size: 10px;
    font-weight: 800;
}

.template-state i.pending {
    background: #e3a32c;
}

.status-pill.danger {
    background: var(--danger-soft);
    color: var(--danger);
}

.template-list,
.connection-list {
    display: grid;
    gap: 10px;
}

.template-row {
    display: grid;
    min-height: 86px;
    grid-template-columns: 40px 220px minmax(240px, 1fr) auto 38px 38px;
    align-items: center;
    gap: 14px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    padding: 13px 16px;
}

.template-state {
    position: relative;
}

.template-state > span {
    display: grid;
    width: 40px;
    height: 40px;
    place-items: center;
    border-radius: 7px;
    background: var(--surface-muted);
    color: var(--ink-700);
}

.template-state svg {
    width: 20px;
    height: 20px;
}

.template-state i {
    position: absolute;
    inset-block-end: -2px;
    inset-inline-end: -2px;
    width: 10px;
    height: 10px;
    border: 2px solid #ffffff;
    border-radius: 50%;
    background: var(--accent);
}

.template-identity {
    display: grid;
    min-width: 0;
}

.template-identity strong {
    overflow: hidden;
    font-size: 12px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.template-identity small {
    color: var(--ink-500);
    font-size: 10px;
}

.template-row > p {
    overflow: hidden;
    color: var(--ink-600);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.policy-note {
    display: flex;
    align-items: center;
    gap: 12px;
    border-top: 1px solid var(--line);
    margin-top: 24px;
    padding: 18px 2px;
}

.policy-note-warning {
    border-color: #f3d59a;
    background: #fff8ea;
    color: var(--amber);
    margin-bottom: 20px;
}

.checkbox-field {
    display: grid;
    grid-template-columns: 18px minmax(0, 1fr);
    align-items: start;
    gap: 8px;
    color: var(--ink-700);
    font-size: 12px;
    line-height: 1.6;
    margin: 14px 0;
}

.checkbox-field input {
    width: 16px;
    height: 16px;
    margin-top: 3px;
    accent-color: var(--accent);
}

.api-result {
    display: grid;
    gap: 14px;
    padding: 18px;
}

.api-result dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin: 0;
}

.api-result dl div {
    border: 1px solid var(--line-soft);
    border-radius: var(--radius);
    padding: 10px;
}

.api-result dt {
    color: var(--ink-500);
    font-size: 10px;
}

.api-result dd {
    margin: 3px 0 0;
    color: var(--ink-900);
    font-size: 12px;
    font-weight: 720;
}

.api-result pre {
    min-height: 180px;
    overflow: auto;
    white-space: pre-wrap;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #0f172a;
    color: #e2e8f0;
    margin: 0;
    padding: 14px;
    font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
    font-size: 12px;
    line-height: 1.7;
}

.policy-note > svg {
    width: 22px;
    height: 22px;
    color: var(--accent-dark);
}

.policy-note > div {
    display: grid;
}

.policy-note strong {
    font-size: 12px;
}

.policy-note span {
    color: var(--ink-500);
    font-size: 10px;
}

.connection-row {
    display: grid;
    min-height: 104px;
    grid-template-columns: 48px minmax(170px, 0.7fr) minmax(390px, 1fr) auto;
    align-items: center;
    gap: 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: #ffffff;
    padding: 16px 18px;
}

.connection-logo {
    width: 48px;
    height: 48px;
}

.connection-main {
    display: grid;
    min-width: 0;
}

.connection-main > span {
    display: flex;
    align-items: center;
    gap: 8px;
}

.connection-main strong {
    font-size: 14px;
}

.connection-main small {
    color: var(--ink-500);
    font-size: 11px;
}

.connection-row dl {
    display: grid;
    grid-template-columns: repeat(3, minmax(100px, 1fr));
    gap: 14px;
    margin: 0;
}

.connection-row dl div {
    display: grid;
}

.connection-row dt {
    color: var(--ink-500);
    font-size: 9px;
}

.connection-row dd {
    margin: 2px 0 0;
    font-size: 11px;
    font-weight: 720;
}

.quality-good {
    color: var(--accent-dark);
}

.connection-actions {
    display: flex;
    align-items: center;
    gap: 7px;
}

.connection-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 18px;
    margin-top: 22px;
}

.endpoint-box {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: var(--surface-muted);
    margin: 16px;
    padding: 8px 10px;
}

.endpoint-box code {
    overflow: hidden;
    color: var(--ink-700);
    font-size: 11px;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.check-list {
    display: grid;
    gap: 10px;
    list-style: none;
    margin: 0;
    padding: 0 18px 18px;
}

.check-list li {
    display: flex;
    align-items: center;
    gap: 8px;
    color: var(--ink-500);
    font-size: 11px;
}

.check-list li.done {
    color: var(--ink-800);
}

.check-list svg {
    width: 15px;
    height: 15px;
}

.check-list li.done svg {
    color: var(--accent);
}

.api-readiness {
    display: grid;
    grid-template-columns: 54px minmax(0, 1fr);
    align-items: center;
    gap: 13px;
    padding: 22px 18px;
}

.readiness-mark {
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    border-radius: 50%;
    background: var(--accent-soft);
    color: var(--accent-dark);
}

.readiness-mark svg {
    width: 27px;
    height: 27px;
}

.api-readiness > div {
    display: grid;
}

.api-readiness strong {
    font-size: 13px;
}

.api-readiness span {
    color: var(--ink-500);
    font-size: 11px;
}

.mobile-nav {
    display: none;
}

.valid.modified:not([type=checkbox]) {
    outline: 1px solid var(--accent);
}

.invalid {
    outline: 1px solid var(--danger);
}

.validation-message {
    color: var(--danger);
}

.blazor-error-boundary {
    background: var(--danger);
    color: #ffffff;
    padding: 1rem;
}

.form-control,
.form-select {
    width: 100%;
    min-height: 42px;
    border: 1px solid var(--line);
    border-radius: 7px;
    background: #ffffff;
    padding: 8px 10px;
}

.form-label {
    display: block;
    margin-bottom: 5px;
    font-size: 12px;
    font-weight: 700;
}

.form-floating {
    margin-bottom: 12px;
}

@keyframes message-in {
    from {
        opacity: 0;
        transform: translateY(5px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes panel-in {
    from {
        opacity: 0;
        transform: translateX(-8px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@media (max-width: 1180px) {
    :root {
        --sidebar-width: 220px;
    }

    .contact-inspector {
        display: none;
    }

    .inbox-workspace {
        grid-template-columns: 300px minmax(380px, 1fr);
    }

    .campaign-layout.composer-open {
        grid-template-columns: minmax(0, 1fr) 310px;
    }

    .connection-row {
        grid-template-columns: 48px minmax(170px, 0.7fr) minmax(300px, 1fr);
    }

    .connection-actions {
        grid-column: 2 / -1;
        justify-content: flex-end;
    }

    .welcome-panel,
    .ai-workbench {
        grid-template-columns: 1fr;
    }

    .growth-panel {
        grid-template-columns: 1fr;
    }

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

@media (max-width: 920px) {
    .sidebar {
        display: none;
    }

    .workspace-shell {
        margin-inline-start: 0;
    }

    .workspace-content {
        padding: 24px 20px 96px;
    }

    .global-search {
        display: none;
    }

    .mobile-nav {
        position: fixed;
        inset-inline: 12px;
        inset-block-end: 12px;
        z-index: 30;
        display: grid;
        height: 64px;
        grid-template-columns: repeat(4, 1fr);
        border: 1px solid rgba(255, 255, 255, 0.12);
        border-radius: 8px;
        background: rgba(16, 21, 18, 0.96);
        box-shadow: 0 14px 38px rgba(16, 21, 18, 0.26);
        backdrop-filter: blur(14px);
        padding: 5px 8px;
    }

    .mobile-nav a {
        display: grid;
        place-items: center;
        align-content: center;
        gap: 2px;
        color: #87948d;
        font-size: 9px;
    }

    .mobile-nav a.active {
        color: #ffffff;
    }

    .mobile-nav svg {
        width: 19px;
        height: 19px;
    }

    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .quick-stats {
        grid-template-columns: 1fr;
    }

    .compliance-strip {
        grid-template-columns: 1fr;
    }

    .dashboard-section-wide {
        grid-row: auto;
    }

    .metric-strip,
    .campaign-overview {
        grid-template-columns: 1fr 1fr;
    }

    .metric:nth-child(2),
    .campaign-overview article:nth-child(2) {
        border-inline-end: 0;
    }

    .metric:nth-child(-n + 2),
    .campaign-overview article:nth-child(-n + 2) {
        border-bottom: 1px solid var(--line);
    }

    .campaign-layout.composer-open {
        grid-template-columns: 1fr;
    }

    .campaign-composer {
        grid-row: 1;
    }

    .template-row {
        grid-template-columns: 40px minmax(170px, 0.7fr) minmax(220px, 1fr) auto 38px;
    }

    .template-row > button:last-child {
        display: none;
    }

    .connection-row {
        grid-template-columns: 48px 1fr;
    }

    .connection-row dl,
    .connection-actions {
        grid-column: 2;
    }

    .connection-detail-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 700px) {
    .client-hero,
    .client-section {
        width: min(100% - 24px, 1180px);
    }

    .client-topbar {
        display: grid;
    }

    .client-nav-actions .button,
    .client-hero-actions .button,
    .client-submit-row .button {
        width: 100%;
        justify-content: center;
    }

    .client-hero-grid {
        grid-template-columns: 1fr;
        padding-top: 18px;
    }

    .semsem-landing .client-topbar,
    .semsem-landing .client-hero-grid {
        width: min(100% - 24px, 1180px);
    }

    .semsem-landing .client-hero-grid-simple {
        width: 100%;
        min-height: 0;
        padding: 96px 12px 34px;
    }

    .hero-proof-strip {
        grid-template-columns: 1fr 1fr;
    }

    .semsem-device-stage {
        min-height: 580px;
    }

    .floating-dashboard-card {
        right: 8px;
        bottom: 0;
    }

    .client-hero-copy,
    .client-status-panel,
    .client-section {
        padding: 18px;
    }

    .client-hero-copy {
        min-height: 0;
    }

    .client-hero-copy h1 {
        font-size: 36px;
    }

    .client-hero-copy p {
        font-size: 16px;
    }

    .client-section-heading h2 {
        font-size: 24px;
    }

    .client-requirements-grid,
    .permission-matrix,
    .client-links-grid,
    .client-form-grid {
        grid-template-columns: 1fr;
    }

    .customer-steps-grid,
    .plans-grid,
    .faq-grid {
        grid-template-columns: 1fr;
    }

    .client-flow article {
        grid-template-columns: 46px minmax(0, 1fr);
    }

    .flow-step-number {
        width: 44px;
        height: 44px;
    }

    .topbar {
        height: 62px;
        padding: 0 15px;
    }

    .workspace-switcher {
        grid-template-columns: 32px auto 14px;
    }

    .workspace-symbol {
        width: 32px;
        height: 32px;
    }

    .help-link span {
        display: none;
    }

    .workspace-content {
        padding: 20px 14px 92px;
    }

    .page-heading,
    .page-heading-compact {
        display: grid;
        min-height: 0;
        margin-bottom: 18px;
    }

    .page-heading h1 {
        font-size: 24px;
    }

    .heading-actions {
        width: 100%;
        padding-top: 0;
    }

    .heading-actions .button {
        flex: 1 1 auto;
    }

    .status-band {
        grid-template-columns: 38px minmax(0, 1fr);
    }

    .status-band-mark {
        width: 38px;
        height: 38px;
    }

    .live-indicator {
        grid-column: 2;
    }

    .metric {
        min-height: 105px;
        padding: 14px;
    }

    .metric strong {
        font-size: 24px;
    }

    .metric small {
        position: static;
        margin-top: 5px;
    }

    .section-heading {
        align-items: flex-start;
        padding: 14px;
    }

    .data-table th,
    .data-table td {
        padding: 12px 14px;
    }

    .inbox-workspace {
        height: auto;
        min-height: 0;
        grid-template-columns: 1fr;
        overflow: visible;
    }

    .conversation-rail {
        max-height: 320px;
        border-inline-end: 0;
        border-bottom: 1px solid var(--line);
    }

    .chat-panel {
        min-height: 560px;
    }

    .chat-stream {
        padding: 18px 14px;
    }

    .chat-bubble {
        max-width: 84%;
    }

    .chat-actions .icon-button:nth-child(1),
    .chat-actions .icon-button:nth-child(2) {
        display: none;
    }

    .message-composer {
        grid-template-columns: 34px minmax(0, 1fr) 42px;
        gap: 6px;
        padding: 10px;
    }

    .message-composer > .icon-button:nth-of-type(2) {
        display: none;
    }

    .template-toolbar {
        display: grid;
    }

    .template-toolbar .small-search {
        width: 100%;
    }

    .segmented-control {
        width: 100%;
    }

    .segmented-control button {
        flex: 1;
        min-width: 0;
    }

    .template-row {
        grid-template-columns: 40px minmax(0, 1fr) auto;
        gap: 10px;
    }

    .template-row > p {
        grid-column: 2 / -1;
        white-space: normal;
    }

    .template-row > .icon-button {
        display: none;
    }

    .connection-row dl {
        grid-template-columns: 1fr 1fr;
    }

    .connection-actions {
        justify-content: flex-start;
    }

    .welcome-panel {
        padding: 18px;
    }

    .metric-strip,
    .campaign-overview,
    .summary-grid,
    .meta-identity-grid {
        grid-template-columns: 1fr;
    }

    .metric,
    .campaign-overview article {
        border-inline-end: 0;
        border-bottom: 1px solid var(--line);
    }

    .metric:last-child,
    .campaign-overview article:last-child {
        border-bottom: 0;
    }

    .flat-chart {
        height: 180px;
        gap: 7px;
    }

    .template-actions {
        display: grid;
    }
}

/* Campaign studio responsive overrides must stay after the shared mobile rules. */
@media (max-width: 1180px) {
    .campaign-studio-body {
        grid-template-columns: 180px minmax(380px, 1fr) 270px;
    }
}

@media (max-width: 980px) {
    .campaign-command-bar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .campaign-command-bar article:nth-child(2) {
        border-inline-end: 0;
    }

    .campaign-command-bar article:nth-child(-n + 2) {
        border-bottom: 1px solid var(--line);
    }

    .campaign-studio-body {
        grid-template-columns: 150px minmax(0, 1fr);
    }

    .campaign-preview-panel {
        grid-column: 1 / -1;
        grid-template-columns: minmax(240px, 300px) 1fr;
        gap: 18px;
        border-top: 1px solid var(--line);
        border-inline-start: 0;
    }

    .campaign-preview-heading,
    .preview-health,
    .campaign-test-link {
        grid-column: 2;
    }

    .whatsapp-preview-phone {
        grid-column: 1;
        grid-row: 1 / 5;
    }

    .campaign-list-heading,
    .campaign-list-tools {
        display: grid;
        align-items: stretch;
    }
}

@media (max-width: 700px) {
    .campaign-page-heading .heading-actions {
        display: grid;
        grid-template-columns: 1fr 1fr;
    }

    .campaign-command-bar {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .campaign-command-bar article {
        min-width: 0;
        min-height: 80px;
        grid-template-columns: 32px minmax(0, 1fr);
        padding: 10px;
    }

    .campaign-command-bar strong {
        font-size: 17px;
    }

    .campaign-metric-icon {
        width: 32px;
        height: 32px;
    }

    .campaign-safety-rail {
        max-width: 100%;
    }

    .campaign-studio-body {
        grid-template-columns: minmax(0, 1fr);
    }

    .campaign-stepper {
        display: grid;
        grid-template-columns: repeat(3, minmax(0, 1fr));
        border-inline-end: 0;
        border-bottom: 1px solid var(--line);
        padding: 8px;
    }

    .campaign-stepper button {
        min-width: 0;
        min-height: 58px;
        grid-template-columns: 26px minmax(0, 1fr);
        gap: 5px;
        padding: 7px 4px;
    }

    .campaign-stepper button::after,
    .campaign-stepper small {
        display: none;
    }

    .campaign-stepper button > span {
        width: 25px;
        height: 25px;
    }

    .campaign-stepper strong {
        font-size: 9px;
    }

    .campaign-editor-section {
        padding: 16px;
    }

    .campaign-editor-title {
        display: grid;
    }

    .campaign-editor-title > small {
        text-align: start;
    }

    .campaign-form-grid,
    .schedule-options,
    .campaign-review-summary,
    .audience-source-tabs {
        grid-template-columns: minmax(0, 1fr);
    }

    .audience-source-tabs button {
        justify-content: flex-start;
        padding-inline: 12px;
    }

    .campaign-editor-actions {
        display: grid;
    }

    .campaign-editor-actions > div,
    .campaign-editor-actions .button {
        width: 100%;
    }

    .campaign-editor-actions > div .button {
        flex: 1;
    }

    .campaign-preview-panel {
        display: grid;
        grid-template-columns: minmax(0, 1fr);
    }

    .campaign-preview-heading,
    .whatsapp-preview-phone,
    .preview-health,
    .campaign-test-link {
        grid-column: 1;
        grid-row: auto;
    }

    .whatsapp-preview-phone {
        width: min(100%, 320px);
        margin-inline: auto;
    }

    .campaign-list-section {
        max-width: 100%;
        overflow: hidden;
    }

    .campaign-list-tools {
        width: 100%;
        min-width: 0;
    }

    .campaign-status-filter {
        width: 100%;
        max-width: 100%;
        overflow-x: auto;
    }

    .campaign-status-filter button {
        flex: 1;
        min-width: max-content;
    }

    .campaign-list-tools .small-search {
        width: 100%;
        min-width: 0;
    }

    .campaign-list-section .table-wrap {
        width: 100%;
        max-width: 100%;
        overflow-x: auto;
        overscroll-behavior-inline: contain;
    }
}

@media (max-width: 980px) {
    .template-studio-grid {
        grid-template-columns: minmax(0, 1fr) 290px;
    }
}

@media (max-width: 700px) {
    .template-studio-grid {
        grid-template-columns: minmax(0, 1fr);
    }

    .template-builder {
        padding: 0 16px;
    }

    .template-live-preview {
        border-top: 1px solid var(--line);
        border-inline-start: 0;
    }

    .template-builder-actions {
        display: grid;
    }

    .template-builder-actions .button {
        width: 100%;
        justify-content: center;
    }
}
