:root {
    --brand-50: #eff6ff;
    --brand-100: #dbeafe;
    --brand-200: #bfdbfe;
    --brand-300: #93c5fd;
    --brand-500: #3b82f6;
    --brand-600: #2563eb;
    --brand-700: #1d4ed8;
    --brand-900: #1e3a8a;
    --slate-50: #f8fafc;
    --slate-100: #f1f5f9;
    --slate-200: #e2e8f0;
    --slate-300: #cbd5e1;
    --slate-500: #64748b;
    --slate-700: #334155;
    --slate-900: #0f172a;
    --text-soft: #475569;
}

.workspace-body {
    min-height: 100vh;
}

.workspace-header {
    position: sticky;
    top: 0;
    z-index: 25;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 1.25rem 1.5rem;
    background: #fff;
    border-bottom: 1px solid #dbeafe;
}

.account-menu {
    display: inline-flex;
    align-items: center;
    gap: 0.9rem;
    font-size: 0.88rem;
    flex-wrap: wrap;
}

.account-link {
    max-width: 12rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.quiet-button {
    background: transparent;
    border: 1px solid #93c5fd;
    border-radius: 0.55rem;
    color: inherit;
    padding: 0.55rem 0.95rem;
    cursor: pointer;
    font: inherit;
}

.quiet-button:hover {
    background: var(--brand-50);
    border-color: #60a5fa;
}

.workspace-layout {
    display: grid;
    grid-template-columns: minmax(220px, 290px) minmax(0, 1fr);
    min-height: calc(100vh - 80px);
}

.workspace-sidebar {
    background: #fff;
    border-right: 1px solid #dbeafe;
    position: sticky;
    top: 80px;
    height: calc(100vh - 80px);
    padding: 1.8rem 1.2rem;
}

.workspace-sidebar .eyebrow::after,
.workspace-sidebar .eyebrow::before {
    display: none;
}

.workspace-sidebar nav {
    margin-top: 1.4rem;
    display: grid;
    gap: 0.55rem;
}

.workspace-sidebar nav a {
    display: flex;
    align-items: center;
    gap: 0.65rem;
    border-radius: 0.55rem;
    padding: 0.75rem 0.85rem;
    color: var(--slate-700);
    border: 1px solid transparent;
}

.workspace-sidebar nav a:hover {
    background: #dbeafe;
    border-color: #93c5fd;
    color: var(--slate-900);
}

.workspace-sidebar nav a[aria-current="page"] {
    background: var(--brand-50);
    border-color: #bfdbfe;
    color: var(--slate-900);
    font-weight: 600;
}

.workspace-sidebar nav a span {
    width: 1rem;
    text-align: center;
    color: var(--brand-700);
}

.workspace-sidebar nav a:hover span,
.workspace-sidebar nav a[aria-current="page"] span {
    color: var(--slate-900);
}

.sidebar-note {
    margin-top: 2.3rem;
    border-top: 1px solid var(--slate-200);
    padding-top: 1rem;
    color: var(--text-soft);
    font-size: 0.83rem;
    line-height: 1.65;
}

.admin-sidebar-links {
    margin-top: 0.85rem;
    display: grid;
    gap: 0.55rem;
}

.sidebar-note .status-dot {
    display: inline-block;
    width: 0.45rem;
    height: 0.45rem;
    border-radius: 50%;
    margin-right: 0.35rem;
    background: #10b981;
}

.workspace-main {
    width: 100%;
    max-width: 1450px;
    padding: clamp(1.4rem, 3vw, 2.6rem) clamp(1rem, 3.5vw, 2.5rem) 3rem;
}

.workspace-heading {
    margin-bottom: 1.8rem;
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
}

.workspace-heading h1 {
    margin: 0.55rem 0 0.6rem;
    font-size: clamp(1.8rem, 3vw, 2.9rem);
    line-height: 1.09;
    letter-spacing: -0.02em;
}

.workspace-heading p {
    margin: 0;
    max-width: 40rem;
    color: var(--text-soft);
    line-height: 1.7;
}

.release-pill {
    display: inline-flex;
    padding: 0.45rem 0.8rem;
    border: 1px solid #93c5fd;
    border-radius: 999px;
    font-size: 0.78rem;
    color: var(--brand-700);
    font-weight: 600;
    white-space: nowrap;
    background: #eff6ff;
}

.workspace-panel {
    margin-bottom: 1.4rem;
    border: 1px solid #dbeafe;
    background: #fff;
    border-radius: 0.95rem;
    padding: 1.2rem;
}

.panel-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    margin-bottom: 0.95rem;
}

.panel-heading h2 {
    margin: 0;
    font-size: 1.12rem;
    letter-spacing: -0.02em;
}

.panel-heading > span,
.section-note {
    color: var(--text-soft);
    font-size: 0.84rem;
}

.company-list-item {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    border-top: 1px solid var(--slate-200);
    padding-top: 1.05rem;
    padding-bottom: 0.4rem;
    flex-wrap: wrap;
    margin-top: 0.85rem;
}

.company-list-item h3 {
    margin: 0;
    font-size: 1rem;
}

.company-list-item p {
    margin: 0.24rem 0 0;
    color: var(--text-soft);
    font-size: 0.82rem;
}

.company-list-item > div:nth-child(2) {
    max-width: calc(100% - 9rem);
}

.company-list-item .text-link,
.company-list-item .planned-chip {
    margin-left: auto;
    font-size: 0.8rem;
}

.company-initial {
    flex: 0 0 auto;
    width: 2.75rem;
    height: 2.75rem;
    display: grid;
    place-items: center;
    border-radius: 0.62rem;
    background: #dbeafe;
    font-size: 1.25rem;
    font-weight: 600;
}

.company-state {
    font-size: 0.73rem;
    border-radius: 999px;
    padding: 0.32rem 0.6rem;
    background: #dbeafe;
    color: var(--brand-700);
}

.planned-chip {
    display: inline-block;
    border-radius: 999px;
    background: #ecfeff;
    color: var(--text-soft);
    font-size: 0.72rem;
    padding: 0.33rem 0.7rem;
}

.section-note {
    margin-top: 0;
}

.module-grid {
    margin-top: 1rem;
    display: grid;
    gap: 0.9rem;
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.module-card {
    background: #fff;
    border: 1px solid #dbeafe;
    border-radius: 0.85rem;
    padding: 1.2rem;
}

.module-card--featured {
    border-color: #bfdbfe;
    box-shadow: 0 10px 30px -20px rgb(37 99 235 / 0.45);
    background: linear-gradient(180deg, #eff6ff, #fff);
}

.module-card h3 {
    margin: 0.95rem 0 0.55rem;
    font-size: 1.08rem;
    letter-spacing: -0.02em;
}

.module-card h4 {
    margin: 0.95rem 0 0.55rem;
    font-size: 1.08rem;
    letter-spacing: -0.02em;
}

.module-group {
    margin-top: 1.6rem;
}

.module-group-heading {
    margin: 0;
    font-size: 1.08rem;
    letter-spacing: -0.02em;
    color: var(--slate-900);
}

.module-link {
    margin-top: 0.95rem;
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
}

.module-link--inactive {
    color: var(--text-soft);
    font-size: 0.82rem;
    font-weight: 500;
}

.module-card p {
    margin: 0;
    color: var(--text-soft);
    font-size: 0.88rem;
    line-height: 1.7;
}

.module-links {
    margin-top: 0.95rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
}

.module-links .text-link {
    font-size: 0.82rem;
}

.empty-state {
    color: var(--text-soft);
    padding: 1.8rem 0;
}

.empty-state h3 {
    margin: 0 0 0.5rem;
    color: var(--slate-900);
}

.evidence-panel,
.progress-history {
    margin-top: 1rem;
    border-top: 1px solid var(--slate-200);
    padding-top: 0.85rem;
}

.evidence-list,
.progress-history {
    display: grid;
    gap: 0.65rem;
    padding-left: 1.2rem;
}

.evidence-list li,
.progress-history li {
    color: var(--text-soft);
    line-height: 1.55;
}

.evidence-list small,
.evidence-list span,
.progress-history small {
    display: block;
}

.evidence-selection {
    width: 100%;
    border: 1px solid var(--slate-200);
    border-radius: 0.65rem;
    padding: 0.8rem;
}

.evidence-selection label {
    display: block;
    margin-top: 0.45rem;
}

.evidence-upload > small {
    align-self: center;
    color: var(--text-soft);
}

.credential-secret textarea {
    width: 100%;
    resize: vertical;
    font: 0.85rem/1.5 ui-monospace, SFMono-Regular, Consolas, monospace;
    overflow-wrap: anywhere;
}

.credential-form fieldset {
    flex-basis: 100%;
}

.credential-row {
    grid-template-columns: minmax(0, 1fr) auto;
}

.credential-row small {
    display: block;
    margin-top: 0.45rem;
    color: var(--text-soft);
}

.integration-steps {
    list-style: none;
    padding-left: 0;
}

.integration-downloads {
    margin-top: 1rem;
}

.portfolio-form {
    display: grid;
    gap: 1rem;
}

.portfolio-form textarea {
    min-height: 7rem;
}

.portfolio-choice {
    align-items: flex-start;
}

.portfolio-choice span,
.portfolio-choice small {
    display: block;
}

.portfolio-freeze,
.portfolio-actions,
.publish-confirm {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.75rem;
    margin-top: 1rem;
}

.portfolio-version {
    grid-template-columns: minmax(0, 1fr) minmax(15rem, auto);
}

.portfolio-public-main {
    width: min(920px, calc(100% - 2rem));
    margin: 0 auto;
    padding: 5rem 0;
}

.portfolio-public-main > h1 {
    max-width: 18ch;
    font-size: clamp(2.5rem, 7vw, 5.5rem);
    letter-spacing: -0.055em;
    line-height: 0.96;
}

.portfolio-byline,
.portfolio-integrity {
    color: var(--text-soft);
}

.portfolio-evidence {
    padding: 1.25rem 0;
    border-top: 1px solid var(--line);
}

@media (max-width: 1140px) {
    .workspace-layout {
        grid-template-columns: 200px minmax(0, 1fr);
    }

    .workspace-heading {
        flex-direction: column;
        gap: 0.5rem;
    }

    .module-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 900px) {
    .workspace-layout {
        display: block;
    }

    .workspace-sidebar {
        position: static;
        top: auto;
        height: auto;
        border-right: 0;
        border-bottom: 1px solid #dbeafe;
        padding: 1rem 0.9rem;
    }

    .workspace-sidebar .eyebrow,
    .sidebar-note {
        display: none;
    }

    .workspace-sidebar nav {
        display: flex;
        gap: 0.45rem;
        overflow: auto;
        margin: 1rem 0 0;
    }

    .workspace-sidebar nav a {
        white-space: nowrap;
        padding: 0.6rem 0.65rem;
    }

    .workspace-sidebar nav a span {
        display: none;
    }
}

@media (max-width: 620px) {
    .workspace-header {
        flex-wrap: wrap;
        padding: 1rem 0.9rem;
    }

    .account-menu {
        justify-content: space-between;
        width: 100%;
    }

    .workspace-main {
        padding: 1.4rem 0.9rem 2rem;
    }

    .workspace-heading h1 {
        font-size: clamp(1.6rem, 7vw, 2.1rem);
    }

    .module-grid {
        grid-template-columns: 1fr;
    }

    .company-list-item > div:nth-child(2) {
        max-width: 100%;
    }

    .company-list-item .text-link,
    .company-list-item .planned-chip {
        margin-left: 0;
    }
}

.company-site-body { margin: 0; min-height: 100vh; background: #f8fafc; color: #0f172a; font-family: Inter, sans-serif; }
.company-site-header { min-height: 4rem; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0 2rem; border-bottom: 1px solid #e2e8f0; background: rgba(255,255,255,.96); }
.company-site-header .brand { display: flex; align-items: center; gap: .65rem; color: #0f172a; text-decoration: none; font-weight: 800; letter-spacing: -.02em; }
.company-site-header .brand-mark { display: grid; place-items: center; width: 2rem; height: 2rem; border-radius: .5rem; color: #fff; background: #2563eb; }
.company-site-header nav { display: flex; align-items: center; gap: 1rem; margin-left: auto; }
.company-site-header small { display: block; color: #64748b; font-size: .62rem; letter-spacing: .12em; }
.company-site-main { width: min(920px, calc(100% - 2rem)); margin: 0 auto; padding: clamp(3rem, 8vw, 7rem) 0; }
.company-site-main h1 { max-width: 16ch; margin: .5rem 0 2rem; font-size: clamp(2.5rem, 7vw, 5.5rem); line-height: 1; letter-spacing: -.055em; }
.company-site-content { padding: clamp(1.25rem, 4vw, 2.5rem); border: 1px solid #dbe4f0; border-radius: 1.25rem; background: #fff; box-shadow: 0 20px 50px rgba(15,23,42,.08); font-size: 1.05rem; line-height: 1.75; }
.company-site-content img { max-width: 100%; height: auto; }
.company-site-footer { display: flex; justify-content: center; gap: 1rem; padding: 2rem; border-top: 1px solid #e2e8f0; color: #64748b; text-align: center; font-size: .85rem; }
@media (max-width: 620px) { .company-site-header { padding: .8rem 1rem; align-items: flex-start; flex-direction: column; } }
