
.subjects-page {
    margin: 0;
    background: #f8faf8;
    color: #17211b;
    font-family: 'IBM Plex Sans', sans-serif;
    min-height: 100vh;
}

.subjects-page * {
    box-sizing: border-box;
}

.subjects-page a {
    color: inherit;
    text-decoration: none;
}

.subjects-header {
    min-height: 76px;
    padding: 0 7%;
    background: #fff;
    border-bottom: 1px solid #e5e9e5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
}

.subjects-header .brand {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;
}

.subjects-header .brand-logo {
    width: 150px;
    height: 44px;
    object-fit: contain;
    object-position: left center;
}

.header-nav,
.header-actions {
    display: flex;
    align-items: center;
    gap: 28px;
}

.header-nav a {
    font-size: 13px;
    color: #69746c;
    transition: color 180ms ease;
}

.header-nav a:hover,
.header-nav .nav-current {
    color: #166534;
}

.header-nav .nav-current {
    font-weight: 600;
}

.header-actions {
    gap: 22px;
}

.exam-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
    white-space: nowrap;
}

.status-dot {
    width: 7px;
    height: 7px;
    background: #22c55e;
    border-radius: 50%;
}

.profile-button {
    border: 0;
    background: transparent;
    display: flex;
    align-items: center;
    gap: 9px;
    cursor: pointer;
    font: inherit;
}

.profile-initial {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #e7f3e8;
    color: #166534;
    font-size: 13px;
    font-weight: 700;
}

.profile-name {
    font-size: 12px;
    font-weight: 600;
}

.profile-chevron {
    color: #69746c;
}

.subjects-main {
    width: min(1060px, 86%);
    margin: 0 auto;
}

.welcome-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 36px;
    padding: 76px 0 60px;
    border-bottom: 1px solid #dfe6df;
}

.eyebrow,
.section-kicker {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 0.15em;
    color: #647067;
}

.eyebrow-line {
    width: 25px;
    height: 2px;
    background: #22a052;
}

.welcome-copy h1 {
    margin: 24px 0 18px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: clamp(42px, 5.4vw, 68px);
    font-weight: 500;
    letter-spacing: -0.065em;
    line-height: 1.04;
}

.welcome-copy h1 span {
    color: #16803d;
}

.welcome-description {
    max-width: 490px;
    margin: 0;
    font-size: 14px;
    line-height: 1.9;
    color: #647067;
}

.welcome-note {
    width: 180px;
    padding: 0 0 8px 20px;
    border-left: 1px solid #dfe6df;
    flex-shrink: 0;
}

.note-index {
    color: #16803d;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.08em;
}

.note-rule {
    width: 100%;
    height: 1px;
    margin: 15px 0;
    background: #dfe6df;
}

.welcome-note p {
    margin: 0;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 17px;
    line-height: 1.5;
    letter-spacing: -0.035em;
}

.subject-section {
    padding-top: 46px;
}

.section-heading {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    gap: 20px;
    margin-bottom: 24px;
}

.section-kicker {
    font-size: 9px;
    margin-bottom: 10px;
}

.section-heading h2 {
    margin: 0;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 29px;
    font-weight: 500;
    letter-spacing: -0.045em;
}

.subject-count {
    margin: 0 0 3px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 22px;
    color: #166534;
}

.subject-count span {
    display: block;
    margin-top: 3px;
    font-family: 'IBM Plex Sans', sans-serif;
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.12em;
    color: #647067;
}

.subject-list {
    border-top: 1px solid #dfe6df;
}

.subject-row {
    position: relative;
    display: grid;
    grid-template-columns: 34px 58px minmax(0, 1fr) 160px 20px;
    align-items: center;
    gap: 22px;
    width: 100%;
    min-height: 119px;
    padding: 22px 16px 22px 4px;
    border: 0;
    border-bottom: 1px solid #dfe6df;
    background: transparent;
    text-align: left;
    font: inherit;
    color: inherit;
    cursor: pointer;
    transition: background 180ms ease, padding 180ms ease;
}

.subject-row:hover,
.subject-row:focus-visible {
    background: #f0f7f0;
    padding-left: 14px;
    outline: none;
}

.subject-row:focus-visible {
    box-shadow: inset 3px 0 #16803d;
}

.subject-number {
    align-self: start;
    padding-top: 7px;
    font-size: 10px;
    font-weight: 600;
    color: #8b958d;
}

.subject-mark {
    width: 54px;
    height: 54px;
    display: grid;
    place-items: center;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 17px;
    font-weight: 600;
    letter-spacing: -0.06em;
}

.english-mark {
    background: #e3f1e4;
    color: #176334;
}

.maths-mark {
    background: #f8edc7;
    color: #795b08;
    font-size: 26px;
}

.physics-mark {
    background: #e5ecf9;
    color: #335b99;
    font-size: 25px;
}

.biology-mark {
    background: #e2eee7;
    color: #286746;
    font-size: 14px;
}

.subject-details {
    display: flex;
    flex-direction: column;
    gap: 7px;
    min-width: 0;
}

.subject-title {
    font-family: 'Space Grotesk', sans-serif;
    font-size: 20px;
    font-weight: 500;
    letter-spacing: -0.035em;
}

.subject-description {
    font-size: 12px;
    line-height: 1.7;
    color: #69746c;
}

.subject-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
}

.subject-tag {
    padding: 5px 7px;
    border: 1px solid #dce5dc;
    color: #647067;
    font-size: 8px;
    font-weight: 700;
    letter-spacing: 0.09em;
    white-space: nowrap;
}

.subject-status {
    font-size: 11px;
    color: #166534;
    font-weight: 600;
}

.subject-status span {
    margin-left: 5px;
}

.subject-arrow {
    color: #8a958c;
    font-size: 19px;
    transition: transform 180ms ease, color 180ms ease;
}

.subject-row:hover .subject-arrow {
    color: #166534;
    transform: translate(3px, -3px);
}

.bottom-note {
    display: flex;
    align-items: flex-start;
    gap: 18px;
    margin-top: 44px;
    padding: 24px 26px;
    background: #edf5ec;
    border-left: 3px solid #22a052;
}

.bottom-note-icon {
    color: #16803d;
    font-size: 23px;
    line-height: 1;
}

.bottom-note h3 {
    margin: 0 0 6px;
    font-family: 'Space Grotesk', sans-serif;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: -0.025em;
}

.bottom-note p {
    margin: 0;
    font-size: 12px;
    line-height: 1.8;
    color: #647067;
}

.subjects-footer {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-top: 50px;
    padding: 22px 0 28px;
    border-top: 1px solid #dfe6df;
    color: #788279;
    font-size: 10px;
}

/* Notification */
.toast-message {
    position: fixed;
    right: 24px;
    bottom: 24px;
    z-index: 10;
    max-width: min(360px, calc(100vw - 32px));
    padding: 14px 18px;
    background: #17211b;
    color: #fff;
    font-size: 13px;
    line-height: 1.6;
    opacity: 0;
    transform: translateY(8px);
    pointer-events: none;
    transition: opacity 180ms ease, transform 180ms ease;
}

.toast-message.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive */
@media (max-width: 850px) {
    .subjects-header {
        padding: 0 5%;
        gap: 20px;
    }

    .header-nav {
        gap: 16px;
    }

    .header-actions {
        gap: 12px;
    }

    .profile-name,
    .profile-chevron {
        display: none;
    }

    .subjects-main {
        width: 90%;
    }

    .welcome-section {
        padding-top: 60px;
    }

    .subject-row {
        grid-template-columns: 25px 48px minmax(0, 1fr) 20px;
        gap: 15px;
    }

    .subject-mark {
        width: 46px;
        height: 46px;
    }

    .subject-meta {
        display: none;
    }
}

@media (max-width: 560px) {
    .subjects-header {
        min-height: 68px;
        padding: 0 5%;
        gap: 12px;
    }

    .subjects-header .brand-logo {
        width: 112px;
        height: 38px;
    }

    .header-nav {
        display: none;
    }

    .header-actions {
        margin-left: auto;
    }

    .exam-label {
        font-size: 9px;
        letter-spacing: 0.04em;
    }

    .subjects-main {
        width: 90%;
    }

    .welcome-section {
        padding: 48px 0 38px;
    }

    .welcome-copy h1 {
        font-size: clamp(39px, 11vw, 54px);
        margin-top: 20px;
    }

    .welcome-description {
        font-size: 13px;
    }

    .welcome-note {
        display: none;
    }

    .subject-section {
        padding-top: 34px;
    }

    .section-heading h2 {
        font-size: 25px;
    }

    .subject-row {
        grid-template-columns: 22px 42px minmax(0, 1fr) 16px;
        gap: 11px;
        min-height: 105px;
        padding: 17px 3px;
    }

    .subject-row:hover,
    .subject-row:focus-visible {
        padding-left: 8px;
    }

    .subject-mark {
        width: 40px;
        height: 40px;
        font-size: 14px;
    }

    .maths-mark,
    .physics-mark {
        font-size: 21px;
    }

    .biology-mark {
        font-size: 12px;
    }

    .subject-title {
        font-size: 16px;
    }

    .subject-description {
        font-size: 11px;
        line-height: 1.55;
    }

    .subject-arrow {
        font-size: 16px;
    }

    .bottom-note {
        margin-top: 30px;
        padding: 20px 16px;
        gap: 12px;
    }

    .bottom-note h3 {
        font-size: 14px;
    }

    .bottom-note p {
        font-size: 11px;
    }

    .subjects-footer {
        margin-top: 36px;
        font-size: 9px;
    }
}

@media (prefers-reduced-motion: reduce) {
    .subject-row,
    .subject-arrow,
    .toast-message {
        transition: none;
    }
}
