:root {
    font-family:
        Inter,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;

    color: #202124;
    background: #f4f6f8;
}

* {
    box-sizing: border-box;
}

html {
    overflow-y: scroll;
    scroll-behavior: smooth;
}

body {
    margin: 0;
}

button,
input,
select,
textarea {
    font: inherit;
}

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

.card {
    background: white;
    border: 1px solid #dfe3e8;
    border-radius: 12px;
    padding: 28px;
    margin-bottom: 20px;
}

h1 {
    margin-top: 0;
    margin-bottom: 2px;
}

h2 {
    margin-top: 0;
    font-weight: 500;
}

h3 {
    margin-top: 0;
}

.status {
    margin-top: 18px;
    color: #5f6368;
}

.label {
    font-weight: 600;
    margin-bottom: 8px;
}


/* Header ------------------------------------------------------------ */

.site-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 24px;

    margin-bottom: 20px;
}

.site-header h1 {
    margin: 0 0 2px;
}

.site-header .author-line {
    margin: 0;
}

.site-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;

    padding-top: 8px;
}

.site-nav a {
    color: #0969da;
    text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
    text-decoration: underline;
}

.author-line {
    margin: 0 0 18px;

    color: #6b7075;

    font-size: 0.92rem;
    font-weight: 500;
}


/* Verification ------------------------------------------------------ */

.verification-card {
    text-align: center;
}

#captcha-container > div {
    margin-left: auto;
    margin-right: auto;
}

.ticket-loader,
.report-loader {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 18px;

    margin: 28px auto 12px;
    padding: 20px;

    max-width: 440px;

    background: #f8f9fa;
    border-radius: 10px;

    text-align: left;
}

.ticket-loader p,
.report-loader p {
    margin: 5px 0 0;
    color: #5f6368;
}

.spinner {
    width: 34px;
    height: 34px;

    flex: 0 0 34px;

    border: 4px solid #dfe3e8;
    border-top-color: #1a73e8;
    border-radius: 50%;

    animation:
        ticket-spinner 0.8s linear infinite;
}

.report-spinner {
    width: 30px;
    height: 30px;

    flex-basis: 30px;
}

@keyframes ticket-spinner {
    to {
        transform: rotate(360deg);
    }
}


/* Ticket ------------------------------------------------------------ */

.ticket-header {
    text-align: center;
}

.success-mark {
    display: flex;
    align-items: center;
    justify-content: center;

    width: 44px;
    height: 44px;

    margin: 0 auto 12px;

    border-radius: 50%;

    background: #e6f4ea;
    color: #137333;

    font-size: 1.4rem;
    font-weight: 700;
}

.ticket-ready-text {
    color: #5f6368;
}

.ticket-row {
    display: flex;
    gap: 8px;

    width: min(420px, 100%);
    margin: 0 auto 12px;
}

.ticket-row input {
    flex: 1;
    min-width: 0;

    font-family: monospace;
    font-size: 1.2rem;
    text-align: center;

    padding: 12px;

    border: 1px solid #c7ccd1;
    border-radius: 6px;

    background: #f8f9fa;
}

.confirmation-note {
    width: min(560px, 100%);

    margin: 18px auto 0;
    padding: 12px 14px;

    border-radius: 7px;

    background: #f4f6f8;
    color: #5f6368;

    font-size: 0.92rem;
    line-height: 1.45;
}

.confirmation-success {
    background: #e6f4ea;
    color: #137333;

    border: 1px solid #b7dfbf;
}

.confirmation-warning {
    background: #fff7e0;
    color: #7a4f01;

    border: 1px solid #f0d58a;

    font-weight: 600;
}

.file-upload-box {
    margin-top: 28px;
    padding-top: 24px;

    border-top: 1px solid #e4e7eb;

    text-align: left;
}

.optional-label {
    font-size: 0.78rem;
    font-weight: 500;

    color: #6b7075;

    margin-left: 4px;
}


/* File help --------------------------------------------------------- */

.file-help {
    margin-top: 20px;

    border: 1px solid #dfe3e8;
    border-radius: 8px;

    background: #fafbfc;
}

.file-help > summary {
    padding: 14px 16px;

    cursor: pointer;
    font-weight: 600;
}

.file-help-content {
    padding: 2px 16px 18px;
}

.file-help-content h4 {
    margin-bottom: 6px;
}

.file-help-content p {
    margin-top: 6px;
}

.file-help code {
    display: block;

    overflow-x: auto;

    padding: 10px 12px;
    margin: 8px 0 16px;

    border-radius: 6px;

    background: #eef1f4;

    font-size: 0.88rem;
    white-space: nowrap;
}

.secondary-file-help {
    margin-top: 18px;
}

.secondary-file-help > summary {
    cursor: pointer;
    font-weight: 600;
}


/* Information ------------------------------------------------------- */

.info-box {
    padding: 16px 18px;
    margin: 20px 0 24px;

    border-left: 4px solid #1a73e8;
    border-radius: 6px;

    background: #f4f8ff;
}

.info-box p {
    margin: 7px 0 0;
}

.contact-button {
    margin-top: 4px;

    background: transparent;
    color: #1a73e8;

    padding: 0;

    border: 0;

    text-decoration: underline;
    cursor: pointer;
}

.contact-button:hover {
    filter: none;
    text-decoration: none;
}


/* Form -------------------------------------------------------------- */

.form-row {
    display: grid;

    grid-template-columns:
        minmax(0, 1fr)
        minmax(0, 1fr);

    gap: 18px;
}

.form-field {
    margin-bottom: 20px;
}

.form-field label {
    display: block;

    margin-bottom: 7px;

    font-weight: 600;
}

.form-field input,
.form-field select,
.form-field textarea {
    width: 100%;

    padding: 11px 12px;

    border: 1px solid #c7ccd1;
    border-radius: 6px;

    color: #202124;
    background: white;
}

.form-field textarea {
    resize: vertical;
    line-height: 1.45;
}

.form-field input:focus,
.form-field select:focus,
.form-field textarea:focus {
    outline: 2px solid #1a73e8;
    outline-offset: 1px;

    border-color: #1a73e8;
}

.form-field select:disabled,
.form-field input:disabled,
.form-field textarea:disabled {
    background: #f1f3f4;
    color: #80868b;
}

.field-help {
    margin: 6px 0 0;

    color: #6b7075;

    font-size: 0.9rem;
}


/* Buttons ----------------------------------------------------------- */

button,
.button {
    display: inline-block;

    padding: 12px 18px;

    border: 0;
    border-radius: 6px;

    cursor: pointer;

    text-decoration: none;
    font: inherit;
}

button {
    background: #e8eaed;
    color: #202124;
}

.button,
.primary-button {
    background: #1a73e8;
    color: white;
}

button:disabled,
.button:disabled {
    cursor: not-allowed;
    opacity: 0.55;
}

button:not(:disabled):hover,
.button:hover {
    filter: brightness(0.96);
}

.submit-area {
    margin-top: 12px;
    padding-top: 22px;

    border-top: 1px solid #e4e7eb;

    text-align: center;
}

.report-loader {
    margin-top: 0;
    margin-bottom: 0;
}


/* Footer ------------------------------------------------------------ */

.page-footer {
    padding: 12px 16px 32px;

    text-align: center;

    color: #6b7075;

    font-size: 0.9rem;
}

.page-footer p {
    margin: 0 0 7px;
}

.page-footer a {
    color: #1a73e8;
}


/* Generic ----------------------------------------------------------- */

[hidden] {
    display: none !important;
}


/* Mobile ------------------------------------------------------------ */

@media (max-width: 600px) {
    .page {
        width: min(100% - 20px, 1040px);
        margin: 20px auto;
    }

    .site-header {
        flex-direction: column;
    }

    .site-nav {
        padding-top: 0;
    }

    .card {
        padding: 20px;
    }

    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }

    .ticket-row {
        flex-direction: column;
    }

    .ticket-row button {
        width: 100%;
    }

    .ticket-loader,
    .report-loader {
        align-items: flex-start;
    }
}



/* Back to top ------------------------------------------------------- */

.back-to-top {
    position: fixed;
    right: 22px;
    bottom: 22px;
    z-index: 20;

    display: flex;
    align-items: center;
    justify-content: center;

    width: 42px;
    height: 42px;

    border: 1px solid #c7ccd1;
    border-radius: 50%;

    background: rgba(255, 255, 255, 0.94);
    color: #1a73e8;

    box-shadow:
        0 4px 14px
        rgba(32, 33, 36, 0.14);

    text-decoration: none;
    font-size: 1.35rem;
    font-weight: 700;
    line-height: 1;
}

.back-to-top:hover {
    background: #f4f8ff;
    border-color: #9db9df;
    text-decoration: none;
}

@media (max-width: 600px) {
    .back-to-top {
        right: 14px;
        bottom: 14px;

        width: 38px;
        height: 38px;
    }
}
