:root {
    --bg: #f0f4f8;
    --surface: #ffffff;
    --text: #0f172a;
    --muted: #475569;
    --accent: #0b4f6c;
    --accent2: #145374;
    --accent-soft: #dbeafe;
    --border: #cbd5e1;
    --header-h: 72px;
    --radius: 14px;
    --shadow: 0 10px 40px rgba(15, 23, 42, 0.08);
    --font: "Outfit", system-ui, sans-serif;
}

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

html {
    scroll-behavior: smooth;
}

body.public-body {
    margin: 0;
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.6;
    min-height: 100vh;
}

.skip-link {
    position: absolute;
    left: -999px;
    top: 0;
    background: var(--accent);
    color: #fff;
    padding: 0.5rem 1rem;
    z-index: 9999;
}

.skip-link:focus {
    left: 0;
}

/* ——— Üst header ——— */
.site-header {
    position: sticky;
    top: 0;
    z-index: 800;
    background: rgba(255, 255, 255, 0.96);
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(10px);
}

.public-body.is-home .site-header--on-hero {
    position: fixed;
    left: 0;
    right: 0;
    top: 0;
    background: linear-gradient(180deg, rgba(15, 23, 42, 0.75) 0%, rgba(15, 23, 42, 0.2) 100%);
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.public-body.is-home .site-header--on-hero .site-nav a {
    color: rgba(255, 255, 255, 0.92);
}

.public-body.is-home .site-header--on-hero .site-nav a:hover,
.public-body.is-home .site-header--on-hero .site-nav a.is-active {
    color: #fff;
    background: rgba(255, 255, 255, 0.12);
}

.public-body.is-home .site-header--on-hero .site-logo-text {
    color: #fff;
}

.public-body.is-home .site-header--on-hero .site-lang__current,
.public-body.is-home .site-header--on-hero .site-lang__link {
    color: #fff;
    border-color: rgba(255, 255, 255, 0.35);
}

.site-header__inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0.65rem 1.25rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    min-height: var(--header-h);
}

.site-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    color: inherit;
    flex-shrink: 0;
}

.site-logo img {
    max-height: 48px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
}

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

.site-nav {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: flex-end;
    gap: 0.25rem;
    flex: 1;
}

.site-nav a {
    text-decoration: none;
    color: var(--muted);
    font-weight: 600;
    font-size: 0.92rem;
    padding: 0.45rem 0.65rem;
    border-radius: 10px;
    transition: background 0.2s, color 0.2s;
}

.site-nav a:hover,
.site-nav a.is-active {
    color: var(--accent);
    background: var(--accent-soft);
}

.site-lang {
    display: flex;
    align-items: center;
    gap: 0.35rem;
    flex-shrink: 0;
    margin-left: 0.25rem;
}

.site-lang__current {
    font-weight: 700;
    font-size: 0.8rem;
    padding: 0.35rem 0.5rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    color: var(--accent);
}

.site-lang__link {
    font-weight: 700;
    font-size: 0.8rem;
    padding: 0.35rem 0.5rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    text-decoration: none;
    color: var(--muted);
}

.site-lang__link:hover {
    border-color: var(--accent);
    color: var(--accent);
}

.nav-burger {
    display: none;
    margin-left: auto;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 10px;
    background: var(--accent-soft);
    cursor: pointer;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 0;
}

.nav-burger-line {
    width: 20px;
    height: 2px;
    background: var(--accent);
    border-radius: 1px;
}

.nav-backdrop {
    display: none;
    position: fixed;
    inset: 0;
    z-index: 750;
    background: rgba(15, 23, 42, 0.45);
    pointer-events: none;
}

.nav-backdrop[hidden] {
    display: none !important;
}

.public-body.nav-open .nav-backdrop {
    display: block !important;
    pointer-events: auto;
}

.page-shell {
    padding-top: 0;
}

.public-body:not(.is-home) .page-shell {
    padding-top: var(--header-h);
}

/* ——— Hero ——— */
.home-hero-stack {
    position: relative;
    width: 100%;
    height: 100vh;
    min-height: 480px;
    background: #0c1220;
}

.hero-slider {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.hero-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.7s ease;
}

.hero-slide.is-active {
    opacity: 1;
    pointer-events: auto;
}

.hero-slide-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.hero-yt-wrap {
    position: absolute;
    inset: 0;
    overflow: hidden;
}

.hero-yt-wrap iframe {
    position: absolute;
    top: 50%;
    left: 50%;
    width: 177.77vh;
    min-width: 100%;
    height: 100vh;
    min-height: 56.25vw;
    transform: translate(-50%, -50%);
    border: 0;
    pointer-events: none;
}

.hero-dots {
    position: absolute;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 0.5rem;
    z-index: 5;
}

.hero-dots button {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 0;
    background: rgba(255, 255, 255, 0.35);
    cursor: pointer;
    padding: 0;
}

.hero-dots button.is-active {
    background: #fff;
    transform: scale(1.15);
}

.home-below {
    position: relative;
    z-index: 2;
    background: var(--bg);
}

.section {
    padding: 3rem 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-head {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
}

.section-head h2 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 700;
}

.section-head a {
    color: var(--accent);
    font-weight: 600;
    text-decoration: none;
}

.section-head a:hover {
    text-decoration: underline;
}

.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 1.25rem;
}

.card {
    background: var(--surface);
    border-radius: var(--radius);
    border: 1px solid var(--border);
    overflow: hidden;
    box-shadow: var(--shadow);
    display: flex;
    flex-direction: column;
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s, box-shadow 0.2s;
}

a.card:hover {
    transform: translateY(-3px);
    box-shadow: 0 16px 48px rgba(15, 23, 42, 0.12);
}

.card-img {
    aspect-ratio: 16 / 9;
    width: 100%;
    object-fit: cover;
    background: linear-gradient(135deg, var(--accent-soft), #e2e8f0);
}

.card-body {
    padding: 1.1rem 1.2rem 1.25rem;
}

.card-body h3 {
    margin: 0 0 0.4rem;
    font-size: 1.05rem;
}

.card-body p {
    margin: 0;
    font-size: 0.92rem;
    color: var(--muted);
}

.about-teaser {
    max-width: 720px;
}

.about-teaser a.btn-inline {
    display: inline-block;
    margin-top: 0.75rem;
    font-weight: 600;
    color: var(--accent);
}

/* Video thumbs home */
.video-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

@media (max-width: 900px) {
    .video-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

.video-thumb {
    position: relative;
    border: 0;
    padding: 0;
    border-radius: var(--radius);
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 16 / 10;
    background: #0c1220;
    display: block;
    width: 100%;
}

.video-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    opacity: 0.92;
}

.video-thumb::after {
    content: "";
    position: absolute;
    inset: 0;
    margin: auto;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.92);
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M8 5v14l11-7z'/%3E%3C/svg%3E") center / 28px 28px no-repeat;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M8 5v14l11-7z'/%3E%3C/svg%3E") center / 28px 28px no-repeat;
}

/* Gallery thumbs */
.photo-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

@media (max-width: 900px) {
    .photo-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

.photo-thumb {
    border-radius: var(--radius);
    overflow: hidden;
    border: 0;
    padding: 0;
    cursor: pointer;
    aspect-ratio: 4 / 3;
    background: #e2e8f0;
}

.photo-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* About layout */
.about-layout {
    display: grid;
    grid-template-columns: 1fr 320px;
    gap: 2rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 1.5rem 3rem;
}

@media (max-width: 900px) {
    .about-layout {
        grid-template-columns: 1fr;
    }
}

.about-sidebar-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.65rem;
}

.about-sidebar-grid button {
    border: 0;
    padding: 0;
    border-radius: 10px;
    overflow: hidden;
    cursor: pointer;
    aspect-ratio: 1;
    background: #e2e8f0;
}

.about-sidebar-grid img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* Timeline references */
.ref-intro {
    max-width: 800px;
    margin: 0 auto 2rem;
    padding: 0 1.5rem;
}

.timeline {
    max-width: 880px;
    margin: 0 auto;
    padding: 0 1.5rem 3rem;
    position: relative;
}

.timeline::before {
    content: "";
    position: absolute;
    left: 1rem;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--border);
}

@media (min-width: 640px) {
    .timeline::before {
        left: 50%;
        margin-left: -1px;
    }
}

.tl-item {
    position: relative;
    margin-bottom: 2rem;
    padding-left: 3rem;
}

@media (min-width: 640px) {
    .tl-item {
        width: 50%;
        padding-left: 2.5rem;
    }
    .tl-item:nth-child(odd) {
        margin-left: 0;
        padding-right: 2.5rem;
        padding-left: 0;
        text-align: right;
    }
    .tl-item:nth-child(even) {
        margin-left: 50%;
    }
}

.tl-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.1rem 1.2rem;
    box-shadow: var(--shadow);
}

.tl-date {
    font-size: 0.8rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 0.04em;
    text-transform: uppercase;
}

.tl-code {
    font-size: 0.78rem;
    color: var(--muted);
    margin-top: 0.25rem;
}

/* Masonry gallery page */
.masonry {
    column-count: 3;
    column-gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 1.5rem 3rem;
}

@media (max-width: 900px) {
    .masonry {
        column-count: 2;
    }
}

@media (max-width: 520px) {
    .masonry {
        column-count: 1;
    }
}

.masonry-item {
    break-inside: avoid;
    margin-bottom: 1rem;
}

.masonry-item button {
    width: 100%;
    border: 0;
    padding: 0;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    display: block;
    background: #e2e8f0;
}

.masonry-item img {
    width: 100%;
    height: auto;
    vertical-align: middle;
    display: block;
}

/* Videos grid page */
.videos-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    max-width: 1100px;
    margin: 0 auto;
    padding: 1rem 1.5rem 3rem;
}

@media (max-width: 900px) {
    .videos-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 520px) {
    .videos-grid {
        grid-template-columns: 1fr;
    }
}

.video-card {
    border: 0;
    background: var(--surface);
    border-radius: var(--radius);
    overflow: hidden;
    text-align: left;
    cursor: pointer;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.video-card .thumb {
    position: relative;
    aspect-ratio: 16 / 10;
    background: #0c1220;
}

.video-card .thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.video-card .cap {
    padding: 0.65rem 0.85rem;
    font-weight: 600;
    font-size: 0.9rem;
}

.io-sentinel {
    height: 2px;
    margin: 2rem auto;
    max-width: 1200px;
}

.page-hero {
    background: linear-gradient(135deg, var(--accent-soft), var(--surface));
    border-bottom: 1px solid var(--border);
    padding: 2.5rem 1.5rem 2rem;
    max-width: 1200px;
    margin: 0 auto;
}

.page-hero h1 {
    margin: 0 0 0.5rem;
    font-size: clamp(1.75rem, 3vw, 2.25rem);
}

.page-hero p {
    margin: 0;
    color: var(--muted);
    max-width: 640px;
}

.prose {
    font-size: 1.02rem;
}

.prose p {
    margin-top: 0;
}

.detail-layout {
    max-width: 800px;
    margin: 0 auto;
    padding: 2rem 1.5rem 3rem;
}

.detail-layout img.feature {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    border-radius: var(--radius);
    margin-bottom: 1.5rem;
}

/* İletişim — form sağ, bilgi sol (grid sırası) */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
    padding: 2rem 1.5rem 3rem;
    align-items: start;
}

.contact-grid .contact-info-block {
    order: 1;
}

.contact-grid .contact-form-block {
    order: 2;
}

@media (max-width: 900px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
    .contact-grid .contact-info-block {
        order: 1;
    }
    .contact-grid .contact-form-block {
        order: 2;
    }
}

.contact-info {
    background: var(--surface);
    padding: 1.5rem;
    border-radius: var(--radius);
    border: 1px solid var(--border);
}

.contact-info h2 {
    margin-top: 0;
    font-size: 1.2rem;
}

.contact-info a {
    color: var(--accent);
}

.map-embed {
    border-radius: var(--radius);
    overflow: hidden;
    border: 1px solid var(--border);
    min-height: 280px;
    background: var(--border);
    margin-top: 1rem;
}

.map-embed iframe {
    width: 100%;
    height: 320px;
    border: 0;
    display: block;
}

.form-stack label {
    display: block;
    font-weight: 600;
    font-size: 0.9rem;
    margin-bottom: 0.35rem;
}

.form-stack input,
.form-stack textarea {
    width: 100%;
    padding: 0.65rem 0.85rem;
    border: 1px solid var(--border);
    border-radius: 10px;
    font-family: inherit;
    font-size: 1rem;
    margin-bottom: 1rem;
}

.form-stack textarea {
    min-height: 140px;
    resize: vertical;
}

.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    background: var(--accent);
    color: #fff;
    border: 0;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}

.btn:hover:not(:disabled) {
    background: var(--accent2);
}

.btn:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.contact-gate-wrap {
    margin: 1.25rem 0 1rem;
    padding: 1rem 1.1rem;
    background: var(--accent-soft);
    border: 1px solid var(--border);
    border-radius: var(--radius);
}

.contact-gate-title {
    margin: 0 0 0.35rem;
    font-size: 1rem;
    font-weight: 700;
}

.contact-gate-hint {
    margin: 0 0 0.85rem;
    font-size: 0.88rem;
    color: var(--muted);
}

.contact-slider-track {
    position: relative;
    height: 52px;
    border-radius: 999px;
    background: #e2e8f0;
    border: 1px solid var(--border);
    overflow: hidden;
    user-select: none;
    touch-action: none;
}

.contact-slider-track.is-complete {
    border-color: rgba(11, 79, 108, 0.45);
}

.contact-slider-fill {
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 0;
    max-width: 100%;
    background: linear-gradient(90deg, var(--accent-soft), rgba(11, 79, 108, 0.25));
    border-radius: 999px 0 0 999px;
    pointer-events: none;
    z-index: 0;
}

.contact-slider-hint {
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--muted);
    pointer-events: none;
    z-index: 1;
    padding-left: 52px;
}

.contact-slider-thumb {
    position: absolute;
    top: 50%;
    left: 6px;
    margin-top: -22px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 2px solid #fff;
    background: linear-gradient(160deg, #e0f2fe, #7dd3fc);
    z-index: 2;
    cursor: grab;
    padding: 0;
    touch-action: none;
    transition: left 0.28s cubic-bezier(0.34, 1.2, 0.64, 1);
}

.contact-slider-thumb.is-dragging {
    cursor: grabbing;
    transition: none;
}

.contact-slider-thumb.is-snapping {
    transition: left 0.32s cubic-bezier(0.34, 1.4, 0.64, 1);
}

.contact-slider-thumb.is-complete {
    background: linear-gradient(160deg, #0b4f6c, #082f45);
    cursor: default;
    pointer-events: none;
}

.contact-gate-status {
    margin: 0.65rem 0 0;
    font-size: 0.85rem;
    color: var(--muted);
}

.alert {
    padding: 0.85rem 1rem;
    border-radius: 10px;
    margin-bottom: 1rem;
}

.alert-success {
    background: var(--accent-soft);
    color: var(--accent);
}

.alert-error {
    background: #ffe8e8;
    color: #a32020;
}

.muted {
    color: var(--muted);
}

/* Lightbox — kapalıyken kesinlikle tıklanamaz; açıkken flex */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 2000;
    background: rgba(15, 23, 42, 0.88);
    align-items: center;
    justify-content: center;
    padding: 1rem;
}

.lightbox[hidden] {
    display: none !important;
    pointer-events: none !important;
}

.lightbox:not([hidden]) {
    display: flex;
}

.lightbox__img {
    position: relative;
    z-index: 1;
    max-width: min(96vw, 1200px);
    max-height: 90vh;
    border-radius: 12px;
    object-fit: contain;
}

.lightbox__close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    z-index: 4;
    width: 44px;
    height: 44px;
    border: 0;
    border-radius: 50%;
    background: #fff;
    font-size: 1.75rem;
    line-height: 1;
    cursor: pointer;
}

/* Video modal */
.video-modal {
    position: fixed;
    inset: 0;
    z-index: 1900;
}

.video-modal[hidden] {
    display: none !important;
    pointer-events: none !important;
}

.video-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.82);
}

.video-modal__dialog {
    position: absolute;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    width: min(96vw, 960px);
    background: #000;
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
}

.video-modal__close {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    z-index: 2;
    width: 40px;
    height: 40px;
    border: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.95);
    font-size: 1.5rem;
    cursor: pointer;
    line-height: 1;
}

.video-modal__frame {
    position: relative;
    aspect-ratio: 16 / 9;
}

.video-modal__frame iframe {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    border: 0;
}

.site-footer {
    border-top: 1px solid var(--border);
    background: var(--surface);
    padding: 2rem 1.5rem;
    margin-top: 2rem;
}

.site-footer__inner {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    justify-content: space-between;
    align-items: flex-start;
}

.site-footer__copy {
    display: block;
    font-size: 0.85rem;
    color: var(--muted);
    margin-top: 0.35rem;
}

.site-footer__contact {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    font-size: 0.92rem;
}

.footer-k {
    font-weight: 700;
    color: var(--accent);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
}

.whatsapp-float {
    position: fixed;
    right: 1.25rem;
    bottom: 1.25rem;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: #25d366;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.45);
    z-index: 200;
}

@media (max-width: 900px) {
    .nav-burger {
        display: flex;
    }

    .site-nav {
        position: fixed;
        top: var(--header-h);
        right: 0;
        bottom: 0;
        width: min(100%, 380px);
        background: var(--surface);
        flex-direction: column;
        align-items: stretch;
        padding: 1rem 1.25rem;
        box-shadow: -8px 0 32px rgba(15, 23, 42, 0.12);
        transform: translateX(100%);
        visibility: hidden;
        pointer-events: none;
        transition: transform 0.3s ease, visibility 0.3s;
        z-index: 800;
        overflow-y: auto;
    }

    .public-body.nav-open .site-nav {
        transform: translateX(0);
        visibility: visible;
        pointer-events: auto;
    }

    .site-lang {
        margin-left: 0;
    }

    .site-header__inner {
        flex-wrap: wrap;
    }

    .home-hero-stack {
        height: min(100vh, 720px);
    }
}
