:root {
    --blue: #2563eb;
    --blue-dark: #1d4ed8;
    --green: #16a34a;
    --amber: #d97706;
    --red: #dc2626;
    --background: #f4f6f8;
    --card: #ffffff;
    --text: #111827;
    --muted: #667085;
    --line: #d9e1ec;
    --focus: rgba(37, 99, 235, 0.22);
    --shadow: 0 24px 60px rgba(15, 23, 42, 0.10);
}

* {
    box-sizing: border-box;
}

html {
    min-height: 100%;
}

body {
    min-height: 100%;
    margin: 0;
    background: var(--background);
    color: var(--text);
    font-family: "Inter", Arial, Helvetica, sans-serif;
    line-height: 1.5;
}

button,
input {
    font: inherit;
}

button,
label {
    -webkit-tap-highlight-color: transparent;
}

.container {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
}

.site-header {
    background: rgba(255, 255, 255, 0.88);
    border-bottom: 1px solid var(--line);
    backdrop-filter: blur(14px);
}

.header-inner {
    display: flex;
    min-height: 74px;
    align-items: center;
    justify-content: space-between;
}

.brand {
    display: inline-flex;
    align-items: center;
    color: var(--text);
    text-decoration: none;
}

.brand-logo {
    display: block;
    width: auto;
    height: 42px;
}

.main-content {
    min-height: calc(100vh - 142px);
}

.hero {
    padding: 72px 0 56px;
}

.hero-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(340px, 460px);
    gap: 48px;
    align-items: center;
}

.hero-copy {
    max-width: 680px;
}

.eyebrow {
    margin: 0 0 14px;
    color: var(--green);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0;
    text-transform: uppercase;
}

h1,
h2,
p {
    margin-top: 0;
}

h1 {
    margin-bottom: 20px;
    font-size: clamp(2.45rem, 5vw, 4.9rem);
    line-height: 1.02;
    letter-spacing: 0;
}

.hero-subheadline {
    max-width: 620px;
    margin-bottom: 0;
    color: var(--muted);
    font-size: 1.18rem;
}

.upload-card,
.results-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--card);
    box-shadow: var(--shadow);
}

.upload-card {
    padding: 24px;
}

.upload-card-header {
    margin-bottom: 18px;
}

.upload-card-header h2 {
    margin-bottom: 4px;
    font-size: 1.18rem;
}

.upload-card-header p {
    margin-bottom: 0;
    color: var(--muted);
    font-size: 0.95rem;
}

.drop-zone {
    display: grid;
    min-height: 310px;
    place-items: center;
    gap: 8px;
    padding: 28px;
    border: 2px dashed #b7c3d4;
    border-radius: 8px;
    background: #fbfcff;
    text-align: center;
    cursor: pointer;
    transition: background 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.drop-zone:hover,
.drop-zone.is-dragging {
    border-color: var(--blue);
    background: #eff6ff;
    box-shadow: 0 0 0 4px var(--focus);
}

.drop-zone input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
}

.upload-icon {
    display: grid;
    width: 58px;
    height: 58px;
    place-items: center;
    border-radius: 8px;
    background: #e8f0ff;
    color: var(--blue);
    font-size: 2rem;
    font-weight: 700;
    line-height: 1;
}

.drop-title {
    font-size: 1.05rem;
    font-weight: 800;
}

.drop-help,
.file-name {
    color: var(--muted);
    font-size: 0.94rem;
}

.file-name {
    max-width: 100%;
    overflow-wrap: anywhere;
}

.file-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 18px;
}

.file-picker-button {
    display: inline-flex;
    min-height: 42px;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--line);
    border-radius: 8px;
    padding: 0 16px;
    background: #ffffff;
    color: var(--blue-dark);
    font-weight: 800;
    cursor: pointer;
}

.file-picker-button:hover {
    border-color: var(--blue);
    box-shadow: 0 0 0 4px var(--focus);
}

.supported-files {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
}

.supported-files span {
    display: inline-flex;
    min-height: 30px;
    align-items: center;
    border-radius: 999px;
    padding: 0 10px;
    background: #eef2f7;
    color: #344054;
    font-size: 0.78rem;
    font-weight: 800;
}

.supported-files span:nth-child(1) {
    background: #eff6ff;
    color: var(--blue-dark);
}

.supported-files span:nth-child(2) {
    background: #f0fdf4;
    color: var(--green);
}

.supported-files span:nth-child(3) {
    background: #fffbeb;
    color: var(--amber);
}

.supported-files span:nth-child(4) {
    background: #fef2f2;
    color: var(--red);
}

.primary-button {
    display: inline-flex;
    width: 100%;
    min-height: 52px;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 18px;
    border: 0;
    border-radius: 8px;
    background: var(--blue);
    color: #ffffff;
    font-weight: 800;
    cursor: pointer;
    transition: background 160ms ease, opacity 160ms ease, transform 160ms ease;
}

.primary-button:hover:not(:disabled) {
    background: var(--blue-dark);
    transform: translateY(-1px);
}

.primary-button:disabled {
    cursor: not-allowed;
    opacity: 0.48;
}


.button-spinner {
    display: none;
    width: 18px;
    height: 18px;
    border: 2px solid rgba(255, 255, 255, 0.45);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: spin 800ms linear infinite;
}

.primary-button.is-loading .button-spinner {
    display: inline-block;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.upload-card.is-processing .drop-zone,
.upload-card.is-processing .file-picker-button,
.upload-card.is-processing .supported-files {
    pointer-events: none;
    opacity: 0.68;
}

.progress-container {
    display: grid;
    justify-items: center;
    margin-top: 24px;
}

.progress-container[hidden] {
    display: none;
}

.progress-card {
    display: grid;
    width: min(100%, 560px);
    justify-items: center;
    gap: 10px;
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--card);
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.10);
    padding: 28px;
    text-align: center;
    transform: translateY(0);
    opacity: 1;
    transition: opacity 300ms ease, transform 300ms ease, border-color 300ms ease;
}

.progress-card.is-fading {
    opacity: 0;
    transform: translateY(-6px);
}

.progress-spinner {
    width: 42px;
    height: 42px;
    border: 3px solid #dbeafe;
    border-top-color: var(--blue);
    border-radius: 50%;
    animation: spin 850ms linear infinite;
}

.progress-check {
    display: grid;
    width: 42px;
    height: 42px;
    place-items: center;
    border-radius: 50%;
    background: #ecfdf3;
    color: var(--green);
    font-size: 1.45rem;
    font-weight: 800;
}

.progress-check[hidden],
.progress-spinner[hidden] {
    display: none;
}

.progress-card h2 {
    margin: 8px 0 0;
    color: var(--blue-dark);
    font-size: 1.15rem;
}

.progress-card p {
    max-width: 390px;
    margin: 0;
    color: var(--muted);
}

.progress-card.is-complete {
    border-color: #bbf7d0;
}

.progress-card.is-complete h2 {
    color: var(--green);
}

.progress-card.is-error {
    border-color: #fecaca;
    background: #fffafa;
}

.progress-card.is-error h2 {
    color: var(--red);
}

.results-section.is-awaiting-reveal {
    display: none;
}

.results-section.is-revealed {
    animation: revealReport 420ms ease both;
}

@keyframes revealReport {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}
.results-section {
    padding: 0 0 56px;
}

.report-container {
    display: grid;
    gap: 24px;
}

.upload-success-banner,
.report-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--card);
    box-shadow: 0 16px 42px rgba(15, 23, 42, 0.08);
}

.upload-success-banner {
    padding: 22px 24px;
}

.status-label {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 16px;
    color: var(--green);
    font-size: 1.1rem;
    font-weight: 800;
}

.upload-details {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 16px;
    margin: 0;
}

.upload-details div {
    border-top: 1px solid var(--line);
    padding-top: 12px;
}

.upload-details dt {
    margin-bottom: 3px;
    color: var(--muted);
    font-size: 0.88rem;
    font-weight: 700;
}

.upload-details dd {
    margin: 0;
    color: var(--text);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.analysis-report {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 20px;
}

.report-card {
    padding: 24px;
}

.report-card:first-child {
    grid-column: 1 / -1;
}

.report-card h2 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 14px;
    color: var(--blue-dark);
    font-size: 1.08rem;
    letter-spacing: 0;
}

.report-icon {
    display: inline-grid;
    width: 34px;
    height: 34px;
    flex: 0 0 auto;
    place-items: center;
    border-radius: 8px;
    background: #eff6ff;
    color: var(--blue-dark);
    font-size: 1rem;
}

.report-content {
    color: #243042;
    font-size: 0.98rem;
    line-height: 1.65;
}

.report-content p {
    margin: 0 0 14px;
    color: #243042;
}

.report-content p:last-child,
.report-content ul:last-child,
.report-content ol:last-child {
    margin-bottom: 0;
}

.report-content ul,
.report-content ol {
    display: grid;
    gap: 8px;
    margin: 0 0 14px;
    padding-left: 22px;
}

.report-content li {
    padding-left: 2px;
}

.notice {
    margin-bottom: 16px;
    padding: 12px 14px;
    border-radius: 8px;
    font-size: 0.94rem;
    font-weight: 600;
}

.notice-error {
    border: 1px solid #fecaca;
    background: #fef2f2;
    color: var(--red);
}
.site-footer {
    border-top: 1px solid var(--line);
    background: #ffffff;
}

.footer-inner {
    display: flex;
    min-height: 68px;
    align-items: center;
    color: var(--muted);
    font-size: 0.9rem;
}

@media (max-width: 900px) {
    .hero {
        padding: 48px 0;
    }

    .hero-grid {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .hero-copy {
        max-width: none;
    }
    .analysis-report {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .container {
        width: min(100% - 24px, 1120px);
    }

    .hero {
        padding: 34px 0;
    }

    h1 {
        font-size: 2.3rem;
    }

    .hero-subheadline {
        font-size: 1.02rem;
    }

    .upload-card {
        padding: 18px;
    }

    .drop-zone {
        min-height: 250px;
        padding: 20px;
    }

    .file-actions {
        align-items: stretch;
        flex-direction: column;
    }

    .upload-details {
        grid-template-columns: 1fr;
    }

    .supported-files {
        justify-content: flex-start;
    }
}
/* Version 1.0 polish */
.hero.has-report .hero-grid {
    display: none;
}

.compact-upload-container {
    margin-top: 24px;
}

.compact-upload-card,
.report-header-card,
.report-toolbar,
.report-card {
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--card);
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
}

.compact-upload-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    padding: 22px 24px;
}

.compact-upload-details {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 12px;
}

.compact-reset-button {
    width: auto;
    min-width: 220px;
    margin-top: 0;
    padding: 0 18px;
}

.report-container {
    gap: 22px;
}

.report-header-card {
    display: grid;
    grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.4fr);
    gap: 22px;
    padding: 26px;
}

.report-header-card h2 {
    margin-bottom: 8px;
    color: var(--text);
    font-size: 1.6rem;
    line-height: 1.15;
}

.report-header-card p {
    margin-bottom: 0;
    color: var(--green);
    font-weight: 800;
}

.report-meta {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin: 0;
}

.report-meta div {
    border-top: 1px solid var(--line);
    padding-top: 10px;
}

.report-meta dt {
    margin-bottom: 3px;
    color: var(--muted);
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
}

.report-meta dd {
    margin: 0;
    color: var(--text);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.report-toolbar {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 14px;
    padding: 16px 18px;
}

.secondary-button {
    min-height: 42px;
    border: 1px solid var(--blue);
    border-radius: 8px;
    background: #ffffff;
    color: var(--blue-dark);
    cursor: pointer;
    font-weight: 800;
    padding: 0 16px;
}

.secondary-button:hover {
    background: #eff6ff;
}

.copy-feedback {
    color: var(--green);
    font-size: 0.92rem;
    font-weight: 800;
}

.analysis-report {
    align-items: stretch;
}

.report-card-wrap {
    display: flex;
    min-width: 0;
    opacity: 0;
    transform: translateY(10px);
    animation: cardRise 260ms ease forwards;
    animation-delay: calc(var(--stagger-index) * 35ms);
}

.report-card-wrap:first-child {
    grid-column: 1 / -1;
}

.report-card {
    display: flex;
    width: 100%;
    flex-direction: column;
    padding: 26px;
}

.report-card h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 14px;
    color: var(--blue-dark);
    font-size: 1.08rem;
    line-height: 1.25;
}

.report-card-summary {
    border-left: 5px solid var(--blue);
    padding: 32px;
}

.report-card-summary h3 {
    font-size: 1.45rem;
}

.report-card-summary .report-content {
    font-size: 1.08rem;
    line-height: 1.75;
}

.report-icon {
    font-size: 1.05rem;
}

.drop-zone:focus-visible,
.primary-button:focus-visible,
.secondary-button:focus-visible,
.file-picker-button:focus-visible,
.compact-reset-button:focus-visible {
    outline: 3px solid var(--focus);
    outline-offset: 3px;
}

.results-section.is-revealed {
    animation: revealReport 260ms ease both;
}

.progress-card.is-fading {
    transition-duration: 240ms;
}

@keyframes cardRise {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@media (max-width: 900px) {
    .compact-upload-card,
    .report-header-card {
        grid-template-columns: 1fr;
    }

    .compact-upload-card {
        align-items: stretch;
        flex-direction: column;
    }

    .compact-reset-button {
        width: 100%;
    }

    .report-meta {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 560px) {
    .compact-upload-details,
    .upload-details {
        grid-template-columns: 1fr;
    }

    .report-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .secondary-button {
        width: 100%;
    }

    .report-card,
    .report-card-summary,
    .report-header-card,
    .compact-upload-card {
        padding: 20px;
    }
}
/* Version 1.1 progress and report actions */
.progress-panel {
    width: min(100%, 680px);
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--card);
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.10);
    padding: 24px;
    opacity: 1;
    transform: translateY(0);
    transition: opacity 240ms ease, transform 240ms ease, border-color 240ms ease;
}

.progress-panel.is-fading {
    opacity: 0;
    transform: translateY(-6px);
}

.progress-panel.is-complete {
    border-color: #bbf7d0;
}

.progress-panel.is-error {
    border-color: #fecaca;
    background: #fffafa;
}

.progress-document-info {
    margin-bottom: 18px;
    border-radius: 8px;
    background: #f8fafc;
    padding: 16px;
}

.progress-document-info[hidden] {
    display: none;
}

.progress-document-info dl {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin: 0;
}

.progress-document-info dt {
    color: var(--muted);
    font-size: 0.78rem;
    font-weight: 800;
    text-transform: uppercase;
}

.progress-document-info dd {
    margin: 0;
    color: var(--text);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.progress-document-info p {
    margin: 14px 0 0;
    color: var(--blue-dark);
    font-weight: 700;
}

.progress-steps {
    display: grid;
    gap: 12px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.progress-steps li {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    color: var(--muted);
    font-weight: 700;
}

.step-indicator {
    display: grid;
    width: 24px;
    height: 24px;
    place-items: center;
    border: 2px solid #cbd5e1;
    border-radius: 50%;
    background: #ffffff;
}

.progress-steps li.is-complete {
    color: var(--text);
}

.progress-steps li.is-complete .step-indicator {
    border-color: var(--green);
    background: #ecfdf3;
    color: var(--green);
}

.progress-steps li.is-complete .step-indicator::before {
    content: "✓";
    font-size: 0.86rem;
    font-weight: 900;
}

.progress-steps li.is-current {
    color: var(--blue-dark);
}

.progress-steps li.is-current .step-indicator {
    border-color: #dbeafe;
    border-top-color: var(--blue);
    animation: spin 850ms linear infinite;
}

.friendly-wait-message {
    margin: 18px 0 0;
    color: var(--text);
    font-weight: 700;
    text-align: center;
}

.slow-response-message {
    margin: 12px 0 0;
    border-radius: 8px;
    background: #eff6ff;
    color: var(--blue-dark);
    padding: 12px;
    font-weight: 700;
    text-align: center;
}

.slow-response-message[hidden] {
    display: none;
}

.error-card-container {
    margin-top: 24px;
}

.analysis-error-card {
    border: 1px solid #fecaca;
    border-radius: 12px;
    background: #fffafa;
    box-shadow: 0 18px 48px rgba(15, 23, 42, 0.08);
    padding: 24px;
}

.analysis-error-card h2 {
    margin-bottom: 8px;
    color: var(--red);
    font-size: 1.2rem;
}

.analysis-error-card p {
    color: var(--muted);
}

.retry-button {
    width: auto;
    min-width: 180px;
}

.report-toolbar {
    flex-wrap: wrap;
    justify-content: space-between;
}

.report-toolbar .secondary-button {
    flex: 0 0 auto;
}

.report-card.is-collapsed .report-content {
    display: none;
}

.results-section.is-revealed .report-card-wrap {
    animation-duration: 240ms;
}

@media (max-width: 760px) {
    .progress-document-info dl {
        grid-template-columns: 1fr;
    }

    .report-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .report-toolbar .secondary-button,
    .retry-button {
        width: 100%;
    }
}

/* Document Helper 1.0 RC shell foundation */
.site-header,
.site-footer {
    background: rgba(255, 255, 255, 0.94);
}

.site-header {
    position: sticky;
    top: 0;
    z-index: 20;
}

.header-inner,
.footer-inner,
.app-shell {
    width: min(1280px, calc(100% - 32px));
    margin: 0 auto;
}

.header-inner {
    min-height: 72px;
    padding: 0;
}

.header-note {
    color: var(--muted);
    font-size: 0.92rem;
    font-weight: 700;
}

.main-content {
    min-height: calc(100vh - 134px);
}

.app-shell-section {
    padding: 32px 0 48px;
}

.app-shell {
    display: grid;
    grid-template-columns: 288px minmax(0, 1fr);
    gap: 32px;
    align-items: start;
}

.app-sidebar {
    position: sticky;
    top: 104px;
    min-height: calc(100vh - 176px);
}

.app-main {
    display: grid;
    min-width: 0;
    gap: 24px;
}

.workspace-header {
    max-width: 840px;
    padding: 10px 0 8px;
}

.workspace-header h1 {
    max-width: 820px;
    margin-bottom: 16px;
    font-size: clamp(2.35rem, 4vw, 4.25rem);
}

.upload-workspace {
    max-width: 760px;
}

.app-shell-section.has-report .upload-workspace {
    display: none;
}

.shell-region,
.upload-card,
.progress-panel,
.analysis-error-card {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: var(--card);
    box-shadow: 0 16px 42px rgba(15, 23, 42, 0.07);
}

.shell-region {
    position: relative;
    min-height: 160px;
}

.shell-region::before {
    content: "";
    position: absolute;
    inset: 20px;
    border-radius: 8px;
    background: linear-gradient(90deg, #eef2f7 0 28%, #f8fafc 28% 100%);
    opacity: 0.72;
}

.app-sidebar.shell-region {
    min-height: calc(100vh - 176px);
}

.app-sidebar.shell-region::before {
    inset: 18px;
    background:
        linear-gradient(#eef2f7, #eef2f7) 0 0 / 58% 18px no-repeat,
        linear-gradient(#f8fafc, #f8fafc) 0 42px / 100% 72px no-repeat,
        linear-gradient(#f8fafc, #f8fafc) 0 132px / 100% 140px no-repeat;
}

.results-section {
    display: grid;
    gap: 24px;
    padding: 0;
}

.results-section[hidden] {
    display: none;
}

.toolbar-shell {
    min-height: 72px;
}

.overview-dashboard-shell {
    min-height: 220px;
}

.report-content-shell {
    min-height: 420px;
}

.progress-container {
    width: min(100%, 760px);
    margin-top: 0;
    justify-items: stretch;
}

.progress-panel {
    width: 100%;
}

.analysis-error-card {
    max-width: 760px;
}

.footer-inner {
    min-height: 62px;
    padding: 0;
}

@media (max-width: 920px) {
    .header-inner,
    .footer-inner,
    .app-shell {
        width: min(100% - 24px, 1280px);
    }

    .app-shell {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .app-sidebar,
    .app-sidebar.shell-region {
        position: relative;
        top: auto;
        min-height: 148px;
    }

    .workspace-header h1 {
        font-size: 2.5rem;
    }

    .upload-workspace,
    .progress-container,
    .analysis-error-card {
        max-width: none;
        width: 100%;
    }
}

@media (max-width: 560px) {
    .header-inner {
        min-height: 66px;
    }

    .header-note {
        display: none;
    }

    .app-shell-section {
        padding: 24px 0 36px;
    }

    .app-main {
        gap: 20px;
    }

    .workspace-header h1 {
        font-size: 2.08rem;
    }

    .shell-region {
        min-height: 132px;
    }

    .overview-dashboard-shell {
        min-height: 180px;
    }

    .report-content-shell {
        min-height: 320px;
    }
}

/* Landing page mockup alignment */
body {
    background: #f8fafc;
}

.site-header {
    border-bottom: 0;
    background: #f8fafc;
    backdrop-filter: none;
}

.header-inner {
    width: min(100% - 48px, 1180px);
    min-height: 62px;
}

.brand {
    color: var(--blue);
}

.brand-logo {
    height: 40px;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 36px;
    margin-left: auto;
}

.site-nav a {
    color: #475467;
    font-size: 0.78rem;
    font-weight: 800;
    text-decoration: none;
}

.site-nav a:hover,
.site-nav a:focus-visible {
    color: var(--blue-dark);
}

.header-action {
    display: inline-flex;
    min-height: 38px;
    align-items: center;
    justify-content: center;
    margin-left: 28px;
    border-radius: 7px;
    background: var(--blue);
    color: #ffffff;
    font-size: 0.78rem;
    font-weight: 800;
    padding: 0 18px;
    text-decoration: none;
    box-shadow: 0 10px 22px rgba(37, 99, 235, 0.18);
}

.header-action:hover,
.header-action:focus-visible {
    background: var(--blue-dark);
}

.app-shell-section {
    padding: 42px 0 34px;
}

.app-shell {
    display: block;
    width: min(100% - 48px, 1180px);
}

.app-sidebar {
    display: none;
}

.app-main {
    justify-items: center;
    gap: 28px;
}

.workspace-header {
    max-width: 760px;
    padding: 0;
    text-align: center;
}

.workspace-header h1 {
    max-width: 720px;
    margin: 0 auto 14px;
    color: #0f172a;
    font-size: clamp(2.3rem, 5vw, 3.85rem);
    line-height: 1.06;
    text-align: center;
}

.workspace-header h1 span {
    color: var(--blue);
}

.hero-subheadline {
    max-width: 560px;
    margin: 0 auto;
    color: #475467;
    font-size: 1.03rem;
    font-weight: 600;
    line-height: 1.55;
}

.hero-trust-line {
    max-width: 720px;
    margin: 12px auto 0;
    color: #667085;
    font-size: 0.92rem;
    font-weight: 700;
    line-height: 1.5;
}

.upload-workspace {
    width: min(100%, 820px);
    max-width: none;
}

.homepage-info-sections {
    display: grid;
    width: min(100%, 920px);
    gap: 18px;
    margin-top: 10px;
}

.homepage-info-sections[hidden],
.landing-trust-notes[hidden] {
    display: none !important;
}

.app-shell-section.is-marketing-hidden .homepage-info-sections,
.app-shell-section.is-marketing-hidden .landing-trust-notes,
.app-shell-section.has-report .homepage-info-sections,
.app-shell-section.has-report .landing-trust-notes {
    display: none !important;
}

.homepage-info-panel {
    scroll-margin-top: 84px;
    border: 1px solid #d8e2ef;
    border-radius: 12px;
    background: #ffffff;
    padding: 24px;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.045);
}

.homepage-info-kicker {
    margin: 0 0 8px;
    color: var(--blue);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
}

.homepage-info-panel h2 {
    margin: 0 0 16px;
    color: #111827;
    font-size: 1.28rem;
    line-height: 1.28;
}

.homepage-steps {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
}

.homepage-steps article {
    border: 1px solid #e5edf7;
    border-radius: 10px;
    background: #f8fbff;
    padding: 16px;
}

.homepage-steps strong {
    display: block;
    margin-bottom: 6px;
    color: #172033;
    font-size: 0.95rem;
}

.homepage-steps p,
.homepage-info-copy {
    margin: 0;
    color: #667085;
    font-size: 0.92rem;
    line-height: 1.55;
}

.sample-report-list {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.sample-report-list a,
.sample-report-list span {
    border: 1px solid #d8e2ef;
    border-radius: 999px;
    background: #f8fbff;
    color: #475467;
    font-size: 0.88rem;
    font-weight: 800;
    padding: 8px 12px;
    text-decoration: none;
    transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.sample-report-list a:hover,
.sample-report-list a:focus-visible {
    border-color: #bfccdc;
    background: #eff6ff;
    color: var(--blue-dark);
    transform: translateY(-1px);
}

.sample-report-page {
    width: min(100% - 48px, 1280px);
    margin: 0 auto;
    padding: 32px 0 48px;
}

.sample-report-return {
    margin-bottom: 18px;
}

.sample-report-return a {
    color: var(--blue);
    font-size: 0.9rem;
    font-weight: 800;
    text-decoration: none;
}

.sample-report-return a:hover,
.sample-report-return a:focus-visible {
    color: var(--blue-dark);
    text-decoration: underline;
}

.upload-card {
    display: grid;
    gap: 22px;
    width: min(100%, 820px);
    margin: 0 auto;
    border: 2px dashed #cfd8e6;
    border-radius: 14px;
    box-shadow: none;
    padding: 46px 78px 34px;
}

.drop-zone {
    min-height: 124px;
    border: 0;
    background: transparent;
    gap: 8px;
    padding: 0;
}

.drop-zone:hover,
.drop-zone.is-dragging,
.drop-zone:focus-visible {
    background: transparent;
    box-shadow: none;
}

.upload-icon {
    width: 52px;
    height: 52px;
    border: 3px solid #dbeafe;
    border-radius: 50%;
    background: #ffffff;
    color: var(--blue);
    font-size: 2rem;
}

.drop-title {
    color: #475467;
    font-size: 1rem;
    font-weight: 800;
}

.drop-help {
    color: #475467;
    font-size: 0.95rem;
    font-weight: 700;
}

.file-name {
    color: var(--muted);
    font-size: 0.86rem;
}

.primary-button {
    width: min(100%, 620px);
    min-height: 58px;
    margin: 0 auto;
    border-radius: 7px;
    font-size: 1rem;
    box-shadow: 0 14px 28px rgba(37, 99, 235, 0.2);
}

.primary-button:disabled {
    opacity: 0.74;
}

.supported-files {
    justify-content: center;
    gap: 8px;
}

.supported-files span {
    position: static;
    min-height: 30px;
    border-radius: 999px;
    padding: 0 10px;
    font-size: 0.78rem;
    font-weight: 800;
}

.supported-files span + span::before {
    content: none;
}

.landing-trust-notes {
    display: flex;
    justify-content: space-between;
    gap: 32px;
    width: min(100%, 900px);
    margin: 58px auto 0;
}

.landing-trust-notes p {
    display: inline-flex;
    align-items: center;
    gap: 14px;
    margin: 0;
    color: #475467;
    font-size: 0.86rem;
    font-weight: 800;
}

.landing-trust-notes span {
    display: inline-grid;
    width: 18px;
    height: 18px;
    place-items: center;
    color: #344054;
    font-size: 1rem;
}

.site-footer {
    border-top: 0;
    background: #f8fafc;
}

.footer-inner {
    width: min(100% - 48px, 1180px);
    min-height: 44px;
    justify-content: center;
    text-align: center;
}

@media (max-width: 760px) {
    .header-inner,
    .app-shell,
    .footer-inner {
        width: min(100% - 28px, 1180px);
    }

    .site-nav {
        display: none;
    }

    .header-action {
        margin-left: 16px;
    }

    .app-shell-section {
        padding-top: 30px;
    }

    .workspace-header h1 {
        font-size: 2.3rem;
    }

    .upload-card {
        padding: 34px 22px 28px;
    }

    .landing-trust-notes {
        align-items: flex-start;
        flex-direction: column;
        gap: 18px;
        margin-top: 34px;
    }
}

@media (max-width: 460px) {
    .header-action {
        min-height: 36px;
        padding: 0 14px;
    }

    .workspace-header h1 {
        font-size: 2rem;
    }

    .hero-subheadline {
        font-size: 0.96rem;
    }

    .supported-files span {
        padding: 0 10px;
        font-size: 0.74rem;
    }
}

/* Official loading / analysis screen */
.app-shell-section.is-analyzing {
    min-height: calc(100vh - 106px);
    display: grid;
    align-items: center;
    padding: 48px 0 64px;
}

.app-shell-section.is-analyzing .workspace-header,
.app-shell-section.is-analyzing .upload-workspace,
.app-shell-section.is-analyzing .homepage-info-sections,
.app-shell-section.is-analyzing .landing-trust-notes,
.app-shell-section.is-analyzing .app-sidebar {
    display: none !important;
}

.app-shell-section.is-analyzing .app-main {
    justify-items: center;
}

.app-shell-section.is-analyzing .progress-container {
    display: grid;
    width: min(100%, 520px);
    justify-items: center;
}

.app-shell-section.is-analyzing .progress-container[hidden] {
    display: none;
}

.progress-panel {
    display: grid;
    justify-items: center;
    width: min(100%, 500px);
    border: 1px solid #dce4f2;
    border-radius: 14px;
    background: #ffffff;
    box-shadow: 0 28px 70px rgba(15, 23, 42, 0.12);
    padding: 46px 32px 38px;
    text-align: center;
}

.analysis-icon-wrap {
    position: relative;
    display: grid;
    width: 122px;
    height: 122px;
    place-items: center;
    margin-bottom: 22px;
}

.analysis-orbit {
    position: absolute;
    inset: 10px;
    border: 10px solid #dbeafe;
    border-top-color: var(--blue);
    border-radius: 50%;
    animation: spin 1300ms linear infinite;
}

.analysis-orbit-dot {
    position: absolute;
    top: -13px;
    left: 50%;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: #1e3a8a;
    transform: translateX(-50%);
}

.analysis-logo-icon {
    position: relative;
    display: block;
    width: 64px;
    height: 64px;
}

.progress-panel h2 {
    margin: 0 0 10px;
    color: #0f172a;
    font-size: 1.54rem;
    line-height: 1.2;
}

.friendly-wait-message {
    margin: 0;
    color: #475467;
    font-size: 0.98rem;
    font-weight: 700;
}

.analysis-progress {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 44px;
    gap: 18px;
    align-items: center;
    width: 100%;
    margin-top: 30px;
}

.analysis-progress-track {
    height: 13px;
    overflow: hidden;
    border-radius: 999px;
    background: #eef2f7;
}

.analysis-progress-track span {
    display: block;
    width: 0;
    height: 100%;
    border-radius: inherit;
    background: var(--blue);
    transition: width 500ms ease;
}

.analysis-progress strong {
    color: #111827;
    font-size: 1rem;
    font-weight: 800;
    text-align: right;
}

.large-document-message,
.slow-response-message {
    display: grid;
    grid-template-columns: 28px minmax(0, 1fr);
    gap: 14px;
    width: 100%;
    margin: 34px 0 0;
    border: 1px solid #dbeafe;
    border-radius: 8px;
    background: #eff6ff;
    color: #1f2937;
    padding: 18px 20px;
    text-align: left;
}

.large-document-message[hidden],
.slow-response-message[hidden] {
    display: none;
}

.large-document-message span {
    display: grid;
    width: 28px;
    height: 28px;
    place-items: center;
    color: var(--blue);
    font-size: 1.32rem;
    font-weight: 900;
}

.large-document-message p,
.slow-response-message {
    color: #1f2937;
    font-size: 0.9rem;
    font-weight: 700;
    line-height: 1.55;
}

.large-document-message p {
    margin: 0;
}

.progress-panel.is-complete .analysis-progress-track span {
    background: var(--green);
}

.progress-panel.is-error {
    border-color: #fecaca;
    background: #fffafa;
}

.progress-panel.is-error .analysis-progress-track span {
    background: var(--red);
}

.progress-panel.is-error h2 {
    color: var(--red);
}

@media (max-width: 560px) {
    .app-shell-section.is-analyzing {
        min-height: calc(100vh - 110px);
        padding: 32px 0 48px;
    }

    .progress-panel {
        padding: 34px 22px 28px;
    }

    .analysis-icon-wrap {
        width: 104px;
        height: 104px;
        margin-bottom: 18px;
    }

    .analysis-logo-icon {
        width: 58px;
        height: 58px;
    }

    .progress-panel h2 {
        font-size: 1.3rem;
    }

    .analysis-progress {
        grid-template-columns: 1fr 40px;
        gap: 12px;
    }

    .large-document-message,
    .slow-response-message {
        margin-top: 26px;
        padding: 16px;
    }
}

/* Loading screen polish */
.app-shell-section.is-analyzing .progress-container {
    width: min(100%, 640px);
}

.progress-panel {
    width: min(100%, 620px);
    padding: 48px 44px 40px;
}

.analysis-icon-wrap {
    animation: analysisFloat 3200ms ease-in-out infinite;
}

.analysis-logo-icon {
    animation: analysisPulse 2400ms ease-in-out infinite;
}

@keyframes analysisFloat {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-5px);
    }
}

@keyframes analysisPulse {
    0%,
    100% {
        opacity: 1;
        transform: scale(1);
    }
    50% {
        opacity: 0.88;
        transform: scale(1.03);
    }
}

.analysis-document-details {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
    width: 100%;
    margin: 12px 0 8px;
    border: 1px solid #dbe3ef;
    border-radius: 8px;
    background: #f8fafc;
    padding: 12px 14px;
    text-align: left;
}

.analysis-document-details[hidden] {
    display: none;
}

.analysis-file-icon {
    display: grid;
    width: 38px;
    height: 42px;
    place-items: center;
    border-radius: 7px;
    background: #e8f0ff;
    color: var(--blue);
    font-size: 0.68rem;
    font-weight: 900;
}

.analysis-document-details strong {
    display: block;
    color: #111827;
    font-size: 0.92rem;
    font-weight: 900;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.analysis-document-details p {
    margin: 3px 0 0;
    color: #667085;
    font-size: 0.82rem;
    font-weight: 700;
}

.large-document-message,
.slow-response-message {
    grid-template-columns: 32px minmax(0, 1fr);
    align-items: start;
    width: 100%;
    margin-top: 28px;
}

.slow-response-message {
    opacity: 0;
    transform: translateY(8px);
    transition: opacity 220ms ease, transform 220ms ease;
}

.slow-response-message.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.slow-response-message span,
.large-document-message span {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border-radius: 8px;
    background: #dbeafe;
    color: var(--blue);
    font-size: 0.95rem;
    font-weight: 900;
}

.slow-response-message strong {
    display: block;
    margin-bottom: 4px;
    color: #111827;
    font-size: 0.94rem;
    font-weight: 900;
    line-height: 1.35;
}

.slow-response-message p {
    margin: 0;
    color: #344054;
    font-size: 0.88rem;
    font-weight: 700;
    line-height: 1.5;
}

@media (prefers-reduced-motion: reduce) {
    .analysis-icon-wrap,
    .analysis-logo-icon {
        animation: none;
    }

    .slow-response-message {
        transition: none;
    }
}

@media (max-width: 560px) {
    .progress-panel {
        width: 100%;
        padding: 34px 22px 28px;
    }

    .analysis-document-details {
        grid-template-columns: 38px minmax(0, 1fr);
    }
}

/* Official report screen */
html {
    scroll-behavior: smooth;
}

.report-page .site-header,
.report-page .site-footer {
    display: none;
}

.app-shell-section.has-report {
    padding: 0;
}

.app-shell-section.has-report .app-shell {
    width: 100%;
}

.app-shell-section.has-report .app-main {
    display: block;
}

.app-shell-section.has-report .results-section {
    width: 100%;
    padding: 0;
}

.report-screen {
    display: grid;
    grid-template-columns: 292px minmax(0, 1fr);
    min-height: 100vh;
    background: #f7f9fc;
}

.report-sidebar {
    position: sticky;
    top: 0;
    align-self: start;
    min-height: 100vh;
    border-right: 1px solid #dbe3ef;
    background: #f8fafc;
    padding: 16px;
}

.sidebar-document-card,
.quick-tips {
    border: 1px solid #dbe3ef;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.sidebar-document-card {
    display: grid;
    gap: 14px;
    padding: 16px;
}

.sidebar-file-row {
    display: grid;
    grid-template-columns: 40px minmax(0, 1fr);
    gap: 12px;
    align-items: center;
}

.file-type-icon {
    display: grid;
    width: 36px;
    height: 42px;
    place-items: center;
    border-radius: 6px;
    background: var(--red);
    color: #ffffff;
    font-size: 0.64rem;
    font-weight: 900;
}

.sidebar-document-card h2 {
    margin: 0 0 4px;
    color: #111827;
    font-size: 0.88rem;
    line-height: 1.25;
    overflow-wrap: anywhere;
}

.sidebar-document-card p {
    margin: 0;
    color: #475467;
    font-size: 0.76rem;
    font-weight: 700;
}

.sidebar-file-size {
    color: #667085;
}

.sidebar-status {
    justify-self: start;
    min-height: 30px;
    border: 0;
    border-radius: 6px;
    background: #dcfce7;
    color: #166534;
    padding: 0 12px;
    font-size: 0.76rem;
    font-weight: 800;
}

.sidebar-analyze-button {
    width: 100%;
    min-height: 42px;
    margin: 0;
    font-size: 0.8rem;
    box-shadow: none;
}

.quick-navigation {
    display: grid;
    gap: 4px;
    margin-top: 24px;
}

.quick-navigation h2,
.quick-tips h2 {
    margin: 0 0 10px;
    color: #344054;
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
}

.quick-navigation a {
    display: grid;
    grid-template-columns: 24px minmax(0, 1fr);
    gap: 10px;
    align-items: center;
    min-height: 44px;
    border-radius: 8px;
    color: #111827;
    font-size: 0.84rem;
    font-weight: 800;
    line-height: 1.25;
    padding: 8px 10px;
    text-decoration: none;
}

.quick-navigation a span {
    display: grid;
    width: 22px;
    height: 22px;
    place-items: center;
    border: 1px solid #cdd7e5;
    border-radius: 6px;
    color: var(--blue);
    font-size: 0.62rem;
    font-weight: 900;
}

.quick-navigation a:hover,
.quick-navigation a:focus-visible,
.quick-navigation a.is-active {
    background: #eaf1ff;
    color: var(--blue-dark);
    outline: none;
}

.quick-navigation a:focus-visible,
.report-toolbar button:focus-visible,
.sidebar-analyze-button:focus-visible {
    box-shadow: 0 0 0 3px var(--focus);
}

.quick-tips {
    margin-top: 28px;
    padding: 16px;
}

.quick-tips ul {
    display: grid;
    gap: 10px;
    margin: 0;
    padding-left: 18px;
    color: #344054;
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.45;
}

.report-workspace {
    min-width: 0;
    padding: 0 20px 28px;
}

.report-toolbar {
    position: sticky;
    top: 0;
    z-index: 10;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    border: 0;
    border-radius: 0;
    background: rgba(247, 249, 252, 0.94);
    box-shadow: none;
    padding: 0 0 14px;
    backdrop-filter: blur(10px);
}

.report-toolbar .secondary-button,
.report-toolbar .primary-button {
    width: auto;
    min-height: 42px;
    margin: 0;
    border-radius: 7px;
    font-size: 0.82rem;
    box-shadow: none;
}

.report-toolbar .secondary-button {
    border-color: #d4deeb;
    color: #111827;
}

.report-toolbar .secondary-button span {
    color: var(--blue);
    font-weight: 900;
}

.toolbar-primary {
    padding: 0 18px;
}

.copy-feedback {
    align-self: center;
    color: var(--green);
    font-size: 0.84rem;
    font-weight: 800;
}

.report-intro {
    padding: 18px 0 22px;
}

.report-intro h1 {
    margin: 0 0 8px;
    color: #111827;
    font-size: clamp(2rem, 3.4vw, 2.75rem);
    line-height: 1.05;
}

.report-intro p {
    margin: 0;
    color: #475467;
    font-size: 0.9rem;
    font-weight: 700;
}

.overview-dashboard {
    margin-bottom: 26px;
}

.overview-grid {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 10px;
}

.overview-card {
    display: grid;
    grid-template-columns: 34px minmax(0, 1fr);
    gap: 10px;
    min-height: 92px;
    align-items: center;
    border: 1px solid #dbe3ef;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 10px 26px rgba(15, 23, 42, 0.055);
    padding: 12px;
}

.overview-icon {
    display: grid;
    width: 30px;
    height: 30px;
    place-items: center;
    border-radius: 7px;
    font-size: 0.68rem;
    font-weight: 900;
}

.overview-card p {
    margin: 0 0 4px;
    color: #475467;
    font-size: 0.68rem;
    font-weight: 800;
    line-height: 1.15;
}

.overview-card strong {
    color: #111827;
    font-size: 0.82rem;
    font-weight: 900;
    line-height: 1.15;
}

.tone-blue .overview-icon,
.tone-blue .report-card-icon {
    background: #e8f0ff;
    color: var(--blue);
}

.tone-green .overview-icon,
.tone-green .report-card-icon {
    background: #dcfce7;
    color: var(--green);
}

.tone-amber .overview-icon,
.tone-amber .report-card-icon {
    background: #fff7ed;
    color: var(--amber);
}

.tone-orange .overview-icon,
.tone-orange .report-card-icon {
    background: #fff7ed;
    color: #ea580c;
}

.tone-red .overview-icon,
.tone-red .report-card-icon {
    background: #fee2e2;
    color: var(--red);
}

.tone-purple .report-card-icon {
    background: #f3e8ff;
    color: #6d28d9;
}

.report-card-list {
    display: grid;
    gap: 16px;
}

.premium-report-card {
    position: relative;
    display: grid;
    gap: 16px;
    border: 1px solid #dbe3ef;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 14px 32px rgba(15, 23, 42, 0.06);
    padding: 22px 58px 22px 24px;
    scroll-margin-top: 86px;
}

.premium-report-card.tone-blue {
    background: #f8fbff;
    border-color: #d6e4ff;
}

.premium-report-card.tone-amber {
    background: #fffaf3;
    border-color: #fde7c7;
}

.premium-report-card.tone-red {
    background: #fff5f5;
    border-color: #ffd6d6;
}

.premium-report-card.tone-purple {
    background: #fbf7ff;
    border-color: #eadcff;
}

.premium-report-card.tone-green {
    background: #f4fbf6;
    border-color: #d6f2df;
}

.report-card-heading {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr);
    gap: 14px;
    align-items: start;
}

.report-card-icon {
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border-radius: 8px;
    font-size: 0.86rem;
    font-weight: 900;
}

.report-card-heading h2 {
    margin: 0 0 5px;
    color: #111827;
    font-size: 1.02rem;
    line-height: 1.25;
}

.report-card-heading p {
    margin: 0;
    color: #475467;
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1.45;
}

.premium-report-card .report-content {
    padding-left: 56px;
    color: #263244;
    font-size: 0.95rem;
    line-height: 1.65;
}

.premium-report-card .report-content p {
    color: #263244;
}

.card-chevron {
    position: absolute;
    top: 28px;
    right: 24px;
    color: #111827;
    font-size: 1.2rem;
    font-weight: 800;
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

@media (max-width: 1100px) {
    .overview-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 860px) {
    .report-screen {
        grid-template-columns: 1fr;
    }

    .report-sidebar {
        position: static;
        min-height: auto;
        border-right: 0;
        border-bottom: 1px solid #dbe3ef;
    }

    .quick-navigation {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .quick-navigation h2 {
        grid-column: 1 / -1;
    }

    .quick-tips {
        display: none;
    }

    .report-toolbar {
        position: static;
        flex-wrap: wrap;
        justify-content: stretch;
        padding-top: 16px;
    }

    .report-toolbar .secondary-button,
    .report-toolbar .primary-button {
        flex: 1 1 180px;
    }
}

@media (max-width: 620px) {
    .report-workspace {
        padding: 0 12px 24px;
    }

    .overview-grid {
        grid-template-columns: 1fr;
    }

    .quick-navigation {
        grid-template-columns: 1fr;
    }

    .premium-report-card {
        padding: 20px;
    }

    .premium-report-card .report-content {
        padding-left: 0;
    }

    .card-chevron {
        display: none;
    }
}

/* Report screen icon and card polish */
.ui-icon {
    display: block;
    width: 1em;
    height: 1em;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

.file-type-icon {
    width: 40px;
    height: 46px;
    border-radius: 8px;
    font-size: 1.18rem;
}

.file-type-icon .ui-icon {
    width: 21px;
    height: 21px;
}

.quick-navigation a {
    grid-template-columns: 26px minmax(0, 1fr);
    gap: 12px;
    min-height: 46px;
    padding: 9px 11px;
}

.quick-navigation a span {
    width: 24px;
    height: 24px;
    font-size: 0.94rem;
}

.report-toolbar {
    align-items: center;
    gap: 10px;
    min-height: 56px;
    padding: 0 0 16px;
}

.report-toolbar .secondary-button,
.report-toolbar .primary-button {
    display: inline-flex;
    min-height: 44px;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border-radius: 8px;
    padding: 0 16px;
    font-size: 0.86rem;
    font-weight: 850;
}

.report-toolbar .secondary-button {
    background: #ffffff;
    box-shadow: 0 8px 18px rgba(15, 23, 42, 0.045);
}

.report-toolbar .secondary-button:hover {
    border-color: #b8c6da;
    background: #f8fbff;
}

.report-toolbar .secondary-button span {
    display: inline-grid;
    width: 18px;
    height: 18px;
    place-items: center;
    color: #111827;
}

.report-toolbar .secondary-button .ui-icon {
    width: 17px;
    height: 17px;
}

.toolbar-primary {
    min-width: 220px;
    padding: 0 20px;
}

.overview-grid {
    gap: 12px;
}

.overview-card {
    grid-template-columns: 38px minmax(0, 1fr);
    gap: 12px;
    min-height: 104px;
    padding: 16px 14px;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.06);
}

.overview-icon {
    width: 36px;
    height: 36px;
    border-radius: 9px;
    font-size: 1.1rem;
}

.overview-icon .ui-icon {
    width: 21px;
    height: 21px;
}

.overview-card p {
    margin-bottom: 6px;
    font-size: 0.7rem;
    line-height: 1.2;
}

.overview-card strong {
    font-size: 0.96rem;
    line-height: 1.18;
}

.report-card-list {
    gap: 18px;
}

.premium-report-card {
    gap: 18px;
    border-color: #d8e2ef;
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.055);
    padding: 24px 62px 24px 26px;
}

.premium-report-card:hover {
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.08);
}

.report-card-heading {
    grid-template-columns: 46px minmax(0, 1fr);
    gap: 16px;
}

.report-card-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    font-size: 1.1rem;
}

.report-card-icon .ui-icon {
    width: 22px;
    height: 22px;
}

.report-card-heading h2 {
    margin-bottom: 6px;
    font-size: 1.08rem;
    font-weight: 900;
}

.report-card-heading p {
    max-width: 780px;
    font-size: 0.87rem;
}

.premium-report-card .report-content {
    padding-left: 62px;
    font-size: 0.98rem;
    line-height: 1.72;
}

.premium-report-card .report-content ul,
.premium-report-card .report-content ol {
    gap: 9px;
    padding-left: 20px;
}

.premium-report-card .report-content li {
    padding-left: 4px;
}

.premium-report-card .report-content li::marker {
    color: currentColor;
    font-weight: 800;
}

.card-chevron {
    top: 31px;
    right: 26px;
    color: #101828;
    font-size: 1.05rem;
}

@media (max-width: 860px) {
    .report-toolbar {
        gap: 10px;
    }

    .toolbar-primary {
        min-width: 0;
    }
}

@media (max-width: 620px) {
    .premium-report-card {
        padding: 22px;
    }

    .premium-report-card .report-content {
        padding-left: 0;
    }
}

/* Version 1.0 final report polish */
.report-screen {
    background: #f6f8fb;
}

.report-sidebar {
    padding: 20px 18px;
    background: #f7f9fc;
}

.sidebar-document-card,
.quick-tips {
    border-color: #d8e2ef;
    border-radius: 10px;
    box-shadow: 0 16px 36px rgba(15, 23, 42, 0.07);
}

.sidebar-document-card {
    gap: 16px;
    padding: 18px;
}

.sidebar-file-row {
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 14px;
}

.sidebar-document-card h2 {
    font-size: 0.92rem;
    font-weight: 900;
}

.sidebar-document-card p,
.sidebar-file-size {
    font-size: 0.79rem;
    line-height: 1.45;
}

.sidebar-status {
    border-radius: 7px;
    padding: 0 13px;
}

.sidebar-analyze-button {
    min-height: 46px;
    border-radius: 8px;
    transition: background 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.sidebar-analyze-button:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 24px rgba(37, 99, 235, 0.18);
}

.quick-navigation {
    gap: 7px;
    margin-top: 28px;
}

.quick-navigation h2,
.quick-tips h2 {
    margin-bottom: 12px;
    font-size: 0.74rem;
}

.quick-navigation a {
    min-height: 48px;
    border: 1px solid transparent;
    border-radius: 10px;
    color: #263244;
    transition: background 160ms ease, border-color 160ms ease, color 160ms ease, transform 160ms ease;
}

.quick-navigation a:hover,
.quick-navigation a:focus-visible {
    border-color: #d6e4ff;
    transform: translateX(2px);
}

.quick-navigation a.is-active {
    border-color: #d6e4ff;
    background: #eaf1ff;
    box-shadow: inset 3px 0 0 var(--blue);
}

.quick-tips {
    margin-top: 32px;
    padding: 18px;
}

.quick-tips ul {
    gap: 12px;
    font-size: 0.82rem;
}

.report-workspace {
    padding: 0 28px 40px;
}

.report-toolbar {
    min-height: 68px;
    gap: 12px;
    padding: 10px 0 18px;
}

.report-toolbar .secondary-button,
.report-toolbar .primary-button {
    min-height: 46px;
    border-radius: 9px;
    padding: 0 18px;
    transition: background 160ms ease, border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.report-toolbar .secondary-button:hover,
.report-toolbar .primary-button:hover {
    transform: translateY(-1px);
}

.report-toolbar .secondary-button:hover {
    box-shadow: 0 12px 24px rgba(15, 23, 42, 0.08);
}

.report-intro {
    padding: 26px 0 30px;
}

.report-intro h1 {
    margin-bottom: 10px;
    font-size: clamp(2.45rem, 4.4vw, 3.55rem);
    font-weight: 900;
    letter-spacing: 0;
}

.report-intro p {
    font-size: 0.98rem;
    color: #536174;
}

.overview-dashboard {
    margin-bottom: 38px;
}

.overview-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 16px;
}

.health-summary-card {
    display: grid;
    grid-column: span 2;
    gap: 18px;
    min-height: 168px;
    border: 1px solid #cfe0ff;
    border-radius: 12px;
    background: #ffffff;
    box-shadow: 0 22px 48px rgba(37, 99, 235, 0.11);
    padding: 22px;
}

.health-summary-heading {
    display: grid;
    grid-template-columns: 48px minmax(0, 1fr);
    gap: 14px;
    align-items: center;
}

.health-summary-card .overview-icon {
    width: 46px;
    height: 46px;
    border-radius: 12px;
}

.health-summary-card p,
.health-recommendation p {
    margin: 0 0 6px;
    color: #536174;
    font-size: 0.76rem;
    font-weight: 900;
    text-transform: uppercase;
}

.health-summary-heading strong {
    color: #0f172a;
    font-size: 2.05rem;
    font-weight: 900;
    line-height: 1;
}

.health-recommendation strong {
    color: #172033;
    font-size: 1.02rem;
    font-weight: 850;
    line-height: 1.45;
}

.overview-card {
    min-height: 132px;
    grid-template-columns: 44px minmax(0, 1fr);
    gap: 14px;
    align-content: center;
    border-radius: 12px;
    padding: 20px 18px;
    box-shadow: 0 18px 40px rgba(15, 23, 42, 0.075);
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

.overview-card:hover {
    border-color: #c9d8ea;
    transform: translateY(-2px);
    box-shadow: 0 24px 52px rgba(15, 23, 42, 0.095);
}

.overview-icon {
    width: 42px;
    height: 42px;
    border-radius: 11px;
}

.overview-icon .ui-icon {
    width: 24px;
    height: 24px;
}

.overview-card p {
    margin-bottom: 8px;
    font-size: 0.72rem;
    text-transform: uppercase;
}

.overview-card strong {
    font-size: 1.12rem;
    line-height: 1.22;
}

.report-card-list {
    gap: 24px;
}

.premium-report-card {
    gap: 22px;
    border-radius: 12px;
    padding: 30px 70px 30px 32px;
    box-shadow: 0 18px 42px rgba(15, 23, 42, 0.065);
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.premium-report-card:hover {
    border-color: #cbd9ea;
    transform: translateY(-2px);
    box-shadow: 0 26px 58px rgba(15, 23, 42, 0.09);
}

.report-card-heading {
    grid-template-columns: 54px minmax(0, 1fr);
    gap: 18px;
}

.report-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 12px;
}

.report-card-icon .ui-icon {
    width: 26px;
    height: 26px;
}

.report-card-heading h2 {
    margin-bottom: 8px;
    font-size: 1.2rem;
}

.report-card-heading p {
    font-size: 0.92rem;
    line-height: 1.55;
}

.premium-report-card .report-content {
    padding-left: 72px;
    font-size: 1.02rem;
    line-height: 1.82;
}

.premium-report-card .report-content p {
    margin-bottom: 18px;
}

.premium-report-card .report-content ul,
.premium-report-card .report-content ol {
    gap: 12px;
    margin-bottom: 18px;
    padding-left: 24px;
}

.premium-report-card .report-content li {
    padding-left: 6px;
}

.premium-report-card.is-collapsed .report-content {
    display: block;
    max-height: 0;
    overflow: hidden;
    opacity: 0;
    transition: max-height 180ms ease, opacity 160ms ease;
}

.premium-report-card:not(.is-collapsed) .report-content {
    max-height: 2000px;
    opacity: 1;
    transition: max-height 220ms ease, opacity 180ms ease;
}

.card-chevron {
    top: 36px;
    right: 30px;
}

@media (max-width: 1180px) {
    .health-summary-card {
        grid-column: 1 / -1;
    }

    .overview-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

@media (max-width: 860px) {
    .report-workspace {
        padding: 0 18px 32px;
    }

    .report-toolbar {
        padding-top: 18px;
    }
}

@media (max-width: 620px) {
    .report-intro h1 {
        font-size: 2.2rem;
    }

    .overview-grid {
        grid-template-columns: 1fr;
    }

    .health-summary-card {
        min-height: auto;
    }

    .premium-report-card {
        padding: 24px;
    }

    .premium-report-card .report-content {
        padding-left: 0;
    }
}

/* Report reveal timing and entrance animation */
.app-shell-section.has-report .results-section.is-revealed {
    animation: none;
}

.results-section.is-preparing-report-entry .report-intro,
.results-section.is-preparing-report-entry .overview-dashboard {
    opacity: 0;
    transform: translateY(14px);
}

.results-section .report-intro,
.results-section .overview-dashboard {
    opacity: 1;
    transform: translateY(0);
    transition: opacity 280ms ease-out, transform 280ms ease-out;
}

@media (prefers-reduced-motion: reduce) {
    .results-section.is-preparing-report-entry .report-intro,
    .results-section.is-preparing-report-entry .overview-dashboard,
    .results-section .report-intro,
    .results-section .overview-dashboard {
        opacity: 1;
        transform: none;
        transition: none;
    }
}

/* Polished report action toolbar */
.report-toolbar {
    position: sticky;
    top: 0;
    z-index: 30;
    align-items: center;
    flex-wrap: nowrap;
    justify-content: flex-end;
    gap: 8px;
    min-height: 58px;
    margin: 0 0 24px;
    border: 1px solid transparent;
    border-radius: 12px;
    background: transparent;
    box-shadow: none;
    padding: 9px 0;
    -webkit-backdrop-filter: blur(14px);
    backdrop-filter: blur(14px);
    transition: background 180ms ease, border-color 180ms ease, box-shadow 180ms ease, padding 180ms ease, margin 180ms ease;
}

.report-toolbar.is-sticky-active {
    margin-bottom: 26px;
    border-color: rgba(216, 226, 239, 0.92);
    background: rgba(255, 255, 255, 0.97);
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.075);
    padding: 9px 10px;
}

.report-toolbar .secondary-button,
.report-toolbar .primary-button {
    display: inline-flex;
    flex: 0 0 auto;
    min-height: 40px;
    align-items: center;
    justify-content: center;
    gap: 7px;
    border-radius: 8px;
    padding: 0 14px;
    font-size: 0.84rem;
    font-weight: 700;
    line-height: 1;
    white-space: nowrap;
    transition: background 170ms ease, border-color 170ms ease, color 170ms ease, box-shadow 170ms ease, transform 170ms ease;
}

.report-toolbar .secondary-button {
    border: 1px solid #d8e2ef;
    background: #ffffff;
    color: #172033;
    box-shadow: 0 7px 16px rgba(15, 23, 42, 0.045);
}

.report-toolbar .secondary-button:hover {
    border-color: #bfccdc;
    background: #f8fbff;
    box-shadow: 0 10px 20px rgba(15, 23, 42, 0.065);
    transform: translateY(-1px);
}

.report-toolbar .secondary-button:disabled,
.report-toolbar .primary-button:disabled {
    cursor: wait;
    opacity: 0.68;
    transform: none;
}

.report-toolbar .primary-button:hover {
    background: var(--blue-dark);
    transform: translateY(-1px);
}

.report-toolbar .secondary-button:focus-visible,
.report-toolbar .primary-button:focus-visible {
    transform: none;
}

.report-toolbar .secondary-button span {
    display: inline-grid;
    width: 16px;
    height: 16px;
    flex: 0 0 16px;
    place-items: center;
    color: #172033;
}

.report-toolbar .secondary-button .ui-icon {
    width: 16px;
    height: 16px;
    stroke-width: 2;
}

.copy-feedback {
    flex: 1 1 100%;
    color: #047857;
    font-size: 0.82rem;
    font-weight: 700;
    text-align: right;
}

.copy-feedback.is-error {
    color: #b42318;
}

.toolbar-primary {
    min-width: 0;
    margin-left: 10px;
    padding: 0 16px;
    box-shadow: 0 10px 20px rgba(37, 99, 235, 0.16);
}

@media (max-width: 1020px) {
    .report-toolbar {
        flex-wrap: wrap;
        justify-content: flex-start;
    }

    .report-toolbar .secondary-button,
    .report-toolbar .primary-button {
        flex: 1 1 180px;
    }

    .toolbar-primary {
        margin-left: 4px;
    }
}

@media (max-width: 860px) {
    .report-toolbar {
        position: sticky;
        top: 0;
        margin-bottom: 20px;
    }

    .report-toolbar.is-sticky-active {
        padding: 9px;
    }
}

@media (max-width: 620px) {
    .report-toolbar {
        gap: 8px;
        margin-right: 0;
        margin-left: 0;
        border-radius: 10px;
        padding: 8px;
    }

    .report-toolbar .secondary-button,
    .report-toolbar .primary-button {
        flex: 1 1 140px;
        min-height: 44px;
        padding: 0 12px;
        font-size: 0.8rem;
    }

    .toolbar-primary {
        margin-left: 0;
        flex-basis: 100%;
    }
}

@media (max-width: 760px) {
    .homepage-steps {
        grid-template-columns: 1fr;
    }

    .homepage-info-panel {
        padding: 20px;
    }
}

@media (max-width: 560px) {
    .hero-trust-line {
        font-size: 0.86rem;
    }

    .homepage-info-sections {
        gap: 14px;
    }

    .sample-report-list a,
    .sample-report-list span {
        width: 100%;
        text-align: center;
    }

    .sample-report-page {
        width: min(100% - 24px, 1280px);
        padding: 24px 0 36px;
    }
}

/* Branded print/PDF output */
.pdf-branding {
    display: none;
}

@media print {
    @page {
        margin: 0.85in 0.62in 1.08in;
    }

    body,
    .report-screen {
        background: #ffffff !important;
    }

    .site-header,
    .site-footer,
    .workspace-header,
    .upload-workspace,
    .progress-container,
    .analysis-error-card,
    .landing-trust-notes {
        display: none !important;
    }

    .report-sidebar,
    .report-toolbar {
        display: none !important;
    }

    .report-screen {
        display: block;
    }

    .report-workspace {
        padding: 0 !important;
    }

    .pdf-branding {
        display: block;
    }

    .pdf-branding-header {
        display: grid;
        grid-template-columns: 190px minmax(0, 1fr);
        gap: 22px;
        align-items: center;
        margin-bottom: 26px;
        border-bottom: 1px solid #d8e2ef;
        padding-bottom: 16px;
    }

    .pdf-branding-header img {
        display: block;
        width: 180px;
        height: auto;
    }

    .pdf-branding-header h1 {
        margin: 0 0 4px;
        color: #111827;
        font-size: 20pt;
        line-height: 1.15;
    }

    .pdf-branding-header p {
        margin: 0;
        color: #475467;
        font-size: 9pt;
        font-weight: 700;
    }

    .pdf-branding-footer {
        position: fixed;
        right: 0;
        bottom: -0.74in;
        left: 0;
        border-top: 1px solid #d8e2ef;
        color: #475467;
        padding-top: 10px;
        font-size: 8pt;
        line-height: 1.35;
        text-align: center;
    }

    .pdf-branding-footer p {
        margin: 0 0 2px;
    }

    .pdf-branding-footer strong {
        color: #111827;
        font-weight: 800;
    }

    .pdf-page-number {
        margin-top: 6px !important;
        color: #667085;
    }

    .pdf-current-page::after {
        content: counter(page);
    }

    .pdf-total-pages::after {
        content: counter(pages);
    }

    .report-intro {
        display: none;
    }

    .overview-dashboard,
    .premium-report-card,
    .health-summary-card,
    .overview-card {
        break-inside: avoid;
        box-shadow: none !important;
    }
}
