/* Design tokens */
:root {
    color-scheme: light;
    --background: #f6f5f2;
    --surface: rgba(255, 255, 255, 0.68);
    --surface-strong: rgba(255, 255, 255, 0.78);
    --ink: #121212;
    --ink-soft: #424242;
    --accent: #3a7dff;
    --accent-strong: #2a63db;
    --accent-soft: #e5edff;
    --border: rgba(18, 18, 18, 0.07);
    --shadow-soft: 0 20px 48px rgba(15, 15, 24, 0.12);
    --shadow-strong: 0 30px 70px rgba(15, 15, 24, 0.18);
    --pointer-x: 0.5;
    --pointer-y: 0.5;
    --page-padding-block: clamp(24px, 5vh, 44px);
    --page-padding-inline: var(--page-padding-block);
    --page-padding-bottom: clamp(14px, 3vh, 24px);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    height: 100%;
}

body {
    height: 100%;
    min-height: 100vh;
    margin: 0;
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
    font-weight: 400;
    font-size: 16px;
    line-height: 1.65;
    color: var(--ink);
    background: var(--background);
    overflow-x: hidden;
    overflow-y: auto;
    position: relative;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

body.no-scroll {
    overflow-x: hidden;
    overflow-y: hidden;
}

body[data-locked="true"] .single-page,
body[data-locked="true"] .ambient-canvas {
    display: none;
}

body[data-locked="true"] {
    overflow-x: hidden;
    overflow-y: hidden;
}

.password-gate {
    position: fixed;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: clamp(24px, 6vw, 48px);
    background: radial-gradient(circle at top, rgba(58, 125, 255, 0.08), rgba(246, 245, 242, 0.98) 60%);
    z-index: 2000;
    transition: opacity 0.3s ease;
}

.password-gate.is-hidden {
    opacity: 0;
    pointer-events: none;
}

.password-gate__content {
    width: min(520px, 100%);
    background: rgba(255, 255, 255, 0.82);
    border-radius: 24px;
    border: 1px solid rgba(18, 18, 18, 0.08);
    box-shadow: 0 30px 60px rgba(15, 15, 24, 0.16);
    backdrop-filter: blur(28px);
    padding: clamp(28px, 6vw, 44px);
    display: flex;
    flex-direction: column;
    gap: clamp(18px, 3vw, 26px);
}

.password-gate__header h1 {
    margin: 0;
    font-size: clamp(1.8rem, 4vw, 2.4rem);
    letter-spacing: -0.02em;
    color: var(--ink);
}

.password-gate__description {
    margin: 12px 0 0;
    font-size: clamp(1rem, 2.2vw, 1.08rem);
    color: var(--ink-soft);
    line-height: 1.6;
}

.password-gate__form {
    display: flex;
    flex-direction: column;
    gap: clamp(16px, 2.8vw, 20px);
}

.password-gate__label {
    font-size: 0.92rem;
    font-weight: 600;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: rgba(18, 18, 18, 0.68);
}

.password-gate__input {
    padding: 0.9rem 1.15rem;
    border-radius: 14px;
    border: 1px solid rgba(18, 18, 18, 0.1);
    background: rgba(255, 255, 255, 0.95);
    font: inherit;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    transition: border-color 0.25s ease, box-shadow 0.25s ease;
}

.password-gate__input:focus-visible {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(58, 125, 255, 0.12);
}

.password-gate__input.is-error {
    border-color: #d33a2c;
    box-shadow: 0 0 0 3px rgba(211, 58, 44, 0.16);
}

.password-gate__submit {
    align-self: flex-start;
    padding-inline: clamp(2.4rem, 4vw, 3rem);
}

.password-gate__error {
    min-height: 1.2rem;
    margin: 0;
    font-size: 0.9rem;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #d33a2c;
}

.password-gate__hint {
    margin: 0;
    font-size: 0.9rem;
    color: rgba(18, 18, 18, 0.66);
    letter-spacing: 0.04em;
}

.password-gate__hint a {
    color: var(--accent);
}

body::before {
    content: "";
    position: fixed;
    inset: 0;
    background: radial-gradient(circle at calc(var(--pointer-x) * 100%) calc(var(--pointer-y) * 100%), rgba(58, 125, 255, 0.18), transparent 55%);
    opacity: 0.8;
    pointer-events: none;
    transition: opacity 0.6s ease;
    z-index: 0;
    mix-blend-mode: screen;
}

body::after {
    content: "";
    position: fixed;
    inset: 0;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0) 30%, rgba(58, 125, 255, 0.1) 130%);
    pointer-events: none;
    z-index: 0;
}

.ambient-canvas {
    position: fixed;
    inset: -10vmax;
    background:
        radial-gradient(40% 40% at 20% 25%, rgba(255, 255, 255, 0.9) 0%, rgba(255, 255, 255, 0) 70%),
        radial-gradient(60% 50% at 80% 75%, rgba(58, 125, 255, 0.28) 0%, rgba(58, 125, 255, 0) 70%),
        linear-gradient(160deg, rgba(18, 18, 18, 0.025), rgba(18, 18, 18, 0.05));
    filter: blur(40px);
    opacity: 0.85;
    pointer-events: none;
    z-index: 0;
}

.noscript-warning {
    position: relative;
    z-index: 1200;
    margin: clamp(24px, 5vh, 48px) auto 0;
    padding: clamp(16px, 3vw, 24px) clamp(20px, 4vw, 32px);
    max-width: min(640px, 90%);
    background: rgba(255, 242, 242, 0.9);
    border: 1px solid rgba(211, 58, 44, 0.18);
    border-radius: 16px;
    color: #8a1c1c;
    text-align: center;
    font-weight: 600;
    letter-spacing: 0.08em;
}

.noscript-warning p {
    margin: 0;
}

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

button {
    font: inherit;
    color: inherit;
    background: none;
    border: none;
    cursor: pointer;
}

img {
    max-width: 100%;
    display: block;
}

.single-page {
    min-height: 100vh;
    height: auto;
    display: flex;
    align-items: stretch;
    justify-content: center;
    position: relative;
    z-index: 1;
    padding-block-start: var(--page-padding-block);
    padding-block-end: var(--page-padding-bottom);
    padding-inline: var(--page-padding-inline);
}

.container {
    width: 100%;
    max-width: 1220px;
    margin: 0 auto;
    height: auto;
}

.portfolio-layout {
    display: grid;
    grid-template-rows: auto auto auto;
    gap: clamp(12px, 2vh, 18px);
    width: 100%;
    align-items: stretch;
    align-content: start;
    min-height: 100%;
}

.hero-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: var(--surface);
    border-radius: 26px;
    padding: clamp(22px, 4vh, 40px);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(18px);
    position: relative;
    isolation: isolate;
    min-height: 0;
}

.hero-section::before {
    content: "";
    position: absolute;
    inset: 14px;
    border-radius: 18px;
    background: linear-gradient(140deg, rgba(58, 125, 255, 0.16), rgba(255, 255, 255, 0));
    pointer-events: none;
    opacity: 0.85;
    z-index: -1;
}

.hero-text {
    position: relative;
    z-index: 1;
    display: grid;
    grid-template-columns: minmax(0, 1.65fr) minmax(0, 0.7fr);
    align-items: center;
    gap: clamp(18px, 3vw, 36px);
    width: 100%;
    min-height: 0;
}

.hero-copy {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    text-align: left;
    max-width: min(68ch, 100%);
    width: 100%;
    gap: clamp(4px, 0.8vh, 10px);
}

.hero-intro {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 8px;
    margin-bottom: clamp(4px, 0.8vw, 10px);
    width: 100%;
}

.hero-tag {
    font-size: 0.66rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    font-weight: 600;
    padding: 0.5rem 0.9rem;
    border-radius: 999px;
    background: var(--accent-soft);
    color: var(--accent);
    box-shadow: inset 0 0 0 1px rgba(58, 125, 255, 0.26);
    white-space: nowrap;
}

.hero-bar {
    width: 70px;
    height: 2px;
    background: linear-gradient(90deg, rgba(58, 125, 255, 0.5), rgba(58, 125, 255, 0));
}

h1 {
    font-size: clamp(2.1rem, 3vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.04em;
    text-transform: uppercase;
    margin: 0 0 clamp(10px, 1.2vw, 16px);
    line-height: 1.08;
}

h2 {
    font-size: clamp(1.1rem, 1.6vw, 1.5rem);
    font-weight: 600;
    letter-spacing: 0.24em;
    text-transform: uppercase;
    margin: 0 0 clamp(14px, 2vw, 22px);
    color: rgba(18, 18, 18, 0.76);
}

h3 {
    font-size: clamp(0.88rem, 1.05vw, 1.05rem);
    font-weight: 600;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    margin: 0;
    text-wrap: balance;
}

.subhead {
    font-size: clamp(0.94rem, 0.85vw, 1.02rem);
    color: var(--ink-soft);
    margin: 0;
    max-width: none;
    line-height: 1.32;
    text-wrap: pretty;
}

.hero-copy .subhead:first-of-type {
    margin-top: 0;
}

.hero-copy .subhead:last-of-type {
    margin-bottom: 0;
}

.hero-actions {
    margin-top: clamp(10px, 1.6vh, 18px);
    display: flex;
    align-items: center;
    gap: clamp(16px, 2vw, 22px);
    justify-content: flex-start;
    width: auto;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.92rem 2.8rem;
    background: var(--accent);
    color: #ffffff;
    font-weight: 600;
    font-size: 0.9rem;
    letter-spacing: 0.18em;
    text-transform: uppercase;
    border-radius: 999px;
    transition: transform 0.4s cubic-bezier(0.34, 0.56, 0.21, 1), box-shadow 0.4s ease, background 0.4s ease;
    box-shadow: 0 20px 40px rgba(58, 125, 255, 0.28);
}

.btn-primary:hover {
    background: var(--accent-strong);
    transform: translateY(-3px) scale(1.015);
    box-shadow: 0 28px 60px rgba(42, 99, 219, 0.3);
}

.btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 12px 28px rgba(58, 125, 255, 0.24);
}

.btn-primary:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 4px;
}

.portrait-shell {
    width: clamp(220px, 24vw, 260px);
    aspect-ratio: 1;
    border-radius: 26px;
    padding: 10px;
    background: linear-gradient(155deg, rgba(58, 125, 255, 0.18), rgba(255, 255, 255, 0.88));
    border: 1px solid rgba(58, 125, 255, 0.28);
    box-shadow: var(--shadow-soft);
    position: relative;
    overflow: hidden;
    transform-style: preserve-3d;
    transition: transform 0.6s cubic-bezier(0.21, 0.61, 0.39, 1), box-shadow 0.6s ease;
    justify-self: end;
    align-self: center;
}

.portrait-shell::after {
    content: "";
    position: absolute;
    inset: 16px;
    border-radius: 22px;
    border: 1px solid rgba(255, 255, 255, 0.5);
    pointer-events: none;
}

.hero-section:hover .portrait-shell {
    transform: translateZ(0) scale(1.015);
    box-shadow: var(--shadow-strong);
}

.portrait-image {
    width: 100%;
    height: 100%;
    border-radius: 20px;
    object-fit: cover;
    display: block;
}

.highlights-section {
    display: flex;
    flex-direction: column;
    gap: clamp(12px, 2vh, 16px);
    align-items: stretch;
    background: var(--surface);
    border-radius: 22px;
    padding: clamp(18px, 3vh, 28px);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-soft);
    backdrop-filter: blur(22px);
    position: relative;
    overflow: hidden;
    isolation: isolate;
    min-height: 0;
}

.highlights-section > h2 {
    align-self: flex-start;
    margin: 0;
    padding: 0;
    text-align: left;
}

.highlights-section::before {
    content: "";
    position: absolute;
    inset: 12px;
    border-radius: 18px;
    background: linear-gradient(160deg, rgba(58, 125, 255, 0.22), rgba(255, 255, 255, 0) 55%);
    pointer-events: none;
    z-index: -1;
}

.highlights-grid {
    flex: 1;
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    grid-auto-rows: minmax(0, 1fr);
    gap: clamp(12px, 1.6vw, 18px);
    min-height: 0;
    justify-content: stretch;
    align-content: stretch;
    width: 100%;
}

.card {
    --tiltX: 0deg;
    --tiltY: 0deg;
    --tiltScale: 1;
    position: relative;
    border-radius: 20px;
    padding: clamp(8px, 1vw, 12px);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    background-color: rgba(255, 255, 255, 0.92);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.65);
    border: 1px solid rgba(18, 18, 18, 0.04);
    transition: transform 0.65s cubic-bezier(0.22, 0.61, 0.36, 1), box-shadow 0.45s ease, border-color 0.45s ease;
    overflow: hidden;
    min-height: clamp(130px, 18vh, 180px);
    will-change: transform;
    isolation: isolate;
    transform: perspective(900px) rotateX(var(--tiltX)) rotateY(var(--tiltY)) scale(var(--tiltScale));
}

.card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(160deg, rgba(18, 18, 18, 0.6), rgba(18, 18, 18, 0.15) 60%, rgba(18, 18, 18, 0));
    opacity: 0;
    transition: opacity 0.45s ease;
    z-index: 0;
}

.card:hover,
.card:focus-visible {
    border-color: rgba(58, 125, 255, 0.28);
    box-shadow: 0 28px 50px rgba(15, 15, 24, 0.18);
    --tiltScale: 1.02;
}

.card:hover::before,
.card:focus-visible::before {
    opacity: 1;
}

.card:focus-visible {
    outline: 2px solid rgba(58, 125, 255, 0.7);
    outline-offset: 4px;
}

.card-text-overlay {
    position: absolute;
    left: 50%;
    bottom: clamp(12px, 1.8vw, 20px);
    transform: translateX(-50%);
    z-index: 1;
    background: rgba(17, 21, 34, 0.58);
    color: #f4f7ff;
    padding: clamp(6px, 0.9vw, 10px) clamp(12px, 1.4vw, 16px);
    border-radius: 16px;
    box-shadow: 0 10px 22px rgba(12, 16, 28, 0.28);
    backdrop-filter: blur(4px);
    border: 1px solid rgba(42, 54, 78, 0.42);
    width: calc(100% - 20px);
    max-width: calc(100% - 20px);
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: clamp(36px, 4vh, 48px);
    box-sizing: border-box;
    padding-inline: clamp(12px, 1.4vw, 18px);
}

.card-text-overlay h3 {
    letter-spacing: 0.08em;
    font-size: clamp(0.78rem, 0.82rem + 0.18vw, 0.98rem);
    text-align: center;
}

.card-title--tight {
    letter-spacing: 0.08em;
    font-size: clamp(0.74rem, 0.76rem + 0.16vw, 0.9rem);
    white-space: nowrap;
}

.card-title--nowrap {
    white-space: nowrap;
    letter-spacing: 0.1em;
    font-size: clamp(0.76rem, 0.8rem + 0.14vw, 0.94rem);
}

.card-text-overlay p {
    display: none;
}

.card.card--logo {
    align-items: center;
    justify-content: center;
    padding: clamp(10px, 1vw, 14px);
    background-repeat: no-repeat;
    background-size: clamp(46%, 9vw, 54%);
    background-position: center 32%;
    background-color: rgba(255, 255, 255, 0.92);
}

.card.card--logo .card-text-overlay {
    background: rgba(17, 21, 34, 0.62);
    box-shadow: 0 10px 22px rgba(12, 16, 28, 0.28);
}

.card.card--logo::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 46%;
    background: linear-gradient(0deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0));
    z-index: 0;
}

.card--compact {
    min-height: clamp(130px, 18vh, 180px);
    padding: clamp(6px, 0.8vw, 10px);
    background-size: clamp(42%, 8vw, 52%);
    background-position: center 32%;
}

.card--compact .card-text-overlay,
.card--compact.card--logo .card-text-overlay {
    width: calc(100% - 16px);
    max-width: calc(100% - 16px);
}

.card--adopt {
    background-image: url("../assets/images/adoptafilter.png");
    background-position: center 24%;
    background-size: clamp(38%, 7vw, 46%);
}

.card--adopt::before {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 26%;
    background: linear-gradient(0deg, rgba(255, 255, 255, 0.95), rgba(255, 255, 255, 0));
    z-index: 0;
}

.card--vocational {
    background-image: url("../assets/images/research.webp");
}

.card--manufacturing {
    background-image: url("../assets/images/manufacturing.jpg");
}

.card--value-engineering {
    background-image: url("../assets/images/engineering.jpg");
}

.card--whatsapp {
    background-image: url("../assets/images/whatsapp.png");
    background-color: rgba(255, 255, 255, 0.9);
}

.card--summer {
    background-image: url("../assets/images/SUMMERCOURSE.png");
    background-position: 65% center;
}

.footer-section {
    align-self: stretch;
    padding: clamp(4px, 0.6vh, 8px) 0 0;
    text-align: center;
    width: 100%;
}

.footer-section p {
    margin: 0;
    font-size: clamp(0.82rem, 0.9vw, 0.95rem);
    letter-spacing: 0.16em;
    text-transform: uppercase;
    color: rgba(18, 18, 18, 0.7);
    line-height: 1.2;
}

.footer-section a {
    color: var(--accent);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-section a:hover,
.footer-section a:focus-visible {
    color: var(--accent-strong);
    text-decoration: underline;
}

.modal[aria-hidden="true"] {
    display: none;
}

.modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    background: rgba(244, 247, 255, 0.85);
    backdrop-filter: blur(12px);
    animation: fadeIn 0.35s ease;
}

.modal.is-visible {
    display: block;
}

.modal-content {
    background: var(--surface-strong);
    margin: 0;
    padding: clamp(28px, 3.5vw, 48px);
    border-radius: 32px;
    border: 1px solid var(--border);
    width: min(90%, 760px);
    max-height: 86vh;
    overflow-y: auto;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: var(--shadow-strong);
    animation: slideUp 0.4s cubic-bezier(0.22, 0.61, 0.36, 1);
}

.modal-title {
    font-size: clamp(1.45rem, 2vw, 1.85rem);
    margin: 0 0 24px;
    letter-spacing: 0.12em;
    text-transform: uppercase;
}

.modal-media {
    text-align: center;
    margin-bottom: 32px;
}

.modal-media img {
    max-width: 300px;
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.1);
}

.modal-cta {
    margin-top: 32px;
    text-align: center;
}

.close {
    color: rgba(18, 18, 18, 0.5);
    font-size: 32px;
    font-weight: 300;
    cursor: pointer;
    position: sticky;
    top: 0;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    transition: transform 0.35s ease, background 0.35s ease, color 0.35s ease;
    margin-left: auto;
}

.close:hover {
    background: rgba(58, 125, 255, 0.14);
    color: var(--accent);
    transform: rotate(90deg);
}

.close:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 4px;
}

#modal-body p {
    margin: 0 0 16px;
    line-height: 1.75;
    color: var(--ink-soft);
    font-size: clamp(1rem, 1.05rem, 1.08rem);
}

#modal-body p strong {
    color: var(--ink);
    font-weight: 600;
}

#modal-body ul {
    list-style: none;
    padding: 0;
    margin: 0 0 24px;
}

#modal-body li {
    position: relative;
    padding-left: 28px;
    margin-bottom: 14px;
    color: var(--ink-soft);
    line-height: 1.7;
}

#modal-body li::before {
    content: "→";
    position: absolute;
    left: 0;
    top: 0;
    color: var(--accent);
    font-weight: 700;
    font-size: 1rem;
}

.resource-stack {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.resource-card {
    --resource-accent: var(--accent);
    --resource-shadow: rgba(58, 125, 255, 0.18);
    --resource-media-bg: var(--resource-accent);
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 24px;
    border: 2px solid #e8e8e8;
    border-radius: 12px;
    text-decoration: none;
    color: inherit;
    background: #fff;
    transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.resource-card:hover,
.resource-card:focus-visible {
    transform: translateY(-2px);
    border-color: var(--resource-accent);
    box-shadow: 0 8px 24px var(--resource-shadow);
}

.resource-card:focus-visible {
    outline: 2px solid var(--resource-accent);
    outline-offset: 4px;
}

.resource-card__media {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    background: var(--resource-media-bg);
    border: 1px solid transparent;
    color: #ffffff;
    overflow: hidden;
}

.resource-card__media img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: 8px;
}

.resource-card__emoji {
    font-size: 2rem;
    line-height: 1;
}

.resource-card__body {
    flex: 1;
}

.resource-card__body h4 {
    margin: 0 0 8px;
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.resource-card__body p {
    margin: 0;
    color: #666666;
    font-size: 0.95rem;
    line-height: 1.5;
}

.resource-card__chevron {
    flex-shrink: 0;
    font-size: 1.5rem;
    color: var(--resource-accent);
}

.resource-card--sky {
    --resource-accent: #0066cc;
    --resource-shadow: rgba(0, 102, 204, 0.15);
}

.resource-card--navy {
    --resource-accent: #00356b;
    --resource-shadow: rgba(0, 53, 107, 0.15);
}

.resource-card--midnight {
    --resource-accent: #002D72;
    --resource-shadow: rgba(0, 45, 114, 0.15);
}

.resource-card--crimson {
    --resource-accent: #8C1515;
    --resource-shadow: rgba(140, 21, 21, 0.15);
}

.resource-card--orange {
    --resource-accent: #ff6900;
    --resource-shadow: rgba(255, 105, 0, 0.18);
}

.resource-card--logo {
    --resource-media-bg: #ffffff;
}

.resource-card--logo .resource-card__media {
    border-color: rgba(0, 0, 0, 0.08);
    padding: 8px;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translate(-50%, -46%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

@media (max-width: 1200px) {
    .highlights-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: clamp(14px, 2vw, 20px);
    }

    .hero-section {
        padding: clamp(24px, 4vw, 40px);
    }
}

@media (max-width: 1024px) {
    :root {
        --page-padding-block: clamp(22px, 6vh, 36px);
        --page-padding-inline: var(--page-padding-block);
        --page-padding-bottom: clamp(12px, 3vh, 22px);
    }

    .single-page {
        padding-block: var(--page-padding-block);
        padding-inline: var(--page-padding-inline);
    }

    .hero-section {
        padding: clamp(22px, 5vh, 36px);
    }

    .hero-copy {
        align-items: center;
        text-align: center;
    }

    .hero-text {
        display: flex;
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: clamp(12px, 3vw, 20px);
    }

    .hero-tag {
        letter-spacing: 0.15em;
    }

    .hero-intro {
        justify-content: center;
    }

    .hero-actions {
        justify-content: center;
    }

    .portrait-shell {
        width: clamp(180px, 36vw, 220px);
    }

    .subhead {
        font-size: clamp(0.9rem, 1.5vw, 1.02rem);
    }

    .highlights-section {
        padding: clamp(20px, 5vh, 32px);
    }
}

@media (min-width: 1440px) {
    :root {
        --page-padding-inline: clamp(36px, 10vw, 120px);
        --page-padding-block: clamp(28px, 6vh, 48px);
    }

    .container {
        max-width: 1320px;
    }

    .hero-section,
    .highlights-section {
        padding: clamp(28px, 3vw, 48px);
    }

    .highlights-grid {
        gap: clamp(18px, 1.6vw, 28px);
    }
}

@media (max-width: 900px) {
    body {
        height: auto;
        min-height: 100vh;
        overflow-x: hidden;
        overflow-y: auto;
    }

    :root {
        --page-padding-block: clamp(16px, 6vh, 26px);
        --page-padding-inline: clamp(14px, 5vw, 22px);
        --page-padding-bottom: clamp(10px, 3vh, 18px);
    }

    .single-page {
        display: block;
        padding-block: var(--page-padding-block);
        padding-inline: var(--page-padding-inline);
        height: auto;
        min-height: 100vh;
    }

    .container,
    .portfolio-layout {
        height: auto;
    }

    .container {
        padding-inline: 0;
    }

    .portfolio-layout {
        display: flex;
        flex-direction: column;
        gap: clamp(14px, 3vh, 22px);
    }

    .hero-section {
        padding: clamp(20px, 5vh, 32px);
        width: 100%;
        margin-inline: auto;
    }

    .highlights-section {
        padding: clamp(18px, 5vh, 30px);
        width: 100%;
        margin-inline: auto;
    }

    .hero-intro {
        flex-direction: column;
        gap: 8px;
    }

    .hero-bar {
        width: 48px;
    }

    .hero-tag {
        font-size: 0.64rem;
        letter-spacing: 0.15em;
        padding: 0.42rem 0.9rem;
    }

    h1 {
        font-size: clamp(2rem, 7vw, 2.6rem);
    }

    .subhead {
        max-width: 100%;
        font-size: clamp(0.85rem, 2.3vw, 0.95rem);
        line-height: 1.6;
    }

    .portrait-shell {
        width: clamp(160px, 36vw, 200px);
        padding: 14px;
    }

    .highlights-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: clamp(12px, 2.4vw, 18px);
    }

    .card {
        min-height: clamp(130px, 26vh, 190px);
        padding: clamp(12px, 2vw, 18px);
    }

    .card-text-overlay {
        padding: clamp(8px, 2vw, 14px);
    }

    .footer-section p {
        font-size: clamp(0.74rem, 1.9vw, 0.85rem);
    }

    .card--compact {
        min-height: clamp(130px, 28vh, 190px);
        background-position: center 34%;
    }
}

@media (max-width: 640px) {
    body {
        font-size: 15px;
    }

    :root {
        --page-padding-block: clamp(14px, 6vh, 24px);
        --page-padding-inline: clamp(12px, 5vw, 18px);
        --page-padding-bottom: clamp(10px, 3vh, 18px);
    }

    .single-page {
        padding-block: var(--page-padding-block);
        padding-inline: var(--page-padding-inline);
    }

    .hero-section,
    .highlights-section {
        padding: clamp(16px, 6vw, 26px);
    }

    .hero-section {
        overflow: hidden;
    }

    .hero-intro {
        gap: 6px;
    }

    .hero-bar {
        width: 40px;
    }

    .hero-actions {
        margin-top: clamp(18px, 3vw, 26px);
    }

    .btn-primary {
        padding: 0.75rem 2.1rem;
        font-size: 0.78rem;
        letter-spacing: 0.16em;
        box-shadow: 0 16px 32px rgba(58, 125, 255, 0.24);
    }

    .highlights-grid {
        grid-template-columns: repeat(1, minmax(0, 1fr));
        gap: clamp(12px, 3vw, 18px);
    }

    .card {
        min-height: clamp(130px, 32vh, 200px);
    }

    .card-text-overlay {
        border-radius: 14px;
    }

    .card--compact {
        min-height: clamp(130px, 32vh, 200px);
    }

    .portrait-shell {
        width: clamp(128px, 50vw, 176px);
        max-width: calc(100% - clamp(28px, 9vw, 42px));
        margin: clamp(8px, 4vw, 18px) auto 0;
        padding: 10px;
    }

    .portrait-shell::after {
        inset: 9px;
    }

    .resource-stack {
        gap: clamp(8px, 3vw, 12px);
    }

    .resource-card {
        padding: clamp(8px, 3.2vw, 12px);
        gap: clamp(8px, 3vw, 12px);
        align-items: center;
        min-height: 0;
    }

    .resource-card__media {
        width: clamp(44px, 16vw, 56px);
        height: clamp(44px, 16vw, 56px);
    }

    .resource-card__body h4 {
        margin-bottom: 4px;
        font-size: clamp(0.9rem, 3.1vw, 1rem);
    }

    .resource-card__body p {
        font-size: clamp(0.78rem, 2.8vw, 0.88rem);
        line-height: 1.35;
    }

    .resource-card__chevron {
        font-size: 1.05rem;
    }

    .hero-section:hover .portrait-shell,
    .hero-section:focus-within .portrait-shell {
        transform: none;
        box-shadow: var(--shadow-soft);
    }
}

@media (max-width: 540px) {
    .container {
        padding: 0;
    }

    .hero-section,
    .highlights-section {
        padding: clamp(14px, 5vw, 20px);
    }

    .hero-section {
        align-items: center;
        gap: clamp(10px, 4vw, 16px);
    }

    .hero-intro {
        align-items: center;
        margin-bottom: clamp(10px, 3vw, 14px);
    }

    .card {
        border-radius: 18px;
        min-height: clamp(140px, 36vh, 220px);
    }

    .card--compact {
        min-height: clamp(140px, 36vh, 220px);
    }

    .highlights-grid {
        grid-template-columns: minmax(0, 1fr);
        gap: clamp(12px, 4vw, 20px);
    }

    .card-text-overlay {
        border-radius: 14px;
    }

    .card-text-overlay {
        border-radius: 14px;
    }

    .portrait-shell {
        width: clamp(118px, 58vw, 168px);
        max-width: calc(100% - clamp(24px, 10vw, 36px));
        padding: 8px;
    }

    .portrait-shell::after {
        inset: 8px;
    }

    .resource-card {
        padding: clamp(8px, 3.4vw, 12px);
        gap: clamp(8px, 4vw, 14px);
        min-height: 0;
    }

    .resource-card__media {
        width: clamp(40px, 18vw, 52px);
        height: clamp(40px, 18vw, 52px);
    }

    .resource-card__body h4 {
        font-size: clamp(0.88rem, 3.8vw, 0.98rem);
    }

    .resource-card__body p {
        font-size: clamp(0.76rem, 3.4vw, 0.88rem);
        line-height: 1.3;
    }
}

@media (max-height: 720px) {
    h1 {
        font-size: clamp(2rem, 3.2vw, 3rem);
    }

    .subhead {
        line-height: 1.55;
    }

    .card {
        min-height: clamp(120px, 18vh, 170px);
    }
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.001ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.001ms !important;
        scroll-behavior: auto !important;
    }

    body::before {
        opacity: 0.4;
    }
}
