/*
Theme Name: Football.ge Theme
Theme URI: https://football.ge
Author: Antigravity AI
Author URI: https://football.ge
Description: პრემიუმ ხარისხის, თანამედროვე და დინამიკური WordPress თემა საფეხბურთო ბლოგისთვის Dark/Light რეჟიმებით, მწვანე და ყვითელი ფერების ჰარმონიული კომბინაციით.
Version: 1.0.0
Text Domain: footballge
*/

@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;500;600;700;800&family=Plus+Jakarta+Sans:wght@400;500;600;700;800&display=swap');

:root {
  /* Clean Scandinavian Editorial Light Mode Tokens */
  --bg-primary: #ffffff;
  --bg-secondary: #f6f6f8;
  --bg-glass: rgba(255, 255, 255, 0.96);
  --text-primary: #111113;
  --text-secondary: #55555e;
  --text-muted: #888893;
  
  /* Scandinavian Forest & Slate Accents */
  --accent-green: #1a5c48;
  --accent-green-light: #24755c;
  --accent-green-gradient: linear-gradient(135deg, #1a5c48 0%, #134636 100%);
  --accent-gold: #d44c4c;
  --accent-gold-hover: #e65c5c;
  --accent-gold-gradient: linear-gradient(135deg, #d44c4c 0%, #e65c5c 100%);
  
  --border-color: #e8e8ed;
  --border-dark: #111113;
  --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
  --card-shadow-hover: 0 16px 36px rgba(0, 0, 0, 0.08);
  
  --transition-smooth: all 0.3s cubic-bezier(0.2, 0.8, 0.2, 1);
  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
}

[data-theme="dark"] {
  /* Clean Scandinavian Editorial Dark Mode Tokens */
  --bg-primary: #0e0e11;
  --bg-secondary: #16161b;
  --bg-glass: rgba(14, 14, 17, 0.96);
  --text-primary: #f2f2f5;
  --text-secondary: #a0a0ad;
  --text-muted: #6e6e78;
  
  --accent-green: #349b7c;
  --accent-green-light: #41b592;
  --accent-green-gradient: linear-gradient(135deg, #287a61 0%, #349b7c 100%);
  --accent-gold: #e56363;
  --accent-gold-hover: #f07878;
  
  --border-color: #22222a;
  --border-dark: #f2f2f5;
  --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.4);
  --card-shadow-hover: 0 16px 36px rgba(0, 0, 0, 0.6);
}

/* Base Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html, body {
  font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
  background-color: var(--bg-primary);
  background-image: none;
  color: var(--text-primary);
  line-height: 1.7;
  transition: background-color 0.4s ease, color 0.4s ease;
  overflow-x: hidden;
}

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

ul {
  list-style: none;
}

.container {
  max-width: 1280px;
  margin: 0 auto;
  padding: 0 24px;
}

.main-content {
  padding-top: 48px;
}

/* Authentic Broadsheet Newspaper Masthead */
.newspaper-masthead {
  background: var(--bg-primary);
  border-bottom: 3px double var(--border-dark);
  padding-top: 10px;
}

/* Original Modern Glassmorphic Site Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--bg-glass);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition-smooth);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 84px;
  padding-top: 12px;
  padding-bottom: 12px;
  gap: 20px;
}

.logo-group {
  display: flex;
  flex-direction: column;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
}

.logo span:first-child {
  font-family: 'Plus Jakarta Sans', 'Outfit', sans-serif;
  font-size: 28px;
  font-weight: 800;
  letter-spacing: -0.8px;
  color: var(--text-primary);
  line-height: 1.1;
}

.logo-dot {
  color: var(--accent-green) !important;
}

.logo-badge {
  background: var(--accent-green-gradient);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 8px rgba(26, 92, 72, 0.2);
}

.logo-tagline {
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-top: 4px;
}

/* Theme Toggle Switch */
.theme-toggle-wrapper {
  display: flex;
  align-items: center;
}

.theme-toggle-btn {
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--card-shadow);
  transition: var(--transition-smooth);
  position: relative;
  overflow: hidden;
}

.theme-toggle-btn:hover {
  transform: translateY(-2px);
  border-color: var(--accent-gold);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.2);
}

.theme-toggle-btn svg {
  width: 22px;
  height: 22px;
  transition: transform 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

[data-theme="dark"] .sun-icon {
  display: block;
}

[data-theme="dark"] .moon-icon {
  display: none;
}

[data-theme="light"] .sun-icon, :root:not([data-theme="dark"]) .sun-icon {
  display: none;
}

[data-theme="light"] .moon-icon, :root:not([data-theme="dark"]) .moon-icon {
  display: block;
}

/* Hero Section */
.hero-section {
  padding: 48px 0;
}

.hero-card {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  box-shadow: var(--card-shadow);
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  min-height: 460px;
}

.hero-image-wrapper {
  position: relative;
  overflow: hidden;
  background: #1e293b;
}

.hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.7s ease;
}

.hero-card:hover .hero-image {
  transform: scale(1.05);
}

.hero-badge {
  position: absolute;
  top: 24px;
  left: 24px;
  background: var(--accent-gold);
  color: #000;
  font-weight: 700;
  font-size: 12px;
  padding: 6px 14px;
  border-radius: 30px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
  z-index: 2;
}

.hero-content {
  padding: 48px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.meta-info {
  display: flex;
  align-items: center;
  gap: 16px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 16px;
  font-weight: 500;
}

.meta-info span {
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-title {
  font-size: 34px;
  font-weight: 800;
  line-height: 1.3;
  margin-bottom: 16px;
  color: var(--text-primary);
}

.hero-title a:hover {
  color: var(--accent-green);
}

.hero-excerpt {
  color: var(--text-secondary);
  font-size: 16px;
  margin-bottom: 32px;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--accent-green-gradient);
  color: #ffffff;
  font-weight: 600;
  font-size: 15px;
  padding: 14px 28px;
  border-radius: var(--radius-sm);
  box-shadow: 0 4px 15px rgba(10, 92, 54, 0.3);
  width: fit-content;
  transition: var(--transition-smooth);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(10, 92, 54, 0.4);
  color: #fff;
}

.btn-primary svg {
  transition: transform 0.3s ease;
}

.btn-primary:hover svg {
  transform: translateX(4px);
}

/* Articles Grid Section */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--border-color);
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-title::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 24px;
  background: var(--accent-gold);
  border-radius: 4px;
}

/* Authentic Broadsheet Front Page Layout */
/* Clean Scandinavian Editorial Grid & Layout */
.scandi-editorial-container {
  max-width: 1160px;
  margin: 40px auto 80px auto;
}

.scandi-hero-card {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 48px;
  align-items: center;
  background: var(--bg-primary);
  margin-bottom: 56px;
}

.scandi-hero-img-wrapper {
  position: relative;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--card-shadow);
}

.scandi-hero-img {
  width: 100%;
  height: auto;
  min-height: 380px;
  object-fit: cover;
  display: block;
  transition: transform 0.6s ease;
}

.scandi-hero-card:hover .scandi-hero-img {
  transform: scale(1.03);
}

.scandi-hero-badge {
  position: absolute;
  top: 20px;
  left: 20px;
  background: var(--bg-glass);
  color: var(--accent-green);
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  font-weight: 700;
  padding: 6px 14px;
  border-radius: 30px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.08);
}

.scandi-hero-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.scandi-meta {
  display: flex;
  gap: 16px;
  font-family: 'Outfit', sans-serif;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
  margin-bottom: 14px;
}

.scandi-hero-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 38px;
  font-weight: 800;
  line-height: 1.25;
  margin: 0 0 16px 0;
  letter-spacing: -0.5px;
}

.scandi-hero-title a:hover {
  color: var(--accent-green);
}

.scandi-hero-excerpt {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.scandi-read-more {
  font-family: 'Outfit', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--accent-green);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: var(--transition-smooth);
}

.scandi-read-more:hover {
  gap: 10px;
  color: var(--accent-green-light);
}

.scandi-divider {
  border: 0;
  border-top: 1px solid var(--border-color);
  margin: 48px 0;
}

/* Secondary Multi-Column Grid */
.scandi-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 36px;
}

.scandi-card {
  display: flex;
  flex-direction: column;
  background: var(--bg-primary);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: var(--transition-smooth);
}

.scandi-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--card-shadow-hover);
  border-color: transparent;
}

.scandi-card-img-wrapper {
  position: relative;
  width: 100%;
  height: 260px;
  overflow: hidden;
  background: var(--bg-secondary);
}

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

.scandi-card:hover .scandi-card-img {
  transform: scale(1.05);
}

.scandi-card-body {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.scandi-card-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.35;
  margin: 0 0 12px 0;
}

.scandi-card-title a:hover {
  color: var(--accent-green);
}

.scandi-card-excerpt {
  font-size: 14px;
  line-height: 1.65;
  color: var(--text-secondary);
  margin-bottom: 20px;
  flex-grow: 1;
}

.scandi-card-meta {
  font-family: 'Outfit', sans-serif;
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  border-top: 1px solid var(--border-color);
  padding-top: 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

/* Single Post Page */
.single-post-header {
  max-width: 860px;
  margin: 40px auto 24px auto;
  text-align: center;
}

.single-title {
  font-family: 'Plus Jakarta Sans', sans-serif;
  font-size: 44px;
  font-weight: 900;
  line-height: 1.25;
  margin: 20px 0;
  color: var(--text-primary);
}

.single-thumb {
  max-width: 1000px;
  margin: 0 auto 40px auto;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--card-shadow);
  border: 1px solid var(--border-color);
  background: var(--bg-secondary);
}

.single-thumb img {
  width: 100%;
  height: auto;
  max-height: 750px;
  object-fit: contain;
  display: block;
  margin: 0 auto;
}

.single-thumb-caption,
.wp-caption-text,
.wp-element-caption {
  font-size: 14.5px;
  color: var(--text-muted);
  padding: 14px 20px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  text-align: center;
  font-style: italic;
  margin: 0;
}

.single-content {
  max-width: 800px;
  margin: 0 auto 60px auto;
  font-size: 18px;
  line-height: 1.8;
  color: var(--text-secondary);
  background: var(--bg-secondary);
  padding: 48px;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  box-shadow: var(--card-shadow);
}

.single-content p {
  margin-bottom: 24px;
}

.single-content h2, .single-content h3 {
  color: var(--text-primary);
  margin: 36px 0 16px 0;
  font-weight: 700;
}

.single-content blockquote {
  border-left: 4px solid var(--accent-gold);
  padding: 16px 24px;
  margin: 32px 0;
  background: rgba(245, 158, 11, 0.05);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--text-primary);
  font-weight: 500;
}

/* Footer */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 48px 0 24px 0;
  margin-top: 64px;
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 32px;
  margin-bottom: 32px;
}

.footer-text {
  color: var(--text-muted);
  font-size: 14px;
  max-width: 400px;
}

/* Footer Tags Cloud */
.footer-tags-wrapper {
  max-width: 420px;
}
.footer-tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}
.footer-tag-item {
  display: inline-block;
  padding: 6px 14px;
  background: var(--bg-primary);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  font-size: 13px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s ease;
}
.footer-tag-item:hover {
  background: rgba(10, 126, 60, 0.12);
  color: var(--accent-green);
  border-color: var(--accent-green);
  transform: translateY(-2px);
}

.footer-bottom {
  text-align: center;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 13px;
}

/* Post & Card Tags */
.post-tags-container {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.tags-label {
  font-weight: 700;
  color: var(--text-color);
  font-size: 14px;
  margin-right: 4px;
}
.tag-pill {
  display: inline-block;
  background: var(--bg-body);
  color: var(--text-color);
  border: 1px solid var(--border-color);
  padding: 6px 14px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.3s ease;
}
.tag-pill:hover {
  background: var(--accent-green);
  color: #ffffff;
  border-color: var(--accent-green);
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(10,126,60,0.2);
}
.card-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
  margin-bottom: 18px;
}
.card-tag-pill {
  display: inline-block;
  background: var(--bg-body);
  color: var(--text-muted);
  border: 1px solid var(--border-color);
  padding: 3px 10px;
  border-radius: 14px;
  font-size: 11px;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
}
.card-tag-pill:hover {
  background: var(--accent-gold);
  color: #000000;
  border-color: var(--accent-gold);
}

/* Reading Progress Bar */
.reading-progress-bar {
  position: fixed;
  top: 0;
  left: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--accent-green), var(--accent-gold));
  width: 0%;
  z-index: 99999;
  transition: width 0.1s ease;
  box-shadow: 0 2px 8px rgba(250, 204, 21, 0.4);
}

/* Share Buttons */
.share-section {
  margin-top: 32px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}
.share-title {
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--text-color);
}
.share-buttons-wrapper {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}
.share-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  border: 1px solid var(--border-color);
  background: var(--bg-body);
  color: var(--text-color);
  cursor: pointer;
  transition: all 0.2s ease;
}
.share-btn:hover {
  background: var(--accent-green);
  color: #fff;
  border-color: var(--accent-green);
  transform: translateY(-2px);
}
.share-btn.fb:hover { background: #1877f2; border-color: #1877f2; }
.share-btn.tw:hover { background: #000000; color: #fff; border-color: #000000; }
.share-btn.tg:hover { background: #0088cc; border-color: #0088cc; }

/* Related Stories */
.related-section {
  max-width: 800px;
  margin: 40px auto 40px auto;
}
.related-header-title {
  font-size: 22px;
  font-weight: 800;
  margin-bottom: 20px;
  border-left: 4px solid var(--accent-gold);
  padding-left: 12px;
}
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 20px;
}
.related-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.related-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 10px 20px rgba(0,0,0,0.15);
}
.related-thumb {
  height: 140px;
  overflow: hidden;
}
.related-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.related-content {
  padding: 16px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.related-title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.4;
  margin-bottom: 8px;
}
.related-title a {
  color: var(--text-color);
  text-decoration: none;
}
.related-title a:hover {
  color: var(--accent-green);
}

/* Live Search Modal Overlay */
.search-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.65);
  backdrop-filter: blur(8px);
  z-index: 100000;
  display: flex;
  justify-content: center;
  align-items: flex-start;
  padding-top: 100px;
}
.search-modal-box {
  background: var(--bg-secondary);
  border: 2px solid var(--border-color);
  width: 90%;
  max-width: 650px;
  border-radius: 16px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  overflow: hidden;
  animation: modalFadeIn 0.25s ease;
  color: var(--text-primary);
}
@keyframes modalFadeIn {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}
.search-modal-header {
  display: flex;
  align-items: center;
  padding: 16px 20px;
  background: var(--bg-primary);
}
#searchInput {
  flex: 1;
  background: var(--bg-secondary);
  border: 1px solid var(--border-color);
  padding: 12px 16px;
  border-radius: 10px;
  font-size: 16px;
  color: var(--text-primary);
  outline: none;
  transition: border-color 0.2s ease;
}
#searchInput:focus {
  border-color: var(--accent-green);
}
#searchInput::placeholder {
  color: var(--text-muted);
}
.close-search-btn {
  background: transparent;
  border: none;
  font-size: 28px;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0 0 0 16px;
  line-height: 1;
}
.close-search-btn:hover {
  color: var(--text-primary);
}
.search-results-list {
  max-height: 400px;
  overflow-y: auto;
  padding: 16px 20px;
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
}
.search-results-list:empty {
  display: none;
  padding: 0;
  border: none;
}
.search-initial-msg {
  color: var(--text-muted);
  font-size: 15px;
  text-align: center;
  padding: 24px 0;
  font-weight: 500;
}
.search-result-item {
  display: block;
  padding: 14px;
  border-radius: 10px;
  text-decoration: none;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-color);
  transition: all 0.2s ease;
  margin-bottom: 8px;
  background: var(--bg-primary);
}
.search-result-item:last-child {
  margin-bottom: 0;
}
.search-result-item:hover {
  background: rgba(10, 126, 60, 0.1);
  transform: translateX(4px);
  border-color: var(--accent-green);
}
.search-result-title {
  font-weight: 700;
  font-size: 16px;
  margin-bottom: 4px;
  color: var(--text-primary);
}
.search-result-meta {
  font-size: 12px;
  color: var(--text-muted);
}

/* Scroll to Top Button */
.scroll-to-top-btn {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 48px;
  height: 48px;
  background: var(--accent-green);
  color: #ffffff;
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.3);
  cursor: pointer;
  z-index: 999;
  opacity: 0;
  visibility: hidden;
  transform: translateY(16px);
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}
.scroll-to-top-btn.show {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
.scroll-to-top-btn:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(10, 126, 60, 0.5);
  background: #0d9648;
  color: #ffffff;
}

/* Responsive */
@media (max-width: 992px) {
  .hero-card {
    grid-template-columns: 1fr;
  }
  .hero-image-wrapper {
    min-height: 260px;
  }
  .hero-content {
    padding: 32px;
  }
  .hero-title {
    font-size: 28px;
  }
}

@media (max-width: 850px) {
  .scandi-hero-card {
    grid-template-columns: 1fr;
    gap: 24px;
  }
  .scandi-hero-img {
    min-height: 260px;
  }
  .scandi-grid {
    grid-template-columns: 1fr;
    gap: 28px;
  }
}

@media (max-width: 850px) {
  .header-inner {
    flex-direction: row;
    justify-content: space-between;
    align-items: center;
    min-height: 70px;
    padding-top: 10px;
    padding-bottom: 10px;
  }
  .logo-badge,
  .hide-on-mobile {
    display: none !important;
  }
}

@media (max-width: 768px) {
  .container {
    padding: 0 16px;
  }
  .logo span:first-child {
    font-size: 22px;
  }
  .logo-tagline {
    font-size: 11px;
    margin-top: 2px;
  }
  .scandi-hero-title {
    font-size: 28px;
  }
  .single-title {
    font-size: 28px;
  }
  .single-thumb {
    border-radius: var(--radius-md);
    margin-bottom: 24px;
  }
  .single-thumb img {
    height: auto;
    max-height: none;
  }
  .single-content {
    padding: 0;
    background: transparent;
    border: none;
    box-shadow: none;
    font-size: 16px;
    line-height: 1.75;
  }
  .scroll-to-top-btn {
    bottom: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
  }
}

/* ==========================================================================
   2-Column Main Page Layout & "On This Day" History Sidebar / Mobile Card
   ========================================================================== */
.main-page-wrapper {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 36px;
  align-items: start;
  margin-top: 20px;
  margin-bottom: 50px;
}

/* Fix news grid alignment so it aligns perfectly with top of sidebar */
.main-articles-column .scandi-editorial-container {
  margin-top: 0 !important;
}

.history-sidebar-widget {
  position: sticky;
  top: 90px;
  border-radius: var(--radius-lg);
}

.history-widget-card {
  background: var(--card-bg);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.3s ease, border-color 0.3s ease;
  position: relative;
  overflow: hidden;
}
.history-widget-card:hover {
  box-shadow: var(--shadow-md);
  border-color: rgba(26, 92, 72, 0.3);
}

/* Decorative top accent border */
.history-widget-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  background: var(--accent-green-gradient);
}

.history-widget-header {
  display: block;
  text-align: center;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-color);
}

.history-badge-wrapper.history-badge-full {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  width: 100%;
  background: rgba(26, 92, 72, 0.1);
  color: var(--accent-green);
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 15px;
  font-weight: 800;
  margin-bottom: 10px;
}
[data-theme="dark"] .history-badge-wrapper.history-badge-full {
  background: rgba(36, 117, 92, 0.25);
  color: #5edbaf;
}

.history-widget-icon {
  font-size: 16px;
}

.history-date-wrapper {
  display: flex;
  justify-content: center;
  width: 100%;
}

.history-widget-date {
  font-size: 13.5px;
  font-weight: 800;
  color: var(--accent-gold);
  background: rgba(212, 76, 76, 0.12);
  padding: 4px 14px;
  border-radius: 16px;
  display: inline-block;
}

.history-event-item {
  margin-bottom: 18px;
}
.history-event-divider {
  padding-top: 18px;
  border-top: 1px dashed var(--border-color);
}

.history-event-header-row {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.history-event-year {
  font-size: 12px;
  font-weight: 800;
  color: var(--accent-gold);
  background: rgba(212, 76, 76, 0.1);
  padding: 2px 8px;
  border-radius: 10px;
  white-space: nowrap;
}

.history-event-title {
  font-size: 16px;
  font-weight: 700;
  line-height: 1.35;
  color: var(--text-primary);
  margin: 0;
  font-family: 'Outfit', sans-serif;
}

.history-widget-thumb {
  margin-bottom: 12px;
  border-radius: var(--radius-md);
  overflow: hidden;
  height: 160px;
}
.history-widget-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.history-widget-card:hover .history-widget-thumb img {
  transform: scale(1.04);
}

.history-event-text {
  font-size: 14px;
  line-height: 1.6;
  color: var(--text-secondary);
}
.history-event-text p {
  margin-bottom: 10px;
}
.history-event-text p:last-child {
  margin-bottom: 0;
}

/* Hide toggle button on desktop because desktop sidebar scrolls comfortably */
.history-toggle-btn {
  display: none;
}

/* ==========================================================================
   Responsive: Mobile (< 992px) -> Top Compact Card with Read More
   ========================================================================== */
@media (max-width: 991px) {
  .main-page-wrapper {
    display: flex;
    flex-direction: column;
    gap: 28px;
  }

  /* Move history card ABOVE the main articles on mobile! */
  .history-sidebar-widget {
    order: -1;
    position: static;
    max-height: none;
    width: 100%;
    overflow: visible;
  }

  .history-widget-thumb {
    height: 180px;
  }

  /* Collapsed state on mobile */
  .history-widget-body.collapsed {
    max-height: 130px;
    overflow: hidden;
    position: relative;
  }

  .history-widget-body.collapsed .history-fade-mask {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(to bottom, rgba(255, 255, 255, 0) 0%, var(--card-bg) 100%);
    pointer-events: none;
  }
  [data-theme="dark"] .history-widget-body.collapsed .history-fade-mask {
    background: linear-gradient(to bottom, rgba(22, 22, 25, 0) 0%, var(--card-bg) 100%);
  }

  /* Expanded state on mobile */
  .history-widget-body.expanded {
    max-height: 4000px;
    transition: max-height 0.5s ease-in-out;
  }
  .history-widget-body.expanded .history-fade-mask {
    display: none;
  }

  .history-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    margin-top: 16px;
    padding: 12px;
    background: var(--bg-secondary);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    color: var(--accent-green);
    font-weight: 700;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.25s ease;
  }
  [data-theme="dark"] .history-toggle-btn {
    color: #5edbaf;
  }
  .history-toggle-btn:hover {
    background: var(--accent-green);
    color: #ffffff !important;
    border-color: var(--accent-green);
  }
}

