/* ==========================================================================
   Main CSS - Kodeks Egitim Rehberi
   ========================================================================== */

/* Header */
.site-header {
    background-color: var(--bg);
    border-bottom: 1px solid var(--border);
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: var(--shadow);
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem 0;
    gap: 1.5rem;
}

.site-branding .site-title-link {
    text-decoration: none;
}

.site-branding .site-title {
    font-size: 1.375rem;
    font-weight: 800;
    color: var(--primary);
    white-space: nowrap;
}

.site-logo img {
    max-height: 50px;
    width: auto;
}

/* Navigation */
.main-navigation .primary-menu {
    display: flex;
    gap: 0.25rem;
    list-style: none;
    margin: 0;
    padding: 0;
}

.main-navigation .primary-menu li {
    position: relative;
}

.main-navigation .primary-menu a,
.main-navigation .primary-menu .kodeks-nav-link {
    display: block;
    padding: 0.5rem 1rem;
    color: var(--text);
    font-weight: 500;
    font-size: 0.9375rem;
    border-radius: var(--radius);
    transition: var(--transition);
    text-decoration: none;
}

.main-navigation .primary-menu a:hover,
.main-navigation .primary-menu .current-menu-item > a {
    color: var(--primary);
    background-color: var(--bg-light);
}

/* Submenu */
.kodeks-submenu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 0.5rem;
    z-index: 100;
    list-style: none;
}

.main-navigation .primary-menu li:hover > .kodeks-submenu {
    display: block;
}

.kodeks-submenu a {
    padding: 0.5rem 0.75rem !important;
    font-size: 0.875rem !important;
}

/* Header actions */
.header-actions {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.header-search-btn svg {
    flex-shrink: 0;
}

/* Mobile menu toggle */
.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
    width: 44px;
    height: 44px;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
}

.hamburger-line {
    display: block;
    width: 24px;
    height: 2px;
    background-color: var(--text);
    border-radius: 2px;
    transition: var(--transition);
}

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(1) {
    transform: rotate(45deg) translate(5px, 5px);
}

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

.mobile-menu-toggle[aria-expanded="true"] .hamburger-line:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -5px);
}

/* Mobile menu overlay */
.mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 9999;
}

.mobile-menu-overlay.active {
    display: block;
}

.mobile-menu-inner {
    position: absolute;
    right: 0;
    top: 0;
    width: 300px;
    max-width: 85%;
    height: 100%;
    background: var(--bg);
    padding: 1.5rem;
    overflow-y: auto;
    box-shadow: var(--shadow-lg);
}

.mobile-menu-close {
    position: absolute;
    top: 1rem;
    right: 1rem;
    background: none;
    border: none;
    font-size: 1.75rem;
    cursor: pointer;
    color: var(--text);
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.mobile-menu {
    list-style: none;
    padding: 2rem 0 0;
    margin: 0;
}

.mobile-menu li {
    border-bottom: 1px solid var(--border-light);
}

.mobile-menu a {
    display: block;
    padding: 0.875rem 0;
    color: var(--text);
    font-weight: 500;
    font-size: 1rem;
}

/* Hero Section */
.kodeks-hero {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 50%, var(--secondary) 100%);
    padding: 5rem 0;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.kodeks-hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.05'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    margin: 0 auto;
}

.hero-title {
    font-size: 2.75rem;
    font-weight: 800;
    color: #fff;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.hero-subtitle {
    font-size: 1.25rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 2.5rem;
    line-height: 1.6;
}

/* Hero Search */
.kodeks-hero-search {
    max-width: 700px;
    margin: 0 auto;
}

.kodeks-hero-search .search-fields {
    display: flex;
    gap: 0.75rem;
    background: var(--bg);
    padding: 0.5rem;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.kodeks-hero-search .hero-select {
    flex: 1;
    border: 1px solid var(--border-light);
    background: var(--bg);
    padding: 0.875rem 1rem;
    border-radius: var(--radius);
    font-size: 0.9375rem;
    color: var(--text);
    appearance: auto;
}

.kodeks-hero-search .kodeks-btn {
    white-space: nowrap;
    flex-shrink: 0;
}

/* Sections */
.section-title {
    text-align: center;
    margin-bottom: 2.5rem;
    font-size: 2rem;
    color: var(--text);
}

.section-cta {
    text-align: center;
    margin-top: 2rem;
}

/* How It Works */
.kodeks-how-it-works {
    padding: 5rem 0;
    background-color: var(--bg);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.step-card {
    text-align: center;
    padding: 2rem 1.5rem;
    border-radius: var(--radius-lg);
    background: var(--bg);
    border: 1px solid var(--border-light);
    transition: var(--transition);
    position: relative;
}

.step-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.step-icon {
    margin-bottom: 1rem;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary);
    color: #fff;
    font-weight: 700;
    font-size: 0.875rem;
    margin-bottom: 0.75rem;
}

.step-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.step-card p {
    color: var(--text-light);
    font-size: 0.9375rem;
    line-height: 1.6;
}

/* Featured Section */
.kodeks-featured-section {
    padding: 5rem 0;
    background-color: var(--bg-light);
}

/* Cities Section */
.kodeks-cities-section {
    padding: 5rem 0;
    background-color: var(--bg);
}

.kodeks-city-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1.25rem;
}

.kodeks-city-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 2rem 1.5rem;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    text-decoration: none;
    transition: var(--transition);
    text-align: center;
}

.kodeks-city-card:hover {
    border-color: var(--primary);
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.kodeks-city-card h3 {
    font-size: 1.125rem;
    color: var(--text);
    margin-bottom: 0.25rem;
}

.kodeks-city-card .city-count,
.kodeks-city-card .count {
    font-size: 0.875rem;
    color: var(--text-light);
}

/* Stats Section */
.kodeks-stats-section {
    padding: 4rem 0;
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
    color: #fff;
}

.stats-grid {
    display: flex;
    justify-content: center;
    gap: 4rem;
    text-align: center;
}

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.stat-number {
    font-size: 3rem;
    font-weight: 800;
    line-height: 1;
}

.stat-suffix {
    font-size: 2rem;
    font-weight: 700;
    opacity: 0.8;
}

.stat-label {
    font-size: 1rem;
    opacity: 0.9;
    margin-top: 0.5rem;
}

/* Recent Section */
.kodeks-recent-section {
    padding: 5rem 0;
    background-color: var(--bg-light);
}

/* CTA Section */
.kodeks-cta-section {
    padding: 5rem 0;
    background: var(--bg);
    border-top: 1px solid var(--border);
}

.cta-content {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
}

.cta-content h2 {
    margin-bottom: 0.75rem;
}

.cta-content p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    font-size: 1.0625rem;
}

/* Footer */
.site-footer {
    background-color: var(--bg-dark);
    color: #cbd5e0;
}

.footer-main {
    padding: 4rem 0 2rem;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr 1fr;
    gap: 2.5rem;
}

.footer-about .footer-title {
    color: #fff;
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.footer-about .footer-logo img {
    max-height: 40px;
    margin-bottom: 0.75rem;
    filter: brightness(0) invert(1);
}

.footer-description {
    font-size: 0.9375rem;
    line-height: 1.6;
    margin-bottom: 1rem;
}

.footer-social {
    display: flex;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.social-link {
    display: inline-flex;
    padding: 0.375rem 0.75rem;
    background: rgba(255, 255, 255, 0.1);
    border-radius: var(--radius);
    color: #cbd5e0;
    font-size: 0.8125rem;
    transition: var(--transition);
    text-decoration: none;
}

.social-link:hover {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}

.footer-col .widget-title {
    color: #fff;
    font-size: 1rem;
    margin-bottom: 1rem;
}

.footer-menu {
    list-style: none;
    padding: 0;
    margin: 0;
}

.footer-menu li {
    margin-bottom: 0.5rem;
}

.footer-menu a {
    color: #a0aec0;
    font-size: 0.9375rem;
    transition: var(--transition);
    text-decoration: none;
}

.footer-menu a:hover {
    color: #fff;
}

.footer-bottom {
    padding: 1.5rem 0;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.copyright {
    font-size: 0.875rem;
    color: #718096;
    text-align: center;
}

/* Sticky Bar (mobile) */
.kodeks-sticky-bar {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 999;
    background: var(--bg);
    border-top: 1px solid var(--border);
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
    padding: 0.5rem;
    gap: 0.5rem;
}

.sticky-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.75rem;
    border-radius: var(--radius);
    font-weight: 600;
    font-size: 0.9375rem;
    text-decoration: none;
    min-height: 44px;
}

.sticky-phone {
    background: var(--primary);
    color: #fff;
}

.sticky-whatsapp {
    background: #25d366;
    color: #fff;
}

/* Compare Bar */
.kodeks-compare-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--bg-dark);
    color: #fff;
    padding: 0.75rem 0;
    z-index: 998;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.2);
}

.kodeks-compare-bar .kodeks-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1rem;
}

.compare-count {
    font-weight: 700;
    font-size: 1.125rem;
}

/* Breadcrumbs */
.kodeks-breadcrumbs {
    padding: 1rem 0;
    font-size: 0.875rem;
}

.kodeks-breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    list-style: none;
    padding: 0;
    margin: 0;
}

.kodeks-breadcrumbs li {
    display: inline-flex;
    align-items: center;
}

.kodeks-breadcrumbs .separator {
    color: var(--text-lighter);
    margin: 0 0.25rem;
}

.kodeks-breadcrumbs a {
    color: var(--text-light);
    text-decoration: none;
}

.kodeks-breadcrumbs a:hover {
    color: var(--primary);
}

/* 404 */
.kodeks-404 {
    text-align: center;
    padding: 5rem 0;
}

.kodeks-404 h1 {
    font-size: 8rem;
    font-weight: 800;
    color: var(--border);
    line-height: 1;
}

.kodeks-404 h2 {
    margin-bottom: 0.75rem;
}

.kodeks-404 p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}

.kodeks-404-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Content Layout */
.content-sidebar-layout {
    display: grid;
    grid-template-columns: 1fr 300px;
    gap: 2rem;
    padding: 2rem 0;
}

.content-area {
    padding: 2rem 0;
}

.entry-header {
    margin-bottom: 1.5rem;
}

.entry-content {
    line-height: 1.8;
}

.entry-content p {
    margin-bottom: 1rem;
}

.entry-content h2 {
    margin-top: 2rem;
    margin-bottom: 1rem;
}

.entry-content h3 {
    margin-top: 1.5rem;
    margin-bottom: 0.75rem;
}

/* Pagination */
.kodeks-pagination,
.nav-links {
    display: flex;
    justify-content: center;
    gap: 0.25rem;
    margin-top: 2rem;
    padding: 1rem 0;
}

.page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 40px;
    height: 40px;
    padding: 0 0.75rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    color: var(--text);
    font-weight: 500;
    font-size: 0.875rem;
    text-decoration: none;
    transition: var(--transition);
}

.page-numbers:hover {
    border-color: var(--primary);
    color: var(--primary);
}

.page-numbers.current {
    background: var(--primary);
    border-color: var(--primary);
    color: #fff;
}

/* WordPress Admin Bar Spacing */
.admin-bar .site-header {
    top: 32px;
}

/* No Results */
.kodeks-no-results {
    text-align: center;
    padding: 4rem 2rem;
}

.kodeks-no-results h3 {
    margin: 1rem 0 0.5rem;
}

.kodeks-no-results p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
}
