/* =========================================
   TODORAN PATRIC — PREMIUM IT PORTFOLIO
   Dark-first theme with light toggle
   ========================================= */

:root {
    --bg: #060709;
    --bg-alt: #0a0c11;
    --surface: rgba(255, 255, 255, 0.045);
    --surface-strong: rgba(255, 255, 255, 0.08);
    --surface-hover: rgba(255, 255, 255, 0.09);

    --text: #f5f6f8;
    --text-muted: #9aa0ae;

    --accent: #3b82f6;
    --accent-2: #60a5fa;
    --accent-soft: rgba(59, 130, 246, 0.12);

    --gradient: linear-gradient(120deg, #2563eb 0%, #3b82f6 50%, #60a5fa 100%);

    --border: rgba(255, 255, 255, 0.09);
    --border-strong: rgba(255, 255, 255, 0.16);

    --max-width: 1140px;

    --radius: 18px;
    --radius-sm: 12px;

    --ease: cubic-bezier(0.16, 1, 0.3, 1);
    --transition: 0.25s var(--ease);

    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 20px 60px rgba(0, 0, 0, 0.45);
    --shadow-glow: 0 0 0 1px rgba(255, 255, 255, 0.05), 0 20px 60px rgba(59, 130, 246, 0.12);
}

:root[data-theme="light"] {
    --bg: #ffffff;
    --bg-alt: #f5f7fb;
    --surface: #ffffff;
    --surface-strong: #eef3fb;
    --surface-hover: #f2f6fc;

    --text: #101828;
    --text-muted: #5b6472;

    --accent: #2454e0;
    --accent-2: #3b82f6;
    --accent-soft: rgba(36, 84, 224, 0.08);

    --gradient: linear-gradient(120deg, #1d4ed8 0%, #2454e0 50%, #3b82f6 100%);

    --border: rgba(16, 24, 40, 0.1);
    --border-strong: rgba(16, 24, 40, 0.18);

    --shadow-sm: 0 1px 2px rgba(16, 24, 40, 0.06);
    --shadow-md: 0 20px 45px rgba(16, 24, 40, 0.1);
    --shadow-glow: 0 1px 2px rgba(16, 24, 40, 0.05), 0 20px 55px rgba(36, 84, 224, 0.12);
}


/* =========================================
   RESET
   ========================================= */

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;

    background: var(--bg);
    color: var(--text);

    line-height: 1.65;

    overflow-x: hidden;

    transition: background var(--transition), color var(--transition);
}

h1, h2, h3, .logo, .project-number, .goal-number {
    font-family: "Space Grotesk", "Inter", sans-serif;
}

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

button {
    font: inherit;
}

img {
    max-width: 100%;
}


/* =========================================
   STATIC AMBIENT BACKGROUND (no motion)
   ========================================= */

.bg-layer {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
}

.bg-grid {
    position: absolute;
    inset: -1px;
    background-image:
        linear-gradient(to right, var(--border) 1px, transparent 1px),
        linear-gradient(to bottom, var(--border) 1px, transparent 1px);
    background-size: 64px 64px;
    opacity: 0.35;
    mask-image: radial-gradient(circle at 50% 0%, black, transparent 75%);
}

.bg-glow {
    position: absolute;
    width: 46vw;
    height: 46vw;
    border-radius: 50%;
    filter: blur(110px);
    opacity: 0.16;
}

.bg-glow-1 {
    top: -10%;
    left: -8%;
    background: radial-gradient(circle, var(--accent), transparent 70%);
}

.bg-glow-2 {
    bottom: -15%;
    right: -10%;
    width: 38vw;
    height: 38vw;
    background: radial-gradient(circle, var(--accent-2), transparent 70%);
    opacity: 0.12;
}

.grain {
    position: fixed;
    inset: 0;
    z-index: 1;
    pointer-events: none;
    opacity: 0.025;
    mix-blend-mode: overlay;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

:root[data-theme="light"] .grain {
    opacity: 0.015;
    mix-blend-mode: multiply;
}


/* =========================================
   PRELOADER
   ========================================= */

.preloader {
    position: fixed;
    inset: 0;
    z-index: 9999;

    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 16px;

    background: var(--bg);

    transition: opacity 0.6s var(--ease), visibility 0.6s var(--ease);
}

.preloader.is-hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.preloader-mark {
    font-size: 1.7rem;
    font-weight: 700;
    letter-spacing: -0.02em;
}

.preloader-mark span {
    color: var(--accent);
}

.preloader-name {
    font-family: "JetBrains Mono", monospace;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.3em;
    color: var(--text-muted);
}

.preloader-bar {
    width: 160px;
    height: 2px;
    background: var(--border);
    border-radius: 2px;
    overflow: hidden;
    margin-top: 8px;
}

.preloader-bar span {
    display: block;
    height: 100%;
    width: 40%;
    background: var(--gradient);
    animation: preloaderSlide 0.9s ease-in-out infinite;
}

@keyframes preloaderSlide {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(350%); }
}


/* =========================================
   SCROLL PROGRESS
   ========================================= */

.scroll-progress {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    z-index: 1001;
    background: transparent;
}

.scroll-progress span {
    display: block;
    height: 100%;
    width: 0%;
    background: var(--gradient);
}


/* =========================================
   GENERAL
   ========================================= */

.container {
    position: relative;
    z-index: 2;
    width: min(calc(100% - 40px), var(--max-width));
    margin: 0 auto;
}

.section {
    padding: 130px 0;
    position: relative;
    z-index: 2;
}

.section-alt {
    background: linear-gradient(180deg, transparent, var(--surface) 15%, var(--surface) 85%, transparent);
}

.section-heading {
    margin-bottom: 56px;
}

.eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 8px;

    color: var(--accent-2);

    font-family: "JetBrains Mono", monospace;
    font-size: 0.72rem;
    font-weight: 600;

    letter-spacing: 0.14em;

    margin-bottom: 14px;
}

.eyebrow.center {
    justify-content: center;
}

.eyebrow-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--accent-2);
    box-shadow: 0 0 8px var(--accent-2);
}

.section-heading h2 {
    font-size: clamp(1.9rem, 3.4vw, 2.7rem);
    line-height: 1.2;
    letter-spacing: -0.01em;
    font-weight: 700;
    color: var(--text);
}

.center {
    text-align: center;
}


/* =========================================
   REVEAL ON SCROLL
   ========================================= */

[data-reveal] {
    opacity: 0;
    transition: opacity 0.9s var(--ease), transform 0.9s var(--ease), filter 0.9s var(--ease);
    filter: blur(6px);
    will-change: transform, opacity;
}

[data-reveal="up"] { transform: translateY(34px); }
[data-reveal="left"] { transform: translateX(-64px) rotate(-4deg); }
[data-reveal="right"] { transform: translateX(64px) rotate(4deg); }
[data-reveal="scale"] { transform: scale(0.85) translateY(14px); }

[data-reveal].is-visible {
    opacity: 1;
    transform: translate(0, 0) rotate(0) scale(1);
    filter: blur(0);
}

@media (prefers-reduced-motion: reduce) {
    [data-reveal] {
        transition-duration: 0.01ms;
        filter: none;
    }
}


/* =========================================
   HEADER
   ========================================= */

.header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;

    background: transparent;
    backdrop-filter: none;
    border-bottom: 1px solid transparent;

    transition: background var(--transition), border-color var(--transition), box-shadow var(--transition), backdrop-filter var(--transition);
}

.header.is-scrolled {
    background: color-mix(in srgb, var(--bg) 80%, transparent);
    backdrop-filter: blur(16px) saturate(140%);
    border-bottom-color: var(--border);
    box-shadow: var(--shadow-sm);
}

.navbar {
    min-height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.logo {
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text);
}

.logo span {
    color: var(--accent-2);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 8px;
    margin-right: auto;
    margin-left: 40px;
}

.nav-links a {
    position: relative;
    display: block;
    padding: 8px 4px;
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 500;
    transition: color var(--transition);
}

.nav-links a span {
    position: relative;
}

.nav-links a span::after {
    content: "";
    position: absolute;
    left: 0;
    right: 100%;
    bottom: -4px;
    height: 1px;
    background: var(--gradient);
    transition: right var(--transition);
}

.nav-links a:hover {
    color: var(--text);
}

.nav-links a:hover span::after {
    right: 0;
}

.nav-links li {
    padding: 0 8px;
}

.nav-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.lang-toggle {
    display: flex;
    align-items: center;
    gap: 5px;
    height: 38px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text-muted);
    cursor: pointer;
    font-family: "JetBrains Mono", monospace;
    font-size: 0.7rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    transition: border-color var(--transition), color var(--transition);
}

.lang-toggle:hover {
    border-color: var(--accent);
}

.lang-sep {
    color: var(--border-strong);
}

.lang-option {
    transition: color var(--transition);
}

.lang-option[data-lang="de"] { color: var(--text); }

.lang-toggle[data-active="en"] .lang-option[data-lang="de"] { color: var(--text-muted); }
.lang-toggle[data-active="en"] .lang-option[data-lang="en"] { color: var(--text); }
.lang-toggle:not([data-active="en"]) .lang-option[data-lang="en"] { color: var(--text-muted); }

.theme-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 38px;
    height: 38px;
    border-radius: 50%;
    border: 1px solid var(--border);
    background: var(--surface);
    color: var(--text);
    cursor: pointer;
    transition: border-color var(--transition), color var(--transition), transform var(--transition);
}

.theme-toggle:hover {
    border-color: var(--accent);
    color: var(--accent-2);
    transform: rotate(12deg);
}

.theme-toggle .icon-sun {
    display: none;
}

:root[data-theme="light"] .theme-toggle .icon-sun {
    display: block;
}

:root[data-theme="light"] .theme-toggle .icon-moon {
    display: none;
}


/* =========================================
   MOBILE MENU
   ========================================= */

.menu-toggle {
    display: none;
    border: 0;
    background: transparent;
    cursor: pointer;
    width: 38px;
    height: 38px;
    flex-direction: column;
    justify-content: center;
    gap: 5px;
    z-index: 1001;
}

.menu-toggle span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--text);
    margin: 0 auto;
    transition: var(--transition);
}

.menu-toggle[aria-expanded="true"] span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] span:nth-child(2) {
    opacity: 0;
}

.menu-toggle[aria-expanded="true"] span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
}


/* =========================================
   HERO
   ========================================= */

.hero {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 100px;
    position: relative;
    z-index: 2;
}

.hero-content {
    max-width: 780px;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.hero-name {
    font-size: clamp(2.6rem, 7vw, 5rem);
    line-height: 1.05;
    letter-spacing: -0.02em;
    font-weight: 700;
    margin: 18px 0 14px;
}

.gradient-text {
    background: var(--gradient);
    background-size: 200% auto;
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-role {
    font-size: clamp(1.15rem, 2.2vw, 1.5rem);
    line-height: 1.4;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 22px;
}

.mobile-break {
    display: none;
}

.hero-description {
    max-width: 560px;
    color: var(--text-muted);
    font-size: 1.02rem;
    margin: 0 auto;
}

.hero-buttons {
    display: flex;
    justify-content: center;
    gap: 14px;
    margin-top: 36px;
    flex-wrap: wrap;
}

.scroll-cue {
    position: absolute;
    left: 50%;
    bottom: 36px;
    transform: translateX(-50%);
    width: 26px;
    height: 42px;
    border: 1px solid var(--border-strong);
    border-radius: 20px;
    display: flex;
    justify-content: center;
    padding-top: 8px;
    z-index: 2;
}

.scroll-cue span {
    width: 4px;
    height: 8px;
    border-radius: 2px;
    background: var(--accent-2);
    animation: scrollCue 1.8s ease-in-out infinite;
}

@keyframes scrollCue {
    0% { opacity: 1; transform: translateY(0); }
    70% { opacity: 0; transform: translateY(14px); }
    100% { opacity: 0; transform: translateY(14px); }
}


/* =========================================
   BUTTONS
   ========================================= */

.button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 48px;
    padding: 0 24px;
    border-radius: 999px;
    font-size: 0.9rem;
    font-weight: 600;
    isolation: isolate;
    overflow: hidden;
    transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition), color var(--transition);
}

.button span {
    position: relative;
    z-index: 1;
}

.button.primary {
    background: var(--gradient);
    background-size: 200% auto;
    color: #ffffff;
    box-shadow: 0 10px 30px -8px rgba(59, 130, 246, 0.5);
}

.button.primary:hover {
    background-position: 100% center;
    box-shadow: 0 14px 36px -6px rgba(59, 130, 246, 0.65);
    transform: translateY(-2px);
}

.button.secondary {
    border: 1px solid var(--border-strong);
    color: var(--text);
    background: var(--surface);
    backdrop-filter: blur(10px);
}

.button.secondary:hover {
    border-color: var(--accent-2);
    color: var(--accent-2);
    transform: translateY(-2px);
}


/* =========================================
   ABOUT
   ========================================= */

.about-grid {
    display: grid;
    grid-template-columns: 1.3fr 0.7fr;
    gap: 70px;
    align-items: start;
}

.about-text {
    color: var(--text-muted);
    font-size: 1.02rem;
}

.about-text p + p {
    margin-top: 18px;
}

.about-text strong {
    color: var(--text);
    font-weight: 600;
}

.about-cards {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
}

.info-card {
    padding: 22px;
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--surface);
    display: flex;
    flex-direction: column;
    gap: 6px;
    transition: border-color var(--transition), transform var(--transition);
}

.info-card:hover {
    border-color: var(--border-strong);
    transform: translateY(-3px);
}

.info-card span {
    color: var(--text-muted);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.info-card strong {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text);
}


/* =========================================
   SKILLS
   ========================================= */

.skills-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.skill-category {
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    transition: border-color var(--transition), transform var(--transition);
}

.skill-category:hover {
    border-color: var(--border-strong);
    transform: translateY(-3px);
}

.skill-category h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 18px;
}

.skill-list {
    list-style: none;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.skill-list li {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
    color: var(--text);
}

.skill-list li:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.level {
    font-style: normal;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    padding: 4px 10px;
    border-radius: 999px;
    white-space: nowrap;
    color: var(--accent-2);
    background: var(--accent-soft);
}

.level-learning { opacity: 0.7; }
.level-exploring { opacity: 0.82; }
.level-developing { opacity: 0.92; }
.level-growing { opacity: 1; }


/* =========================================
   TIMELINE
   ========================================= */

.timeline {
    position: relative;
    max-width: 850px;
}

.timeline-track {
    position: absolute;
    left: 5px;
    top: 10px;
    bottom: 10px;
    width: 1px;
    background: var(--border);
    overflow: hidden;
}

.timeline-progress {
    display: block;
    width: 100%;
    height: 0%;
    background: var(--gradient);
    transition: height 1.2s var(--ease);
}

.timeline-item {
    position: relative;
    padding-left: 45px;
    padding-bottom: 46px;
}

.timeline-item:last-child {
    padding-bottom: 0;
}

.timeline-marker {
    position: absolute;
    left: 0;
    top: 7px;
    width: 11px;
    height: 11px;
    background: var(--bg);
    border: 2px solid var(--accent);
    border-radius: 50%;
    z-index: 1;
}

.timeline-marker.future {
    border-style: dashed;
    border-color: var(--text-muted);
}

.timeline-marker.pulse::after {
    content: "";
    position: absolute;
    inset: -6px;
    border-radius: 50%;
    border: 1px solid var(--accent-2);
    animation: markerPulse 2s ease-out infinite;
}

@keyframes markerPulse {
    0% { transform: scale(0.6); opacity: 0.8; }
    100% { transform: scale(1.8); opacity: 0; }
}

.timeline-date {
    display: inline-block;
    color: var(--accent-2);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.68rem;
    font-weight: 600;
    letter-spacing: 0.1em;
    margin-bottom: 10px;
}

.timeline-content h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 6px;
    color: var(--text);
}

.timeline-content p {
    color: var(--text-muted);
    max-width: 700px;
}


/* =========================================
   EDUCATION CARD
   ========================================= */

.education-card {
    position: relative;
    max-width: 720px;
    padding: 36px;
    border: 1px solid var(--border);
    background: var(--surface);
    border-radius: var(--radius);
    overflow: hidden;
    transform-style: preserve-3d;
    transition: border-color var(--transition), box-shadow var(--transition), transform 0.1s ease-out;
}

.education-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow-md);
}

.education-top {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 18px;
}

.education-icon {
    width: 54px;
    height: 54px;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: var(--accent-soft);
    border: 1px solid var(--border);
    color: var(--accent-2);
    font-family: "JetBrains Mono", monospace;
    font-weight: 700;
}

.education-top h3 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text);
}

.education-card > p {
    color: var(--text-muted);
    margin-bottom: 18px;
}

.certificate-link {
    display: inline-flex;
    flex-direction: column;
    align-items: flex-start;
    position: relative;
}

.certificate-image {
    display: block;
    width: 100%;
    max-width: 420px;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
    transition: transform var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.certificate-hint {
    margin-top: 10px;
    font-size: 0.8rem;
    color: var(--accent-2);
    opacity: 0;
    transform: translateY(-4px);
    transition: opacity var(--transition), transform var(--transition);
}

.certificate-link:hover .certificate-image {
    transform: translateY(-4px);
    border-color: var(--accent-2);
}

.certificate-link:hover .certificate-hint {
    opacity: 1;
    transform: translateY(0);
}

.ai-note {
    display: inline-block;
    margin-top: 22px;
    padding: 10px 14px;
    border-left: 2px solid var(--accent-2);
    background: var(--accent-soft);
    color: var(--text);
    font-size: 0.8rem;
    border-radius: 0 8px 8px 0;
}


/* =========================================
   PROJECTS
   ========================================= */

.projects-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.project-card {
    position: relative;
    display: flex;
    flex-direction: column;
    padding: 28px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    overflow: hidden;
    transition: border-color var(--transition), box-shadow var(--transition), transform 0.1s ease-out;
    transform-style: preserve-3d;
}

.project-glow {
    position: absolute;
    width: 220px;
    height: 220px;
    left: var(--x, 50%);
    top: var(--y, 50%);
    translate: -50% -50%;
    background: radial-gradient(circle, var(--accent-soft), transparent 70%);
    opacity: 0;
    transition: opacity var(--transition);
    pointer-events: none;
}

.project-card:hover .project-glow,
.education-card:hover .project-glow {
    opacity: 1;
}

.project-card:hover {
    border-color: var(--border-strong);
    box-shadow: var(--shadow-md);
}

.project-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 46px;
}

.project-number {
    color: var(--accent-2);
    font-family: "JetBrains Mono", monospace;
    font-size: 0.85rem;
}

.status-badge {
    font-size: 0.66rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    padding: 5px 10px;
    border-radius: 999px;
    border: 1px solid var(--border);
    color: var(--text-muted);
    white-space: nowrap;
}

.status-badge.status-active {
    color: var(--accent-2);
    border-color: var(--accent-soft);
    background: var(--accent-soft);
}

.project-content {
    margin-top: auto;
    position: relative;
}

.project-content h3 {
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: var(--text);
}

.project-content > p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 18px;
}

.tag-list {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.tag-list span {
    font-size: 0.72rem;
    font-weight: 500;
    padding: 5px 10px;
    border-radius: 999px;
    border: 1px solid var(--border);
    color: var(--text-muted);
    background: var(--bg-alt);
}

.project-link {
    display: inline-block;
    color: var(--accent-2);
    font-size: 0.85rem;
    font-weight: 600;
}

.project-link.disabled {
    color: var(--text-muted);
    cursor: default;
}


/* =========================================
   GOALS
   ========================================= */

.goals-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.goal-card {
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    transition: border-color var(--transition), transform var(--transition);
}

.goal-card:hover {
    border-color: var(--border-strong);
    transform: translateY(-4px);
}

.goal-number {
    color: var(--accent-2);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 16px;
}

.goal-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 10px;
}

.goal-card p {
    color: var(--text-muted);
    font-size: 0.88rem;
}


/* =========================================
   HOW I WORK
   ========================================= */

.work-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.work-card {
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
    transition: border-color var(--transition), transform var(--transition);
}

.work-card:hover {
    border-color: var(--border-strong);
    transform: translateY(-4px);
}

.work-icon {
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 14px;
    background: var(--accent-soft);
    color: var(--accent-2);
    margin-bottom: 18px;
}

.work-card h3 {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 8px;
}

.work-card p {
    color: var(--text-muted);
    font-size: 0.88rem;
}


/* =========================================
   PERSONAL DEVELOPMENT
   ========================================= */

.dev-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.dev-card {
    padding: 28px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: var(--surface);
}

.dev-card h3 {
    font-size: 1rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 16px;
}


/* =========================================
   CONTACT
   ========================================= */

.contact-section {
    text-align: center;
}

.contact-section .section-heading {
    margin-bottom: 22px;
}

.contact-text {
    max-width: 560px;
    margin: 0 auto 26px;
    color: var(--text-muted);
}

.contact-meta {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.contact-meta div {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.contact-meta span {
    color: var(--text-muted);
    font-size: 0.72rem;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.contact-meta strong {
    color: var(--text);
    font-weight: 600;
}


/* =========================================
   FOOTER
   ========================================= */

.footer {
    position: relative;
    z-index: 2;
    border-top: 1px solid var(--border);
    background: var(--bg);
}

.footer-content {
    min-height: 120px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 30px;
    flex-wrap: wrap;
    padding: 40px 0;
}

.footer strong {
    font-size: 1rem;
    color: var(--text);
    letter-spacing: -0.01em;
}

.footer p {
    color: var(--text-muted);
    font-size: 0.8rem;
}

.footer-links {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

.footer-links a {
    color: var(--text-muted);
    font-size: 0.8rem;
    transition: color var(--transition);
}

.footer-links a:hover {
    color: var(--accent-2);
}

.footer-bottom {
    padding: 18px 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
    border-top: 1px solid var(--border);
}

.footer-bottom-row {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 8px;
}

.footer-legal {
    display: flex;
    gap: 18px;
}

.footer-legal a {
    color: var(--text-muted);
    font-size: 0.78rem;
    transition: color var(--transition);
}

.footer-legal a:hover {
    color: var(--accent-2);
}


/* =========================================
   LEGAL PAGES (Impressum / Datenschutz)
   ========================================= */

:root {
    --warn: #fbbf24;
    --warn-bg: rgba(251, 191, 36, 0.14);
    --warn-border: rgba(251, 191, 36, 0.45);
}

:root[data-theme="light"] {
    --warn: #b45309;
    --warn-bg: rgba(180, 83, 9, 0.08);
    --warn-border: rgba(180, 83, 9, 0.35);
}

html[lang="en"] [data-lang-block="de"] { display: none; }
html:not([lang="en"]) [data-lang-block="en"] { display: none; }

.legal-hero,
.legal-article-section {
    position: relative;
    z-index: 2;
}

.legal-hero {
    padding: 150px 0 40px;
}

.back-link {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 26px;
    transition: color var(--transition);
}

.back-link:hover {
    color: var(--accent-2);
}

.legal-heading {
    font-size: clamp(2rem, 4vw, 2.8rem);
    font-weight: 700;
    letter-spacing: -0.01em;
    margin-bottom: 10px;
}

.legal-updated {
    color: var(--text-muted);
    font-size: 0.85rem;
}

.legal-article {
    padding: 20px 0 120px;
    max-width: 760px;
}

.legal-block {
    margin-bottom: 44px;
}

.legal-block h2 {
    font-size: 1.3rem;
    font-weight: 700;
    color: var(--text);
    margin-bottom: 14px;
}

.legal-block p {
    color: var(--text-muted);
    margin-bottom: 14px;
}

.legal-block p:last-child {
    margin-bottom: 0;
}

.legal-block address {
    font-style: normal;
    color: var(--text-muted);
    margin-bottom: 14px;
    line-height: 1.8;
}

.legal-block a.inline-link {
    color: var(--accent-2);
    font-weight: 500;
    text-decoration: underline;
    text-decoration-color: var(--border-strong);
    text-underline-offset: 3px;
}

.legal-placeholder {
    display: inline-block;
    color: var(--warn);
    background: var(--warn-bg);
    border: 1px dashed var(--warn-border);
    padding: 1px 8px;
    border-radius: 5px;
    font-weight: 600;
    font-size: 0.94em;
}


/* =========================================
   RESPONSIVE
   ========================================= */

@media (max-width: 900px) {

    .about-grid {
        grid-template-columns: 1fr;
        gap: 40px;
    }

    .about-cards {
        grid-template-columns: 1fr 1fr;
    }

    .skills-grid,
    .projects-grid,
    .goals-grid,
    .work-grid,
    .dev-grid {
        grid-template-columns: 1fr 1fr;
    }

}


@media (max-width: 760px) {

    .nav-links {
        position: fixed;
        top: 0;
        right: 0;
        height: 100vh;
        width: min(78vw, 320px);
        margin: 0;
        padding: 110px 28px 40px;
        flex-direction: column;
        gap: 4px;
        background: color-mix(in srgb, var(--bg) 92%, transparent);
        backdrop-filter: blur(20px);
        border-left: 1px solid var(--border);
        transform: translateX(100%);
        transition: transform 0.4s var(--ease);
        z-index: 999;
    }

    .nav-links.active {
        transform: translateX(0);
    }

    .nav-links li {
        padding: 0;
        border-bottom: 1px solid var(--border);
    }

    .nav-links li:last-child {
        border-bottom: 0;
    }

    .nav-links a {
        padding: 16px 0;
    }

    .menu-toggle {
        display: flex;
    }

    .mobile-break {
        display: inline;
    }

}


@media (max-width: 700px) {

    .container {
        width: min(calc(100% - 30px), var(--max-width));
    }

    .section {
        padding: 90px 0;
    }

    .hero {
        min-height: auto;
        padding-top: 140px;
        padding-bottom: 100px;
    }

    .about-cards,
    .skills-grid,
    .projects-grid,
    .goals-grid,
    .work-grid,
    .dev-grid {
        grid-template-columns: 1fr;
    }

    .contact-meta {
        gap: 20px;
    }

    .footer-content {
        align-items: flex-start;
        flex-direction: column;
    }

    .footer-bottom {
        flex-direction: column;
        gap: 8px;
    }

}


/* =========================================
   MOTION PREFERENCES
   ========================================= */

@media (prefers-reduced-motion: reduce) {

    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }

}
