:root {
    --bg: #f4efe7;
    --bg-strong: #efe2d0;
    --surface: rgba(255, 252, 248, 0.86);
    --surface-strong: #fffaf3;
    --text: #1c1c1a;
    --muted: #5f5a52;
    --accent: #0a7c66;
    --accent-deep: #075a4b;
    --border: rgba(28, 28, 26, 0.12);
    --shadow: 0 24px 50px rgba(49, 39, 26, 0.12);
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: "Trebuchet MS", "Segoe UI", sans-serif;
    color: var(--text);
    background:
        radial-gradient(circle at top left, rgba(10, 124, 102, 0.16), transparent 32%),
        radial-gradient(circle at top right, rgba(186, 104, 41, 0.14), transparent 28%),
        linear-gradient(160deg, var(--bg) 0%, #f8f4ef 55%, var(--bg-strong) 100%);
}

a {
    color: inherit;
    text-decoration: none;
}

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

.compact-shell {
    min-height: 100vh;
}

.site-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 40px;
}

.brand {
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-wrap: wrap;
}

.inline-form {
    margin: 0;
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.9rem 1.2rem;
    border-radius: 999px;
    border: 1px solid transparent;
    background: var(--accent);
    color: #f8fbf9;
    font-weight: 700;
    transition: transform 0.18s ease, background 0.18s ease;
}

.button:hover {
    background: var(--accent-deep);
    transform: translateY(-1px);
}

.button-ghost {
    background: rgba(255, 250, 243, 0.72);
    color: var(--text);
    border-color: var(--border);
}

.hero {
    display: grid;
    grid-template-columns: 1.35fr 0.9fr;
    gap: 28px;
    align-items: stretch;
    margin-bottom: 30px;
}

.hero h1,
.panel h1 {
    margin: 0 0 16px;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.6rem, 5vw, 4.7rem);
    line-height: 0.98;
}

.hero h2,
.panel h2 {
    margin: 0 0 12px;
    font-family: Georgia, "Times New Roman", serif;
}

.lead {
    margin: 0;
    max-width: 62ch;
    color: var(--muted);
    font-size: 1.06rem;
    line-height: 1.7;
}

.eyebrow,
.card-kicker {
    margin: 0 0 10px;
    font-size: 0.84rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: var(--accent-deep);
}

.hero-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    margin-top: 28px;
}

.panel,
.hero-card {
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: 28px;
    background: var(--surface);
    box-shadow: var(--shadow);
    backdrop-filter: blur(10px);
}

.hero-card {
    position: relative;
    overflow: hidden;
}

.hero-card::after {
    content: "";
    position: absolute;
    inset: auto -20% -20% auto;
    width: 180px;
    height: 180px;
    border-radius: 50%;
    background: rgba(10, 124, 102, 0.1);
}

.feature-list,
.history-list {
    margin: 18px 0 0;
    padding-left: 20px;
    color: var(--muted);
    line-height: 1.7;
}

.info-grid,
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 20px;
}

.dashboard-grid {
    grid-template-columns: 1.45fr 0.75fr;
    align-items: start;
}

.panel-wide {
    min-height: 100%;
}

.centered-layout {
    display: grid;
    place-items: center;
    min-height: calc(100vh - 180px);
}

.auth-panel,
.panel-wide {
    width: min(720px, 100%);
}

.app-form {
    display: grid;
    gap: 16px;
    margin-top: 24px;
}

.app-form label {
    display: grid;
    gap: 8px;
    font-weight: 700;
}

.app-form span {
    font-size: 0.95rem;
}

.app-form input,
.app-form select,
.app-form textarea {
    width: 100%;
    padding: 0.95rem 1rem;
    border: 1px solid rgba(28, 28, 26, 0.16);
    border-radius: 16px;
    background: var(--surface-strong);
    color: var(--text);
    font: inherit;
}

.app-form textarea {
    resize: vertical;
}

.notice {
    margin-top: 20px;
    padding: 14px 16px;
    border-radius: 18px;
    border: 1px solid transparent;
}

.notice-success {
    background: rgba(10, 124, 102, 0.12);
    border-color: rgba(10, 124, 102, 0.2);
}

.notice-error {
    background: rgba(176, 56, 28, 0.12);
    border-color: rgba(176, 56, 28, 0.2);
}

.history-block {
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid var(--border);
}

.history-list li {
    margin-bottom: 10px;
}

.history-list strong,
.history-list span {
    display: block;
}

strong {
    font-weight: 700;
}

@media (max-width: 900px) {
    .hero,
    .info-grid,
    .dashboard-grid {
        grid-template-columns: 1fr;
    }

    .site-header {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 640px) {
    .page-shell {
        width: min(100% - 20px, 1180px);
    }

    .hero h1,
    .panel h1 {
        font-size: clamp(2.2rem, 13vw, 3rem);
    }

    .panel,
    .hero-card {
        padding: 22px;
        border-radius: 24px;
    }
}