/* --- GLOBAL VARIABLES --- */
:root {
    --primary-color: #2f855a;
    --primary-dark: #225f40;
    --accent-color: #e53e3e;
    /* Kırmızı vurgu */
    --text-dark: #2d3748;
    --text-light: #718096;
    --bg-light: #f7fafc;
    --header-bg: rgba(255, 255, 255, 0.98);
    --header-text: #2d3748;
    --topbar-bg: #1a202c;
    --topbar-text: #e2e8f0;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-lg: 0 10px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

/* --- RESET & BASE --- */
body {
    font-family: 'Open Sans', sans-serif;
    margin: 0;
    margin-top: 110px; /* Sabit başlık için boşluk */
    background: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
}

h1,
h2,
h3,
h4,
.logo,
.card-btn,
.top-bar,
blockquote {
    font-family: 'Montserrat', sans-serif;
}

a {
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

/* --- HEADER & NAVIGATION --- */
.header-container {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 1000;
    transition: all 0.3s ease;
    box-shadow: 0 2px 20px rgba(0, 0, 0, 0.08);
}

.top-bar {
    background: var(--topbar-bg);
    color: var(--topbar-text);
    text-align: center;
    padding: 8px 0;
    font-size: 0.8rem;
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: all 0.3s ease;
    height: auto;
    overflow: hidden;
}

.navbar {
    background: var(--header-bg);
    backdrop-filter: blur(10px);
    color: var(--header-text);
    padding: 0 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 80px;
    transition: all 0.3s ease;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
}

.navbar .logo {
    font-size: 1.5rem;
    font-weight: 800;
    color: var(--primary-color);
    letter-spacing: -0.5px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-links {
    display: flex;
    align-items: center;
}

.nav-links a {
    color: #4a5568;
    margin-left: 30px;
    font-weight: 600;
    font-size: 0.95rem;
    position: relative;
    padding: 5px 0;
}

.nav-links a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s;
}

.nav-links a:hover::after,
.nav-links a.active::after {
    width: 100%;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary-color);
}

/* Scrolled Header State */
.header-scrolled .top-bar {
    height: 0;
    padding: 0;
    opacity: 0;
}

.header-scrolled .navbar {
    height: 60px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* Scroll Progress Bar */
.scroll-progress-container {
    position: fixed;
    top: 80px;
    left: 0;
    width: 100%;
    height: 3px;
    background: transparent;
    z-index: 999;
    display: none;
    transition: top 0.3s ease;
}

.scroll-progress-bar {
    height: 100%;
    background: var(--primary-color);
    width: 0%;
    transition: width 0.1s;
}

.header-scrolled+.scroll-progress-container {
    top: 60px;
}

/* Dropdown */
.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown-toggle {
    cursor: pointer;
}

.dropdown-menu {
    display: none;
    position: absolute;
    background-color: #f9f9f9;
    min-width: 160px;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    z-index: 1;
}

.dropdown-menu a {
    color: black;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
}

.dropdown-menu a:hover {
    background-color: #f1f1f1;
}

.dropdown:hover .dropdown-menu {
    display: block;
}


/* --- HERO SECTIONS --- */
.hero-section {
    background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)), url('https://images.unsplash.com/photo-1506484381205-f7945653044d?auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    color: white;
    text-align: center;
    padding: 140px 20px;
    margin-bottom: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-content h1 {
    font-size: 3.5rem;
    margin: 0 0 20px 0;
    text-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    letter-spacing: -1px;
}

.hero-content p {
    font-size: 1.3rem;
    max-width: 650px;
    margin: 0 auto;
    opacity: 0.9;
    font-weight: 400;
}

/* Page Specific Headers (Article Pages) */
.page-header {
    background: linear-gradient(135deg, var(--primary-dark), var(--primary-color));
    color: white;
    padding: 80px 20px 120px;
    text-align: center;
    clip-path: polygon(0 0, 100% 0, 100% 85%, 50% 100%, 0 85%);
}

.page-header h1 {
    margin: 0 0 15px 0;
    font-size: 2.8rem;
    letter-spacing: -1px;
    text-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
}

.page-header p {
    font-size: 1.2rem;
    opacity: 0.9;
    max-width: 700px;
    margin: 0 auto;
    font-weight: 400;
}

/* About Hero */
.about-hero {
    text-align: center;
    padding: 60px 20px;
    background: white;
    margin-bottom: 40px;
}

.about-hero h1 {
    font-size: 2.5rem;
    color: var(--primary-dark);
    margin-bottom: 15px;
}

.about-hero p {
    max-width: 600px;
    margin: 0 auto;
    font-size: 1.1rem;
    color: #718096;
}


/* --- LAYOUT & CONTAINERS --- */
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.content-container {
    /* For Articles */
    max-width: 800px;
    margin: -100px auto 60px;
    background: white;
    padding: 50px;
    box-shadow: var(--shadow-lg);
    border-radius: 20px;
    position: relative;
    z-index: 10;
}

/* --- COMPONENTS: CARDS --- */
.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 40px;
    margin-bottom: 60px;
}

.blog-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    flex-direction: column;
    border: 1px solid rgba(0, 0, 0, 0.05);
    opacity: 0;
    transform: translateY(30px);
    position: relative;
    cursor: pointer;
}

.blog-card.is-visible {
    opacity: 1;
    transform: translateY(0);
}

.blog-card:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: var(--shadow-lg);
}

.card-img-wrap {
    overflow: hidden;
    height: 220px;
    position: relative;
}

.card-img {
    height: 100%;
    width: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.blog-card:hover .card-img {
    transform: scale(1.1);
}

.card-body {
    padding: 25px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    position: relative;
}

.card-category {
    color: var(--accent-color);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 10px;
    display: inline-block;
}

.card-title {
    font-size: 1.4rem;
    margin: 0 0 15px 0;
    color: var(--text-dark);
    line-height: 1.3;
}

.card-desc {
    color: var(--text-light);
    font-size: 0.95rem;
    margin-bottom: 25px;
    flex-grow: 1;
}

.card-btn {
    display: inline-flex;
    align-items: center;
    color: var(--primary-color);
    font-weight: 700;
    font-size: 0.9rem;
}

.card-btn i {
    margin-left: 8px;
    transition: margin 0.3s;
}

.card-btn:hover i {
    margin-left: 12px;
}

.stretched-link::after {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 1;
    content: "";
}

/* Category Cards */
.cat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.cat-card {
    position: relative;
    height: 250px;
    border-radius: 15px;
    overflow: hidden;
    cursor: pointer;
    transition: transform 0.4s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.cat-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.cat-bg {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.cat-card:hover .cat-bg {
    transform: scale(1.1);
}

.cat-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0.1));
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    padding: 25px;
    box-sizing: border-box;
}

.cat-title {
    color: white;
    font-size: 1.5rem;
    margin: 0;
}

.cat-count {
    color: #ffd700;
    font-size: 0.9rem;
    font-weight: 600;
    margin-bottom: 5px;
}


/* --- COMPONENTS: UI ELEMENTS --- */
.section-title {
    text-align: center;
    color: var(--primary-dark);
    margin-bottom: 40px;
    font-size: 2.2rem;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 3px;
    background: var(--accent-color);
    margin: 15px auto 0;
}

.search-container {
    max-width: 600px;
    margin: -30px auto 40px;
    position: relative;
    z-index: 10;
    padding: 0 20px;
}

.search-input {
    width: 100%;
    padding: 15px 25px;
    border-radius: 30px;
    border: none;
    box-shadow: var(--shadow-lg);
    font-size: 1rem;
    outline: none;
    transition: box-shadow 0.3s;
    font-family: inherit;
}

.search-input:focus {
    box-shadow: 0 10px 30px -5px rgba(47, 133, 90, 0.3);
}

.btn-primary {
    background: var(--primary-color);
    color: white;
    padding: 12px 35px;
    border-radius: 30px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(47, 133, 90, 0.3);
    transition: all 0.3s;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(47, 133, 90, 0.4);
}

.hero-img {
    width: 100%;
    border-radius: 12px;
    margin-bottom: 40px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* --- PAGE SPECIFIC: ABOUT --- */
.story-section {
    max-width: 1000px;
    margin: 40px auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
    padding: 0 20px;
}

.story-img {
    width: 100%;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.story-content h2 {
    color: var(--primary-color);
    font-size: 2rem;
    margin-bottom: 20px;
}

.stats-container {
    background: var(--primary-dark);
    color: white;
    padding: 60px 20px;
    margin-top: 60px;
}

.stats-grid {
    max-width: 1000px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    text-align: center;
    gap: 20px;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: #ffd700;
    display: block;
    margin-bottom: 5px;
    font-family: 'Montserrat';
}

/* --- PAGE SPECIFIC: CONTACT --- */
.contact-container {
    max-width: 900px;
    margin: 50px auto;
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 40px;
    padding: 0 20px;
}

.contact-info {
    background: var(--primary-dark);
    color: white;
    padding: 40px;
    border-radius: 15px;
}

.contact-form {
    background: white;
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.05);
}

.form-group {
    margin-bottom: 20px;
}

.form-control {
    width: 100%;
    padding: 12px;
    border: 1px solid #cbd5e0;
    border-radius: 8px;
    font-family: inherit;
    box-sizing: border-box;
}

.btn-submit {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 700;
    width: 100%;
}

/* --- PAGE SPECIFIC: THE JOKE / SCIENTIFIC --- */
.highlight-box {
    background: #fff5f5;
    border-left: 5px solid #e53e3e;
    padding: 20px;
    margin: 30px 0;
    font-size: 1.1rem;
}

.scientific-section {
    background: #2d3748;
    color: #fff;
    padding: 40px;
    margin: 40px -50px;
    position: relative;
    border-radius: 10px;
}

.scientific-section h2 {
    color: #63b3ed;
    border-bottom: 2px solid #63b3ed;
    padding-bottom: 10px;
    display: inline-block;
}

.secret-code {
    font-family: 'Courier New', monospace;
    color: #48bb78;
}

/* --- FOOTER --- */
.main-footer {
    background: #1a202c;
    color: #a0aec0;
    padding: 70px 20px 30px;
    margin-top: 60px;
}

.footer-content {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 50px;
    margin-bottom: 50px;
}

.footer-section h3 {
    color: white;
    margin-bottom: 20px;
}

.footer-bottom {
    text-align: center;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {

    .story-section,
    .contact-container,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .scientific-section {
        margin: 40px 0;
    }

    .content-container {
        padding: 30px;
        margin-top: -50px;
    }

    .navbar {
        padding: 0 20px;
    }

    .nav-links {
        display: none;
        /* Basitlik için mobil menü gizlendi, istenirse eklenebilir */
    }
}