/*
Theme Name: WBHaber
Theme URI: https://github.com/wphaber/wbhaber
Author: Senior WordPress Theme Developer
Author URI: https://wphaber.com
Description: 2026 standartlarında, ultra hızlı, SEO odaklı, premium ve minimalist WordPress haber teması.
Version: 1.0.0
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: wbhaber
Domain Path: /languages
Tags: news, blog, two-columns, responsive-layout, custom-colors, custom-menu, featured-images, translation-ready

This theme, like WordPress, is licensed under the GPL.
Use it to make something cool.
*/

/* ----------------------------------------------------
   1. GLOBAL VARIABLES & CSS CUSTOM PROPERTIES
---------------------------------------------------- */
:root {
  --color-primary: #D32F2F;
  --color-primary-hover: #B71C1C;
  --color-secondary: #1A237E;
  --color-secondary-hover: #0D1B60;
  --color-accent: #FFC107;
  
  --color-bg: #FAFAFA;
  --color-bg-card: #FFFFFF;
  --color-border: #E0E0E0;
  --color-text-primary: #212121;
  --color-text-secondary: #616161;
  --color-text-light: #9E9E9E;
  
  --glass-bg: rgba(255, 255, 255, 0.75);
  --glass-border: rgba(224, 224, 224, 0.5);
  --glass-blur: 12px;

  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  --font-title: 'Outfit', sans-serif;
  --font-serif: 'Merriweather', Georgia, serif;

  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.12);
  
  --radius-sm: 6px;
  --radius-md: 12px;
  --radius-lg: 20px;
  
  --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme='dark'] {
  --color-bg: #0C0F12;
  --color-bg-card: #15191E;
  --color-border: #232A32;
  --color-text-primary: #F3F4F6;
  --color-text-secondary: #9CA3AF;
  --color-text-light: #6B7280;

  --glass-bg: rgba(21, 25, 30, 0.8);
  --glass-border: rgba(35, 42, 50, 0.5);
  
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
  --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.3);
  --shadow-lg: 0 16px 40px rgba(0, 0, 0, 0.4);
}

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

body {
  background-color: var(--color-bg);
  color: var(--color-text-primary);
  font-family: var(--font-sans);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  line-height: 1.6;
  transition: background-color 0.3s ease, color 0.3s ease;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition-smooth);
}

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

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* ----------------------------------------------------
   2. ACCESSIBILITY & UTILITIES (WCAG 2.1 AA)
---------------------------------------------------- */
.screen-reader-text {
  border: 0;
  clip: rect(1px, 1px, 1px, 1px);
  clip-path: inset(50%);
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute !important;
  width: 1px;
  word-wrap: normal !important;
}

.skip-link:focus {
  background-color: var(--color-primary);
  border-radius: var(--radius-sm);
  clip: auto !important;
  clip-path: none;
  color: #ffffff;
  display: block;
  font-size: 0.9rem;
  font-weight: 800;
  height: auto;
  left: 10px;
  line-height: normal;
  padding: 12px 20px;
  position: fixed !important;
  top: 10px;
  width: auto;
  z-index: 100000;
  box-shadow: var(--shadow-lg);
  outline: 3px solid #FFF;
}

/* Accessibility Focus Ring */
:focus-visible {
  outline: 3px solid var(--color-primary);
  outline-offset: 3px;
}

/* Touch Targets for Mobile Ergonomics */
.wbh-mobile-cat-pill,
.sp-sticky-btn,
.sp-share-btn,
.theme-toggle,
.search-toggle-btn,
.hamburger-btn {
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

/* Mobile Ergonomics & Touch Optimizations */
@media (max-width: 768px) {
  body {
    -webkit-tap-highlight-color: transparent;
  }
}

/* 4 Kolonlu Kategori Grid Yapısı (Son 4 Haber İçin) */
.grid-layout-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-top: 16px;
}

@media (max-width: 1024px) {
  .grid-layout-4 {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}

@media (max-width: 640px) {
  .grid-layout-4 {
    grid-template-columns: 1fr;
    gap: 14px;
  }
}
