﻿:root {
    --cream: #F5F1E8;
    --navy: #1A2B3C;
    --rust: #C85A3F;
    --light-rust: #E88968;
    --border: #D4C9B5;
    --shadow: rgba(26, 43, 60, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Work Sans', sans-serif;
    background: var(--cream);
    color: var(--navy);
    line-height: 1.6;
    overflow-x: hidden;
}

/* Grain texture overlay */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0.03;
    z-index: -1;
    background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 400 400' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noiseFilter'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noiseFilter)'/%3E%3C/svg%3E");
}

header {
    padding: 3rem 2rem 1rem;
    text-align: center;
    border-bottom: 2px solid var(--border);
    position: relative;
}

header::after {
    content: '';
    position: absolute;
    bottom: -2px;
    left: 50%;
    transform: translateX(-50%);
    width: 100px;
    height: 2px;
    background: var(--rust);
}

h1 {
    font-family: 'Crimson Pro', serif;
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
    color: var(--navy);
}

.tagline {
    font-size: 1.125rem;
    color: var(--rust);
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem;
}

section {
    margin: 4rem 0;
    animation: fadeIn 0.8s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

h2 {
    font-family: 'Crimson Pro', serif;
    font-size: clamp(1.75rem, 5vw, 2.5rem);
    font-weight: 600;
    margin-bottom: 1.5rem;
    position: relative;
    display: inline-block;
}

h2::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 60%;
    height: 3px;
    background: var(--rust);
}

.hero {
    text-align: center;
    padding: 3rem 0;
}

.hero p {
    font-size: 1.25rem;
    max-width: 600px;
    margin: 0 auto;
    color: var(--navy);
    opacity: 0.85;
    font-style: italic;
}

.form-container {
    background: white;
    border: 3px solid var(--navy);
    padding: 3rem;
    max-width: 600px;
    margin: 3rem auto;
    box-shadow: 12px 12px 0 var(--rust);
    position: relative;
}

.form-container::before {
    content: '✦';
    position: absolute;
    top: -15px;
    left: -15px;
    font-size: 2rem;
    color: var(--rust);
}

.form-container::after {
    content: '✦';
    position: absolute;
    bottom: -15px;
    right: -15px;
    font-size: 2rem;
    color: var(--rust);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    font-weight: 600;
    margin-bottom: 0.5rem;
    font-size: 0.95rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--navy);
}

.helper-text {
    margin-top: 0.4rem;
    font-size: 0.85rem;
    color: rgba(26, 43, 60, 0.7);
}

input[type="text"],
input[type="date"] {
    width: 100%;
    padding: 0.875rem;
    border: 2px solid var(--border);
    background: var(--cream);
    font-family: 'Work Sans', sans-serif;
    font-size: 1rem;
    transition: all 0.3s ease;
}

input[type="text"]:focus,
input[type="date"]:focus {
    outline: none;
    border-color: var(--navy);
    box-shadow: 0 0 0 3px rgba(26, 43, 60, 0.1);
}

.form-container button[type="submit"] {
    width: 100%;
    padding: 1.125rem 2rem;
    background: var(--navy);
    color: var(--cream);
    border: none;
    font-family: 'Work Sans', sans-serif;
    font-size: 1.125rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.form-container button[type="submit"]::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: var(--rust);
    transition: left 0.3s ease;
}

.form-container button[type="submit"] span {
    position: relative;
    z-index: 1;
}

.form-container button[type="submit"]:hover::before {
    left: 0;
}

.form-container button[type="submit"]:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 20px var(--shadow);
}

.form-container button[type="submit"]:active {
    transform: translateY(0);
}

.info-section {
    background: white;
    border-left: 5px solid var(--rust);
    padding: 2rem;
    margin: 2rem 0;
    box-shadow: 0 4px 20px var(--shadow);
}

.info-section h3 {
    font-family: 'Crimson Pro', serif;
    font-size: 1.5rem;
    margin-bottom: 1rem;
    color: var(--navy);
}

.info-section p {
    margin-bottom: 1rem;
    line-height: 1.8;
}

.info-section ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.info-section li {
    margin-bottom: 0.5rem;
    line-height: 1.8;
}

.info-section code {
    background: var(--cream);
    padding: 0.25rem 0.5rem;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 0.9rem;
}

.info-section a {
    color: var(--rust);
    text-decoration: none;
    font-weight: 500;
    border-bottom: 2px solid transparent;
    transition: border-color 0.3s ease;
}

.info-section a:hover {
    border-bottom-color: var(--rust);
}

.cta-banner {
    background: var(--navy);
    color: var(--cream);
    padding: 2.5rem 2rem;
    text-align: center;
    margin: 4rem 0;
    position: relative;
    overflow: hidden;
}

.cta-banner::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, transparent 25%, rgba(200, 90, 63, 0.1) 25%, rgba(200, 90, 63, 0.1) 50%, transparent 50%, transparent 75%, rgba(200, 90, 63, 0.1) 75%);
    background-size: 40px 40px;
    opacity: 0.3;
}

.cta-banner h3 {
    font-family: 'Crimson Pro', serif;
    font-size: 1.75rem;
    margin-bottom: 1rem;
    position: relative;
}

.cta-banner p {
    font-size: 1.125rem;
    margin-bottom: 1.5rem;
    opacity: 0.9;
    position: relative;
}

.cta-banner a {
    display: inline-block;
    padding: 1rem 2.5rem;
    background: var(--rust);
    color: white;
    text-decoration: none;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.3s ease;
    position: relative;
}

.cta-banner a:hover {
    background: var(--light-rust);
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

footer {
    text-align: center;
    padding: 3rem 2rem;
    border-top: 2px solid var(--border);
    font-size: 0.9rem;
    color: var(--navy);
    opacity: 0.7;
}

.stamp {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 120px;
    height: 120px;
    border: 4px solid var(--rust);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Crimson Pro', serif;
    font-weight: 700;
    font-size: 0.75rem;
    text-transform: uppercase;
    color: var(--rust);
    transform: rotate(-15deg);
    opacity: 0.6;
    pointer-events: none;
    text-align: center;
    line-height: 1.2;
    padding: 1rem;
}

@media (max-width: 768px) {
    .form-container {
        padding: 2rem;
        box-shadow: 8px 8px 0 var(--rust);
    }

    .stamp {
        width: 80px;
        height: 80px;
        font-size: 0.6rem;
        bottom: 1rem;
        right: 1rem;
    }

    h1 {
        font-size: 2.5rem;
    }
}

.done-panel {
    display: none;
    background: var(--rust);
    color: white;
    padding: 1.5rem;
    text-align: center;
    margin-top: 1.5rem;
    font-weight: 600;
    animation: slideDown 0.5s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.done-panel.show {
    display: block;
}

.done-downloaded {
    font-size: 1.1rem;
    font-weight: 600;
    margin-bottom: 0.6rem;
}

.done-bevisid {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    margin-bottom: 0.8rem;
    font-weight: 400;
    font-size: 0.95rem;
    flex-wrap: wrap;
}

.bevisid-value {
    font-family: 'Courier New', monospace;
    background: rgba(255, 255, 255, 0.18);
    padding: 0.2rem 0.6rem;
    border-radius: 3px;
}

.done-actions {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    flex-wrap: wrap;
}

.copy-btn {
    padding: 0.45rem 0.9rem;
    font-size: 0.75rem;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 3px;
    cursor: pointer;
    font-family: 'Work Sans', sans-serif;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    transition: background 0.2s ease;
}

.copy-btn:hover {
    background: rgba(255, 255, 255, 0.35);
}

.reset-link {
    margin-top: 0.8rem;
    background: none;
    border: none;
    color: white;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
    cursor: pointer;
    font-family: 'Work Sans', sans-serif;
    letter-spacing: 0.03em;
}

.error-panel {
    display: none;
    background: #1a2b3c;
    color: white;
    padding: 1rem 1.25rem;
    text-align: center;
    margin-top: 0.9rem;
    font-weight: 600;
    border-left: 5px solid var(--rust);
}

.error-panel.show {
    display: block;
}

.ghost-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.6rem 1rem;
    margin-top: 0.8rem;
    background: var(--cream);
    color: var(--navy);
    border: 2px solid var(--border);
    font-family: 'Work Sans', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    cursor: pointer;
    transition: border-color 0.2s ease, transform 0.2s ease;
}

.ghost-btn:hover {
    border-color: var(--navy);
    transform: translateY(-1px);
}

.checklist-reset {
    width: 100%;
    margin-top: 1.5rem;
}

input.is-ok {
    border-color: #2e7d32;
    box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.15);
}

.form-container button[type="submit"]:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

button:focus-visible,
input:focus-visible,
a:focus-visible,
summary:focus-visible {
    outline: 3px solid rgba(26, 43, 60, 0.35);
    outline-offset: 3px;
}

/* Accordion */
details.accordion {
    margin: 2rem 0;
}

details.accordion > summary {
    display: flex;
    align-items: center;
    background: white;
    border-left: 5px solid var(--rust);
    padding: 1.25rem 2.5rem 1.25rem 2rem;
    box-shadow: 0 4px 20px var(--shadow);
    cursor: pointer;
    list-style: none;
    font-family: 'Crimson Pro', serif;
    font-size: 1.5rem;
    color: var(--navy);
    user-select: none;
    position: relative;
    transition: background 0.2s ease;
}

details.accordion > summary:hover {
    background: #f9f7f2;
}

details.accordion > summary::-webkit-details-marker {
    display: none;
}

details.accordion > summary::after {
    content: '▶';
    position: absolute;
    right: 1.5rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--rust);
    font-size: 0.7rem;
    transition: transform 0.2s ease;
}

details.accordion[open] > summary::after {
    transform: translateY(-50%) rotate(90deg);
}

details.accordion > .info-section {
    margin-top: 0;
}

/* Checklist */
.checklist-container {
    background: white;
    border-left: 5px solid var(--rust);
    padding: 2rem;
    box-shadow: 0 4px 20px var(--shadow);
}

.progress-wrap {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.progress-track {
    flex: 1;
    height: 8px;
    background: var(--cream);
    border-radius: 4px;
    overflow: hidden;
    border: 1px solid var(--border);
}

#progress-bar {
    height: 100%;
    width: 0%;
    background: var(--rust);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--navy);
    white-space: nowrap;
}

.checklist-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
}

.checklist-item:last-child {
    border-bottom: none;
}

.checklist-item span {
    font-size: 1rem;
    color: var(--navy);
    transition: all 0.2s ease;
}

.checklist-item.checked span {
    text-decoration: line-through;
    opacity: 0.4;
}

.checklist-checkbox {
    width: 20px;
    height: 20px;
    accent-color: var(--rust);
    cursor: pointer;
    flex-shrink: 0;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    section {
        animation: none;
    }

    .done-panel {
        animation: none;
    }
}

/* Foote Line */
.footer-line {
    margin-top: 1.0rem;
    font-size: 0.82rem;
    line-height: 1.4;
    color: #8a8a8a;
    letter-spacing: 0.01em;
    text-align: center;
}

.footer-line a {
    color: inherit;
    text-decoration: none;
}

.footer-line a:hover {
    color: #585858;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.footer-line .sep {
    margin: 0 0.35rem;
    opacity: 0.5;
}
.centered-title { text-align: center; margin-bottom: 2rem; }
