/* Global Styles */
:root {
    --primary-color: #5d1118;
    /* Richer Burgundy */
    --primary-light: #8e1f29;
    --secondary-color: #c5a028;
    /* Polished Gold */
    --accent-color: #bfa13a;
    --text-color: #1a1a1a;
    --bg-color: #fdfcf9;
    /* Elegant Cream */
    --light-bg: #f8f9fa;
    --dark-bg: #1a1a1a;
    --font-heading: 'Cinzel', serif;
    --font-body: 'Inter', sans-serif;
    --transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    --glass: rgba(255, 255, 255, 0.8);
    --shadow-premium: 0 10px 30px -10px rgba(0, 0, 0, 0.1);
}

html {
    scroll-behavior: smooth;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-color);
    color: var(--text-color);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    display: block;
}

.container {
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 40px;
}

.section {
    padding: 100px 0;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 3rem;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 2rem;
    position: relative;
    padding-bottom: 1.5rem;
    font-weight: 700;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 2px;
    background: linear-gradient(90deg, transparent, var(--secondary-color), transparent);
}

.section-subtitle {
    text-align: center;
    margin-bottom: 4rem;
    color: #666;
    font-size: 1.1rem;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
    font-weight: 300;
}

.btn {
    display: inline-block;
    padding: 14px 36px;
    font-weight: 600;
    border-radius: 2px;
    cursor: pointer;
    text-align: center;
    letter-spacing: 1px;
    text-transform: uppercase;
    font-size: 0.85rem;
    transition: var(--transition);
}

.btn-gold {
    background-color: var(--secondary-color);
    color: #fff;
    box-shadow: 0 4px 15px rgba(197, 160, 40, 0.2);
}

.btn-gold:hover {
    background-color: var(--accent-color);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(197, 160, 40, 0.3);
}

.btn-dark {
    background-color: var(--primary-color);
    color: #fff;
}

.btn-dark:hover {
    background-color: var(--primary-light);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(93, 17, 24, 0.3);
}

.btn-outline {
    border: 1px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: #fff;
    transform: translateY(-2px);
}

/* Header */
.header {
    background-color: var(--glass);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: var(--transition);
}

.header.scrolled {
    background-color: #fff;
    height: 80px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 90px;
    transition: var(--transition);
}

.header.scrolled .header-container {
    height: 80px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 15px;
}

.logo-icon {
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-icon img {
    height: 100%;
    width: auto;
}

.logo-text {
    font-family: var(--font-heading);
    color: var(--primary-color);
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.1;
    letter-spacing: 0.5px;
}

.logo-text small {
    font-family: var(--font-body);
    font-size: 0.75rem;
    color: #777;
    font-weight: 400;
    text-transform: uppercase;
    letter-spacing: 1.5px;
}

.nav-list {
    display: flex;
    gap: 35px;
}

.nav-list a {
    font-weight: 600;
    font-size: 0.85rem;
    color: #1a1a1a;
    position: relative;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.nav-list a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--secondary-color);
    transition: var(--transition);
}

.nav-list a:hover {
    color: var(--primary-color);
}

.nav-list a:hover::after {
    width: 100%;
}

.hamburger {
    display: none;
    flex-direction: column;
    gap: 6px;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 2px;
    background-color: var(--primary-color);
    transition: var(--transition);
}

/* Language Switcher */
.nav {
    display: flex;
    align-items: center;
    gap: 20px;
}

.lang-switcher {
    display: flex;
    align-items: center;
    gap: 6px;
    border-left: 1px solid rgba(0, 0, 0, 0.1);
    padding-left: 20px;
    margin-left: 5px;
}

.lang-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 3px;
    border-radius: 4px;
    opacity: 0.45;
    transition: var(--transition);
    display: flex;
    align-items: center;
    gap: 6px;
    line-height: 1;
}

.lang-btn:hover {
    opacity: 1;
    transform: scale(1.1);
}

.lang-btn.active {
    opacity: 1;
    outline: 2px solid var(--secondary-color);
    outline-offset: 2px;
    border-radius: 4px;
}

.flag-img {
    width: 26px;
    height: auto;
    border-radius: 2px;
    display: block;
}

/* Mobile Menu */
.mobile-menu {
    position: fixed;
    top: 90px;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: #fff;
    padding: 40px 20px;
    transform: translateX(100%);
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
    z-index: 999;
    overflow-y: auto;
}

.mobile-menu.active {
    transform: translateX(0);
}

.mobile-nav-list {
    display: flex;
    flex-direction: column;
    gap: 25px;
    text-align: center;
}

.mobile-nav-list a {
    font-size: 1.3rem;
    font-family: var(--font-heading);
    color: var(--primary-color);
}

.mobile-lang-switcher {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-top: 40px;
    padding-top: 30px;
    border-top: 1px solid #eee;
}

.mobile-lang-switcher .lang-btn {
    flex-direction: column;
    gap: 6px;
    padding: 10px 16px;
    border-radius: 8px;
    background: #f7f5f0;
    font-size: 0.8rem;
    font-family: var(--font-body);
    color: #555;
    font-weight: 600;
    opacity: 0.6;
}

.mobile-lang-switcher .lang-btn.active {
    opacity: 1;
    background: #fff;
    box-shadow: 0 4px 15px rgba(93, 17, 24, 0.1);
    outline: 2px solid var(--secondary-color);
    color: var(--primary-color);
}

.mobile-lang-switcher .flag-img {
    width: 34px;
    border-radius: 3px;
}

/* Hero Section */
.hero {
    height: 100vh;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: #fff;
    margin-top: -90px;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 900px;
    padding: 0 20px;
}

.hero-content h1 {
    font-family: var(--font-heading);
    font-size: 4rem;
    margin-bottom: 1.5rem;
    line-height: 1.1;
    text-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.hero-content p {
    font-size: 1.3rem;
    margin-bottom: 2.5rem;
    opacity: 0.95;
    font-weight: 300;
    letter-spacing: 2px;
    text-transform: uppercase;
}

/* History Section */
.history {
    background-color: #fff;
}

.history-content {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 80px;
    align-items: center;
}

.history-text p {
    margin-bottom: 1.8rem;
    color: #333;
    font-size: 1.1rem;
    line-height: 1.8;
}

.history-text strong {
    color: var(--primary-color);
    font-weight: 700;
}

.history-image {
    position: relative;
}

.history-image::before {
    content: '';
    position: absolute;
    top: -15px;
    left: -15px;
    width: 100%;
    height: 100%;
    border: 1px solid var(--secondary-color);
    z-index: 0;
}

.history-image img {
    position: relative;
    z-index: 1;
    box-shadow: var(--shadow-premium);
}

/* School Section */
.school {
    background-color: #f7f5f0;
}

.school-card {
    display: flex;
    background: #fff;
    overflow: hidden;
    box-shadow: var(--shadow-premium);
    transition: var(--transition);
}

.school-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.school-info {
    flex: 1.2;
    padding: 70px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.school-info h2 {
    text-align: left;
    margin-bottom: 2rem;
}

.school-info h2::after {
    left: 0;
    transform: none;
    margin-left: 0;
}

.school-text h3 {
    font-family: var(--font-heading);
    color: var(--primary-color);
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    border-left: 3px solid var(--secondary-color);
    padding-left: 15px;
}

.school-text p {
    margin-bottom: 1.2rem;
    color: #444;
    font-size: 1.05rem;
    line-height: 1.8;
}

.school-image-container {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
    padding: 20px;
    background-color: #fcfbf7;
    align-items: center;
}

.school-main-image {
    width: 100%;
}

.school-main-image img {
    width: 100%;
    height: auto;
    object-fit: contain;
}

.school-gallery img {
    width: 100%;
    aspect-ratio: 16/10;
    object-fit: cover;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    transition: var(--transition);
}

.school-gallery {
    display: flex;
    flex-direction: column;
    gap: 20px;
    width: 100%;
}

.school-gallery img:hover {
    transform: scale(1.02);
}

/* Board Section */
.board-single-container {
    background: #fff;
    overflow: hidden;
    box-shadow: var(--shadow-premium);
    max-width: 1160px;
    margin: 0 auto;
    transition: var(--transition);
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.board-single-container:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.1);
}

.board-photo img {
    width: 100%;
    height: auto;
}

.board-names {
    padding: 50px;
    text-align: center;
}

.board-names h3 {
    font-family: var(--font-heading);
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 1.6rem;
    letter-spacing: 1px;
}

.board-names p {
    color: #555;
    font-size: 1rem;
    line-height: 2;
    max-width: 700px;
    margin: 0 auto;
}

/* Calendar Section */
.calendar {
    background-color: #f7f5f0;
}

.calendar-container {
    background: #fff;
    padding: 20px;
    box-shadow: var(--shadow-premium);
    border-radius: 4px;
    overflow: hidden;
}

/* Instagram Section */
.instagram {
    background-color: #fff;
}

.instagram-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.ig-item {
    aspect-ratio: 1;
    overflow: hidden;
    position: relative;
    cursor: pointer;
}

.ig-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.ig-item::after {
    content: '👁️';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(93, 17, 24, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-size: 1.5rem;
    opacity: 0;
    transition: var(--transition);
}

.ig-item:hover img {
    transform: scale(1.1);
}

.ig-item:hover::after {
    opacity: 1;
}

/* Donation Section */
.donation {
    background-color: #f7f5f0;
}

.donation-card {
    background: #fff;
    padding: 60px;
    max-width: 1160px;
    margin: 0 auto;
    box-shadow: var(--shadow-premium);
    border-top: 4px solid var(--primary-color);
    transition: var(--transition);
}

.donation-card:hover {
    transform: translateY(-5px);
}

.bank-details {
    background: #fdfcf9;
    padding: 30px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    margin-top: 20px;
}

.bank-details p {
    margin-bottom: 12px;
}

.bank-details strong {
    color: var(--primary-color);
    display: inline-block;
    width: 100px;
}

/* Footer */
.footer {
    background-color: var(--dark-bg);
    color: #fff;
    padding: 80px 0 30px;
}

.footer-brand {
    margin-bottom: 50px;
}

.footer-logo-text {
    color: #fff !important;
}

.footer-logo-text small {
    color: #bbb !important;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    margin-bottom: 50px;
    align-items: start;
}

.footer-info h3 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    margin-bottom: 30px;
    color: var(--secondary-color);
    letter-spacing: 1px;
}

.footer-info p {
    margin-bottom: 15px;
    color: #bbb;
    display: flex;
    align-items: center;
    gap: 12px;
}

.footer-info a:hover {
    color: var(--secondary-color);
}

.footer-map {
    border: 1px solid #333;
    overflow: hidden;
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid #333;
    padding-top: 30px;
    font-size: 0.85rem;
    color: #666;
    letter-spacing: 1px;
    text-transform: uppercase;
}

/* Animations Logic */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}

.animate-on-scroll.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 1001;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.back-to-top.show {
    opacity: 1;
    visibility: visible;
}

/* Responsive */
@media (max-width: 1024px) {
    .container {
        padding: 0 30px;
    }

    .hero-content h1 {
        font-size: 3.2rem;
    }
}

@media (max-width: 768px) {

    /* === Global === */
    body {
        line-height: 1.6;
        overflow-x: hidden;
    }

    * {
        overflow-wrap: break-word;
        word-break: break-word;
    }

    .container {
        padding: 0 16px;
    }

    .section {
        padding: 50px 0;
    }

    /* === Header === */
    .header-container {
        height: 70px;
        gap: 10px;
    }

    .logo-icon {
        width: 38px;
        height: 38px;
        flex-shrink: 0;
    }

    /* Hide subtitle "Ermeni Kilisesi Vakfı" on mobile — saves space */
    .logo-text small {
        display: none;
    }

    .logo-text {
        font-size: 0.95rem;
        line-height: 1.2;
    }

    /* Nav: hide desktop list & lang switcher, show hamburger */
    .nav-list {
        display: none;
    }

    .lang-switcher {
        display: none;
    }

    .hamburger {
        display: flex;
        flex-shrink: 0;
    }

    /* Mobile menu opens from top 70px */
    .mobile-menu {
        top: 70px;
    }

    /* === Hero === */
    .hero {
        height: 80vh;
        margin-top: -70px;
        background-attachment: scroll;
    }

    .hero-content h1 {
        font-size: 1.7rem;
        line-height: 1.25;
    }

    .hero-content p {
        font-size: 0.85rem;
        letter-spacing: 0.5px;
    }

    /* === Section Titles === */
    .section-title {
        font-size: 1.6rem;
        margin-bottom: 1.2rem;
        /* Prevent cut-off on narrow screens */
        overflow-wrap: break-word;
        word-break: break-word;
        hyphens: auto;
    }

    .section-subtitle {
        margin-bottom: 2rem;
        font-size: 0.95rem;
    }

    /* === History === */
    .history-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .history-text p {
        font-size: 0.95rem;
        margin-bottom: 1rem;
    }

    /* === School === */
    .school-card {
        flex-direction: column;
    }

    .school-info {
        padding: 30px 16px;
    }

    .school-image-container {
        padding: 12px;
    }

    .school-text p {
        font-size: 0.95rem;
    }

    /* === Board === */
    .board-names {
        padding: 25px 16px;
    }

    .board-names p {
        line-height: 1.7;
        font-size: 0.9rem;
    }

    /* === Donation === */
    .donation-card {
        padding: 30px 16px;
    }

    .bank-details {
        padding: 16px 12px;
    }

    /* Fix: label on its own line above value */
    .bank-details p {
        display: flex;
        flex-direction: column;
        gap: 2px;
        margin-bottom: 14px;
    }

    .bank-details strong {
        width: auto;
        display: block;
        font-size: 0.8rem;
        text-transform: uppercase;
        letter-spacing: 0.5px;
        color: var(--primary-color);
    }

    /* === Footer === */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 480px) {
    .container {
        padding: 0 14px;
    }

    .section-title {
        font-size: 1.4rem;
    }

    .hero-content h1 {
        font-size: 1.4rem;
    }

    .hero-content p {
        font-size: 0.8rem;
    }

    .logo-icon {
        width: 34px;
        height: 34px;
    }

    .logo-text {
        font-size: 0.85rem;
    }

    .board-names h3 {
        font-size: 1.1rem;
    }

    .board-names p {
        font-size: 0.85rem;
    }

    .school-info {
        padding: 25px 14px;
    }

    .mobile-lang-switcher {
        gap: 10px;
    }

    .mobile-lang-switcher .lang-btn {
        padding: 8px 12px;
        font-size: 0.75rem;
    }

    .mobile-lang-switcher .flag-img {
        width: 28px;
    }
}