:root {
    --ink: #17201d;
    --muted: #65706b;
    --paper: #f3f5ef;
    --card: #fbfcf8;
    --line: #ccd2ca;
    --accent: #165b42;
    --accent-bright: #cfff69;
    --shadow: 0 24px 70px rgba(23, 32, 29, 0.12);
}

* { box-sizing: border-box; }

html { min-height: 100%; }

body {
    min-height: 100vh;
    margin: 0;
    color: var(--ink);
    background:
        radial-gradient(circle at 88% 8%, rgba(207, 255, 105, 0.28), transparent 26rem),
        var(--paper);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

a { color: inherit; }

.login-page {
    display: grid;
    place-items: center;
    padding: 24px;
}

.login-shell { width: min(100%, 460px); }

.login-card {
    padding: clamp(32px, 7vw, 54px);
    border: 1px solid var(--line);
    border-radius: 28px;
    background: rgba(251, 252, 248, 0.92);
    box-shadow: var(--shadow);
    backdrop-filter: blur(18px);
}

.brand-mark {
    display: grid;
    width: 54px;
    height: 54px;
    place-items: center;
    border-radius: 16px;
    color: var(--accent-bright);
    background: var(--accent);
    font-family: Georgia, "Times New Roman", serif;
    font-size: 1.8rem;
    font-style: italic;
}

.brand-mark.small {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    font-size: 1.15rem;
}

.eyebrow {
    margin: 30px 0 12px;
    color: var(--accent);
    font-size: 0.78rem;
    font-weight: 800;
    letter-spacing: 0.16em;
}

h1 {
    max-width: 780px;
    margin: 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.6rem, 7vw, 5.7rem);
    font-weight: 500;
    letter-spacing: -0.055em;
    line-height: 0.98;
}

.login-card h1 {
    font-size: clamp(2.4rem, 9vw, 3.7rem);
}

.login-copy,
.intro-copy {
    color: var(--muted);
    font-size: 1.05rem;
    line-height: 1.65;
}

.login-copy { margin: 18px 0 30px; }

.login-form label {
    display: block;
    margin-bottom: 9px;
    font-size: 0.88rem;
    font-weight: 700;
}

.password-row {
    display: flex;
    gap: 8px;
}

input,
button {
    min-height: 50px;
    border: 1px solid var(--line);
    border-radius: 12px;
    font: inherit;
}

input {
    min-width: 0;
    flex: 1;
    padding: 0 15px;
    color: var(--ink);
    background: white;
}

input:focus {
    border-color: var(--accent);
    outline: 3px solid rgba(22, 91, 66, 0.15);
}

button {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 17px;
    border-color: var(--accent);
    color: white;
    background: var(--accent);
    cursor: pointer;
    font-weight: 750;
}

.form-error {
    margin: 12px 0 0;
    color: #a22f2f;
    font-size: 0.9rem;
}

.site-header {
    display: flex;
    width: min(1180px, calc(100% - 48px));
    margin: 0 auto;
    padding: 26px 0;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--line);
}

.wordmark {
    display: flex;
    align-items: center;
    gap: 11px;
    text-decoration: none;
    font-weight: 800;
    letter-spacing: -0.02em;
}

.sign-out {
    color: var(--muted);
    font-size: 0.9rem;
    font-weight: 650;
    text-underline-offset: 4px;
}

.directory-shell {
    width: min(1180px, calc(100% - 48px));
    margin: 0 auto;
    padding: clamp(58px, 9vw, 112px) 0 36px;
}

.intro { margin-bottom: clamp(48px, 8vw, 82px); }

.intro .eyebrow { margin-top: 0; }

.intro-copy { margin: 24px 0 0; }

.project-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    border-top: 1px solid var(--line);
}

.project-card {
    position: relative;
    display: grid;
    min-height: 126px;
    grid-template-columns: 42px 1fr auto;
    gap: 15px;
    padding: 28px 24px;
    align-items: start;
    border-bottom: 1px solid var(--line);
    text-decoration: none;
    transition: background 180ms ease, transform 180ms ease;
}

.project-card:nth-child(odd) { border-right: 1px solid var(--line); }

.project-card:hover,
.project-card:focus-visible {
    z-index: 1;
    background: var(--card);
    box-shadow: inset 4px 0 0 var(--accent-bright);
}

.project-card:focus-visible { outline: 3px solid var(--accent); }

.project-number {
    padding-top: 5px;
    color: var(--muted);
    font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
    font-size: 0.78rem;
}

.project-name {
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1.5rem, 3vw, 2.2rem);
    line-height: 1.08;
}

.project-arrow {
    color: var(--accent);
    font-size: 1.35rem;
    transition: transform 180ms ease;
}

.project-card:hover .project-arrow { transform: translate(3px, -3px); }

.empty-state {
    padding: 28px 0;
    border-top: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    color: var(--muted);
}

footer {
    display: flex;
    justify-content: space-between;
    padding-top: 24px;
    color: var(--muted);
    font-size: 0.8rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

@media (max-width: 700px) {
    .site-header,
    .directory-shell { width: min(100% - 32px, 1180px); }

    .directory-shell { padding-top: 52px; }

    .project-grid { grid-template-columns: 1fr; }

    .project-card:nth-child(odd) { border-right: 0; }

    .project-card { padding-inline: 8px; }

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

    button { justify-content: space-between; }
}

@media (prefers-reduced-motion: reduce) {
    * { scroll-behavior: auto !important; transition: none !important; }
}
