:root {
    --paper: #fbfaf4;
    --surface: #ffffff;
    --ink: #203027;
    --muted: #66756b;
    --sage: #6f8f72;
    --moss: #315b43;
    --berry: #9c4f67;
    --sun: #d7a84e;
    --sky: #d9e8ed;
    --line: #dce3d6;
    --shadow: 0 18px 45px rgba(40, 58, 45, 0.14);
}

* {
    box-sizing: border-box;
}

body {
    min-height: 100vh;
    margin: 0;
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    color: var(--ink);
    background:
        radial-gradient(circle at 18% 8%, rgba(215, 168, 78, 0.2), transparent 24rem),
        radial-gradient(circle at 88% 16%, rgba(156, 79, 103, 0.11), transparent 22rem),
        linear-gradient(135deg, #f8f5eb 0%, #edf4ed 45%, #f7faf8 100%);
}

body::before {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    content: "";
    background-image:
        linear-gradient(rgba(49, 91, 67, 0.05) 1px, transparent 1px),
        linear-gradient(90deg, rgba(49, 91, 67, 0.04) 1px, transparent 1px);
    background-size: 46px 46px;
    mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.85), transparent);
}

.page-shell {
    width: min(1120px, calc(100% - 32px));
    margin: 0 auto;
    padding: 32px 0 48px;
}

.site-header {
    position: relative;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 24px;
    align-items: center;
    min-height: 220px;
    padding: clamp(28px, 5vw, 46px);
    overflow: hidden;
    background:
        linear-gradient(120deg, rgba(255, 255, 255, 0.93), rgba(241, 247, 239, 0.9)),
        linear-gradient(45deg, rgba(111, 143, 114, 0.2), rgba(156, 79, 103, 0.12));
    border: 1px solid rgba(111, 143, 114, 0.25);
    border-radius: 8px;
    box-shadow: var(--shadow);
}

.site-header::after {
    position: absolute;
    right: -80px;
    bottom: -90px;
    width: 360px;
    height: 220px;
    content: "";
    background: rgba(217, 232, 237, 0.72);
    border-radius: 48% 52% 0 0;
    transform: rotate(-8deg);
}

.site-header::before {
    position: absolute;
    inset: auto 26px 24px auto;
    width: 52%;
    height: 1px;
    content: "";
    background: linear-gradient(90deg, transparent, rgba(49, 91, 67, 0.26), transparent);
}

.eyebrow,
.section-label {
    margin: 0 0 10px;
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0;
    color: var(--berry);
    text-transform: uppercase;
}

h1,
h2 {
    margin: 0;
    letter-spacing: 0;
}

h1 {
    max-width: 760px;
    font-size: clamp(2.2rem, 5vw, 4.8rem);
    line-height: 0.98;
}

h2 {
    font-size: 1.35rem;
    line-height: 1.2;
}

.intro {
    max-width: 680px;
    margin: 18px 0 0;
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.7;
}

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

.trust-visual {
    position: relative;
    z-index: 1;
    display: grid;
    place-items: center;
    min-width: clamp(180px, 25vw, 280px);
}

.chain-mark {
    width: clamp(180px, 27vw, 310px);
    max-width: 100%;
    height: auto;
    transform: rotate(-3deg);
}

.leaf-mark {
    position: absolute;
    right: -6px;
    bottom: 2px;
    z-index: -1;
    width: clamp(86px, 13vw, 140px);
    height: auto;
    opacity: 0.76;
    filter: drop-shadow(0 14px 24px rgba(49, 91, 67, 0.12));
}

.trust-strip {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 1px;
    margin-top: 18px;
    overflow: hidden;
    background: rgba(111, 143, 114, 0.24);
    border: 1px solid rgba(111, 143, 114, 0.24);
    border-radius: 8px;
    box-shadow: 0 10px 28px rgba(40, 58, 45, 0.07);
}

.trust-strip > div {
    min-height: 88px;
    padding: 16px;
    background: rgba(255, 255, 255, 0.82);
}

.trust-strip strong {
    display: block;
    margin-top: 6px;
    line-height: 1.35;
}

.trust-kicker {
    color: var(--berry);
    font-size: 0.76rem;
    font-weight: 800;
    text-transform: uppercase;
}

.content-grid {
    display: grid;
    grid-template-columns: minmax(0, 620px);
    gap: 20px;
    margin-top: 20px;
    justify-content: center;
}

.panel,
.notice {
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid var(--line);
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(40, 58, 45, 0.08);
}

.panel {
    padding: 24px;
}

.upload-panel {
    position: relative;
    overflow: hidden;
}

.upload-panel::before {
    position: absolute;
    inset: 0 0 auto;
    height: 5px;
    content: "";
    background: linear-gradient(90deg, var(--moss), var(--sun), var(--berry));
}

.notice {
    margin-top: 18px;
    padding: 14px 16px;
    font-weight: 700;
}

.notice-success {
    color: #274f3c;
    background: #edf8ef;
    border-color: #b9d9c0;
}

.notice-error {
    color: #7b2937;
    background: #fff1f3;
    border-color: #efbbc4;
}

.panel-heading {
    margin-bottom: 18px;
}

.file-drop {
    display: grid;
    gap: 10px;
    min-height: 164px;
    padding: 22px;
    place-content: center;
    text-align: center;
    cursor: pointer;
    background:
        linear-gradient(145deg, rgba(247, 251, 246, 0.96), rgba(255, 250, 240, 0.98)),
        repeating-linear-gradient(135deg, rgba(49, 91, 67, 0.04) 0 8px, transparent 8px 16px);
    border: 2px dashed #a9bfa6;
    border-radius: 8px;
}

.file-drop:hover {
    border-color: var(--moss);
    background: linear-gradient(145deg, #ffffff, #fffaf0);
}

.file-drop input {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0 0 0 0);
    white-space: nowrap;
}

.file-title {
    font-weight: 800;
    color: var(--moss);
}

.file-name {
    color: var(--muted);
    overflow-wrap: anywhere;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 46px;
    width: 100%;
    margin-top: 18px;
    padding: 12px 16px;
    border: 0;
    border-radius: 8px;
    font: inherit;
    font-weight: 800;
    cursor: pointer;
    transition: transform 160ms ease, box-shadow 160ms ease, opacity 160ms ease;
}

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

.button:disabled {
    cursor: wait;
    opacity: 0.65;
    transform: none;
}

.button-primary {
    color: #fff;
    background: var(--moss);
    box-shadow: 0 12px 24px rgba(49, 91, 67, 0.2);
}

.button-secondary {
    color: #fff;
    background: var(--berry);
    box-shadow: 0 12px 24px rgba(156, 79, 103, 0.2);
}

.quiet-consent {
    margin: 12px 0 0;
    color: var(--muted);
    font-size: 0.88rem;
    line-height: 1.5;
    text-align: center;
}

.capture-utility {
    display: none;
}

.privacy-note {
    margin: -6px 0 18px;
    color: var(--muted);
    line-height: 1.55;
}

.camera-frame {
    position: relative;
    display: grid;
    min-height: 260px;
    overflow: hidden;
    place-items: center;
    background:
        linear-gradient(135deg, rgba(217, 232, 237, 0.7), rgba(248, 245, 235, 0.92)),
        repeating-linear-gradient(45deg, rgba(49, 91, 67, 0.05) 0 9px, transparent 9px 18px);
    border: 1px solid var(--line);
    border-radius: 8px;
}

.camera-frame video,
.camera-frame img,
.camera-placeholder {
    grid-area: 1 / 1;
}

.camera-frame video,
.camera-frame img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.camera-snapshot {
    display: block;
}

.camera-placeholder {
    color: var(--moss);
    font-weight: 800;
}

.status-list {
    display: grid;
    gap: 10px;
    margin: 18px 0 0;
    padding: 0;
    list-style: none;
}

.status-list li {
    padding: 10px 12px;
    color: var(--muted);
    background: #f7faf6;
    border: 1px solid #e5ecdf;
    border-radius: 8px;
    overflow-wrap: anywhere;
}

@media (max-width: 820px) {
    .page-shell {
        width: min(100% - 24px, 640px);
        padding-top: 18px;
    }

    .site-header,
    .content-grid {
        grid-template-columns: 1fr;
    }

    .site-header {
        min-height: 0;
        padding: 26px;
    }

    .leaf-mark {
        width: 100px;
    }

    .trust-visual {
        justify-self: end;
        min-width: 160px;
    }

    .chain-mark {
        width: 190px;
    }

    .trust-strip {
        grid-template-columns: 1fr;
    }

    h1 {
        font-size: 2.3rem;
        line-height: 1.04;
    }

    .panel {
        padding: 20px;
    }
}
