.shell {
    width: 100%;
    max-width: 1280px;
    margin: 0 auto;
    padding: 48px 40px 80px;
}

.masthead {
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
    margin-bottom: 56px;
    padding-bottom: 24px;
    border-bottom: 2px solid var(--ink);
}

.masthead-brand {
    flex: 0 0 auto;
}

.masthead-brand--link {
    text-decoration: none;
    color: inherit;
}

.masthead-brand--link:hover .masthead-title {
    opacity: 0.65;
}

.masthead-eyebrow {
    display: block;
    font-size: 11px;
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: var(--ink-tertiary);
    margin-bottom: 6px;
}

.masthead-title {
    margin: 0;
    font-size: 32px;
    font-weight: 600;
    letter-spacing: -0.04em;
    line-height: 1.1;
    color: var(--ink);
}

.site-nav {
    display: flex;
    align-items: center;
    gap: 4px;
    margin-left: auto;
    margin-right: 8px;
}

.site-nav__link {
    font-size: 13px;
    font-weight: 500;
    color: var(--ink-secondary);
    text-decoration: none;
    padding: 6px 12px;
    border: 1px solid transparent;
    transition: color 0.15s ease, border-color 0.15s ease, background 0.15s ease;
}

.site-nav__link:hover {
    color: var(--ink);
    border-color: var(--line);
}

.site-nav__link.is-active {
    color: var(--ink);
    border-color: var(--ink);
    background: var(--white);
}

.masthead-link {
    flex: 0 0 auto;
    font-size: 13px;
    color: var(--ink-secondary);
    text-decoration: none;
    padding-bottom: 4px;
    border-bottom: 1px solid transparent;
    transition: color 0.15s ease, border-color 0.15s ease;
}

.masthead-link:hover {
    color: var(--ink);
    border-bottom-color: var(--ink);
}

.flash-error {
    margin: 0 0 20px;
    padding: 12px 16px;
    border: 1px solid var(--line);
    font-size: 14px;
    color: var(--ink);
}

.flash-success {
    margin: 0 0 20px;
    padding: 12px 16px;
    border: 1px solid #bbf7d0;
    background: #f0fdf4;
    font-size: 14px;
    color: #166534;
}

.empty-state {
    margin: 0;
    padding: 80px 24px;
    text-align: center;
    font-size: 14px;
    color: var(--ink-tertiary);
    border: 1px solid var(--line);
}

@media (max-width: 640px) {
    .shell {
        padding: 28px 20px 48px;
    }

    .masthead {
        margin-bottom: 36px;
    }

    .masthead-title {
        font-size: 26px;
    }

    .site-nav {
        order: 3;
        width: 100%;
        margin: 8px 0 0;
        margin-right: 0;
    }
}
