/* MedFutureAcademy — shared styles */

:root {
    --bg-deep: #070a14;
    --bg-mid: #0c1020;
    --text: #e8eef8;
    --text-muted: rgba(232, 238, 248, 0.72);
    --accent: #2ee7f5;
    --accent-soft: rgba(46, 231, 245, 0.12);
    --accent-2: #9d7aff;
    --card-bg: rgba(255, 255, 255, 0.055);
    --card-border: rgba(255, 255, 255, 0.09);
    --shadow: 0 8px 40px rgba(0, 0, 0, 0.35);
    --radius: 20px;
    --font-display: "Outfit", system-ui, sans-serif;
    --font-body: "Source Sans 3", "Segoe UI", sans-serif;
    --dna-edge-width: min(28vw, 320px);
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.65;
    color: var(--text);
    background: var(--bg-deep);
    overflow-x: hidden;
}

/* Shiny DNA helix: fixed to viewport left / right (overlay sits beneath so both sides match) */
.dna {
    position: fixed;
    inset: 0;
    z-index: 0;
    pointer-events: none;
}

.dna::before,
.dna::after {
    content: "";
    position: fixed;
    top: 0;
    bottom: 0;
    width: var(--dna-edge-width);
    background-image: url("dna.svg");
    background-repeat: no-repeat;
    background-size: auto 100%;
    background-position: left center;
    opacity: 0.88;
    filter:
        drop-shadow(0 0 8px rgba(200, 255, 255, 0.55))
        drop-shadow(0 0 18px rgba(46, 231, 245, 0.45))
        drop-shadow(0 0 36px rgba(157, 122, 255, 0.22));
}

/* Outer edge strong, fade toward page center — mirror of each other */
.dna::before {
    left: 0;
    right: auto;
    -webkit-mask-image: linear-gradient(to right, #000 0%, #000 55%, transparent 100%);
    mask-image: linear-gradient(to right, #000 0%, #000 55%, transparent 100%);
}

.dna::after {
    left: auto;
    right: 0;
    transform: scaleX(-1);
    transform-origin: center center;
    -webkit-mask-image: linear-gradient(to left, #000 0%, #000 55%, transparent 100%);
    mask-image: linear-gradient(to left, #000 0%, #000 55%, transparent 100%);
}

@media (max-width: 720px) {
    :root {
        --dna-edge-width: min(22vw, 120px);
    }

    .dna::before,
    .dna::after {
        opacity: 0.55;
    }
}

@media (prefers-reduced-motion: reduce) {
    .dna::before,
    .dna::after {
        opacity: 0.45;
        filter: none;
    }
}

.overlay {
    position: fixed;
    inset: 0;
    background:
        radial-gradient(ellipse 80% 50% at 50% -20%, rgba(46, 231, 245, 0.14), transparent 55%),
        radial-gradient(ellipse 50% 45% at 50% 100%, rgba(157, 122, 255, 0.08), transparent 55%);
    z-index: -1;
    pointer-events: none;
}

.site-header {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 1.75rem 1.25rem 1rem;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.site-brand {
    font-family: var(--font-display);
    font-weight: 700;
    font-size: clamp(1.15rem, 3vw, 1.45rem);
    letter-spacing: -0.02em;
    color: var(--text);
    text-decoration: none;
    background: linear-gradient(120deg, var(--accent), var(--accent-2));
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.site-brand:hover {
    opacity: 0.92;
}

.lang-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.35rem;
    font-family: var(--font-display);
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.lang-nav a {
    color: var(--text-muted);
    text-decoration: none;
    padding: 0.45rem 0.75rem;
    border-radius: 10px;
    border: 1px solid transparent;
    transition: color 0.2s, background 0.2s, border-color 0.2s;
}

.lang-nav a:hover {
    color: var(--text);
    background: var(--accent-soft);
}

.lang-nav a[aria-current="page"] {
    color: var(--accent);
    background: rgba(46, 231, 245, 0.1);
    border-color: rgba(46, 231, 245, 0.25);
}

.lang-sep {
    color: rgba(255, 255, 255, 0.2);
    user-select: none;
}

.container {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 0 1.25rem 3.5rem;
}

.card {
    background: var(--card-bg);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--card-border);
    border-radius: var(--radius);
    padding: 1.5rem 1.65rem;
    margin-bottom: 1.15rem;
    box-shadow: var(--shadow);
    transition: border-color 0.25s ease, box-shadow 0.25s ease, transform 0.25s ease;
}

.card:hover {
    border-color: rgba(46, 231, 245, 0.18);
    box-shadow: 0 12px 48px rgba(0, 0, 0, 0.4), 0 0 0 1px rgba(46, 231, 245, 0.06);
}

.card p {
    margin: 0 0 0.85rem;
    color: var(--text-muted);
}

.card p:last-child {
    margin-bottom: 0;
}

.card h1,
.card h2 {
    font-family: var(--font-display);
    margin: 0 0 0.85rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--accent);
}

.card h1 {
    font-size: clamp(1.65rem, 4vw, 2rem);
}

.card h2 {
    font-size: clamp(1.2rem, 2.5vw, 1.35rem);
}

.card b {
    color: var(--text);
    font-weight: 600;
}

.contact {
    font-size: 1.02rem;
}

.contact p {
    display: flex;
    align-items: flex-start;
    gap: 0.35rem;
}

.site-footer {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
    padding: 1.5rem 1.25rem 2.5rem;
    text-align: center;
    font-size: 0.8125rem;
    color: rgba(232, 238, 248, 0.38);
    font-family: var(--font-display);
}

.site-footer a {
    color: rgba(232, 238, 248, 0.5);
    text-decoration: none;
}

.site-footer a:hover {
    color: var(--accent);
}

/* Root index.html: language picker only when ?noredirect or noscript */
noscript .root-fallback {
    opacity: 1;
    pointer-events: auto;
    max-height: none;
    margin: 2.5rem auto;
    text-align: center;
    font-family: var(--font-body);
    color: var(--text-muted);
}

noscript .root-fallback a {
    color: var(--accent);
    text-decoration: none;
}

.root-fallback {
    opacity: 0;
    pointer-events: none;
    max-height: 0;
    overflow: hidden;
    margin: 0;
}

html.noredirect-root .root-fallback {
    opacity: 1;
    pointer-events: auto;
    max-height: none;
    margin: 2.5rem auto;
    text-align: center;
    font-family: var(--font-body);
    color: var(--text-muted);
}

html.noredirect-root .root-fallback a {
    color: var(--accent);
    text-decoration: none;
}

html.noredirect-root .root-fallback a:hover {
    text-decoration: underline;
}

html.noredirect-root body {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}
