/*
Theme Name: Niki Cafe Editorial News
Theme URI: https://niki.cafe
Description: "Cafe Newsroom" bilingual (BG/EN) digital newsroom theme for Niki Cafe (niki.cafe). Warm sunlit European cafe crossed with a modern financial terminal.
Version: 2.0.0
Author: Niki Cafe Editorial Team
*/

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,600;0,700;1,600&family=Inter:wght@400;500;600;700&family=JetBrains+Mono:wght@400;500&family=Playfair+Display:ital,wght@0,600;0,700;0,800;1,600&display=swap');

:root {
  /* Light Mode: Sunlit European Cafe */
  --nc-bg: #FAF6F0;                /* Warm Parchment */
  --nc-paper: #FFFFFF;             /* Crisp Paper Card */
  --nc-card: #FFFFFF;
  --nc-elevated: #F3ECE1;          /* Steamed Oat Milk */
  --nc-ink: #1E140C;               /* Dark Espresso Ink */
  --nc-ink-light: #5A4638;         /* Medium Roast */
  --nc-ink-muted: #8C7664;         /* Cinnamon Dust */
  --nc-espresso: #20150E;          /* Deep Espresso Bar */
  --nc-crema: #D99B52;             /* Golden Crema */
  --nc-roast: #C86D28;             /* Sunlit Amber / Roast */
  --nc-wood: #6E3B1E;              /* Classic Mahogany Wood */
  --nc-botanical: #2E6F40;         /* Botanical Cafe Green */
  --nc-border: rgba(30, 20, 12, 0.11);
  --nc-border-strong: rgba(30, 20, 12, 0.22);

  /* Tablet-on-Wooden-Table Soft Warm Shadows */
  --nc-shadow-card:
    0 10px 25px -5px rgba(45, 25, 10, 0.08),
    0 4px 10px -2px rgba(45, 25, 10, 0.04),
    0 0 0 1px rgba(110, 59, 30, 0.06);
  --nc-shadow-hover:
    0 20px 35px -8px rgba(45, 25, 10, 0.15),
    0 8px 16px -4px rgba(45, 25, 10, 0.08),
    0 0 0 1px rgba(200, 109, 40, 0.28);

  --nc-font-serif: 'Playfair Display', 'Cormorant Garamond', Georgia, serif;
  --nc-font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --nc-font-mono: 'JetBrains Mono', monospace;
}

[data-theme="dark"] {
  /* Dark Mode: Evening Espresso Financial Terminal */
  --nc-bg: #120D0A;
  --nc-paper: #1C1410;
  --nc-card: #1F1712;
  --nc-elevated: #281E18;
  --nc-ink: #F5EFE6;
  --nc-ink-light: #C8B9A6;
  --nc-ink-muted: #8E7B68;
  --nc-espresso: #0D0907;
  --nc-crema: #E5A95E;
  --nc-roast: #E08A44;
  --nc-wood: #A6633C;
  --nc-botanical: #48A868;
  --nc-border: rgba(245, 239, 230, 0.11);
  --nc-border-strong: rgba(245, 239, 230, 0.24);
  --nc-shadow-card:
    0 12px 28px -6px rgba(0, 0, 0, 0.55),
    0 4px 12px -2px rgba(0, 0, 0, 0.35),
    0 0 0 1px rgba(245, 239, 230, 0.08);
  --nc-shadow-hover:
    0 22px 40px -8px rgba(0, 0, 0, 0.72),
    0 0 0 1px rgba(224, 138, 68, 0.38);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  padding: 0;
  background-color: var(--nc-bg);
  color: var(--nc-ink);
  font-family: var(--nc-font-sans);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  transition: background-color 0.25s ease, color 0.25s ease;
}

/* Bilingual visibility rules */
html[data-lang="bg"] [lang="en"] { display: none !important; }
html[data-lang="en"] [lang="bg"] { display: none !important; }

/* ==========================================================
   1. MORNING ESPRESSO LIVE TICKER BAR
   ========================================================== */
.nc-ticker-bar {
  background: #1A110B;
  color: #F5EFE6;
  font-size: 12.5px;
  border-bottom: 1px solid rgba(217, 155, 82, 0.25);
}
.nc-ticker-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 7px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.nc-ticker-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--nc-roast);
  color: #fff;
  font-weight: 700;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  padding: 3px 10px;
  border-radius: 999px;
  white-space: nowrap;
  flex-shrink: 0;
}
.nc-ticker-track {
  flex: 1;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
}
.nc-ticker-item {
  color: #E8DEC8;
  text-decoration: none;
  font-weight: 500;
  margin-right: 28px;
  transition: color 0.2s ease;
}
.nc-ticker-item:hover {
  color: var(--nc-crema);
}
.nc-ticker-meta {
  font-family: var(--nc-font-mono);
  font-size: 11.5px;
  color: var(--nc-crema);
  white-space: nowrap;
  flex-shrink: 0;
}

/* ==========================================================
   2. MAIN HEADER & ALIGNED TOP CATEGORY BAR
   ========================================================== */
.nc-header {
  background: var(--nc-paper);
  border-bottom: 2px solid var(--nc-wood);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 6px 24px rgba(30, 20, 12, 0.07);
}
.nc-header-inner {
  max-width: 1280px;
  margin: 0 auto;
  padding: 14px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
}
.nc-logo-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  color: var(--nc-ink);
}
.nc-logo-brand img {
  height: 64px;
  width: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--nc-crema);
  box-shadow: 0 4px 12px rgba(30, 20, 12, 0.18);
}
.nc-brand-text h1 {
  margin: 0;
  font-family: var(--nc-font-serif);
  font-size: 27px;
  font-weight: 800;
  letter-spacing: -0.5px;
  line-height: 1.1;
  color: var(--nc-ink);
}
.nc-brand-text span {
  display: block;
  margin-top: 2px;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1.6px;
  color: var(--nc-roast);
  font-weight: 700;
}

.nc-header-controls {
  display: flex;
  align-items: center;
  gap: 10px;
}
.nc-pill-btn {
  background: var(--nc-elevated);
  border: 1px solid var(--nc-border-strong);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  color: var(--nc-ink);
  transition: all 0.2s ease;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.nc-pill-btn:hover {
  background: var(--nc-roast);
  color: #fff;
  border-color: var(--nc-roast);
}

/* Aligned Top Category Navigation Bar */
.nc-category-bar {
  background: var(--nc-elevated);
  border-top: 1px solid var(--nc-border);
  padding: 10px 24px;
}
.nc-category-bar-inner,
.nc-category-menu {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}
/* Support both direct children in .nc-category-bar and nested .nc-category-menu */
nav.nc-category-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
}
.nc-cat-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 8px 18px;
  background: var(--nc-paper);
  border: 1px solid var(--nc-border-strong);
  border-radius: 999px;
  text-decoration: none;
  color: var(--nc-ink);
  font-family: var(--nc-font-sans);
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.2px;
  white-space: nowrap;
  transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 2px 5px rgba(30, 20, 12, 0.05);
}
.nc-cat-btn .nc-cat-icon {
  font-size: 15px;
  line-height: 1;
}
.nc-cat-btn:hover,
.nc-cat-btn.active {
  background: var(--nc-roast);
  color: #ffffff !important;
  border-color: var(--nc-roast);
  transform: translateY(-1px);
  box-shadow: 0 6px 14px rgba(200, 109, 40, 0.28);
}
.nc-cat-btn[data-cat="business"]:hover, .nc-cat-btn[data-cat="business"].active { background: #6E3B1E; border-color: #6E3B1E; }
.nc-cat-btn[data-cat="economics"]:hover, .nc-cat-btn[data-cat="economics"].active { background: #2E6F40; border-color: #2E6F40; }
.nc-cat-btn[data-cat="politics"]:hover, .nc-cat-btn[data-cat="politics"].active { background: #3B4F76; border-color: #3B4F76; }
.nc-cat-btn[data-cat="hardware"]:hover, .nc-cat-btn[data-cat="hardware"].active { background: #7A4928; border-color: #7A4928; }
.nc-cat-btn[data-cat="software"]:hover, .nc-cat-btn[data-cat="software"].active { background: #1F5E5B; border-color: #1F5E5B; }
.nc-cat-btn[data-cat="ai"]:hover, .nc-cat-btn[data-cat="ai"].active { background: #9B3B24; border-color: #9B3B24; }

/* ==========================================================
   3. PORTAL CONTAINER, HERO & ARCHIVE BANNERS
   ========================================================== */
.nc-portal {
  max-width: 1280px;
  margin: 0 auto;
  padding: 28px 24px 80px;
}

.nc-hero {
  background: var(--nc-paper);
  border: 1px solid var(--nc-border);
  border-radius: 16px;
  padding: 38px;
  margin-bottom: 36px;
  box-shadow: var(--nc-shadow-card);
  position: relative;
  overflow: hidden;
}
.nc-hero::before {
  content: "";
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 4px;
  background: linear-gradient(90deg, var(--nc-wood), var(--nc-roast), var(--nc-botanical));
}
.nc-hero-inner {
  display: grid;
  grid-template-columns: 1.25fr 1fr;
  gap: 36px;
  align-items: center;
}
.nc-pill {
  display: inline-block;
  background: var(--nc-elevated);
  color: var(--nc-roast);
  border: 1px solid var(--nc-border-strong);
  font-size: 11.5px;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 999px;
}
.nc-hero-title {
  font-family: var(--nc-font-serif);
  font-size: 38px;
  line-height: 1.18;
  margin: 14px 0;
  color: var(--nc-ink);
}
.nc-hero-title em {
  font-style: italic;
  color: var(--nc-roast);
}
.nc-hero-desc {
  font-size: 16px;
  color: var(--nc-ink-light);
  margin-bottom: 18px;
}
.nc-hero-art img {
  width: 100%;
  height: 310px;
  object-fit: cover;
  border-radius: 12px;
  box-shadow: var(--nc-shadow-card);
  border: 1px solid var(--nc-border);
}
.nc-sources-tagline {
  margin-top: 16px;
  padding: 12px 16px;
  background: var(--nc-elevated);
  border-left: 3px solid var(--nc-botanical);
  border-radius: 6px;
  font-size: 12.5px;
  color: var(--nc-ink-light);
}

/* Category Archive Header Banner */
.nc-archive-head {
  background: var(--nc-paper);
  border: 1px solid var(--nc-border);
  border-left: 6px solid var(--nc-roast);
  border-radius: 14px;
  padding: 28px 32px;
  margin-bottom: 28px;
  box-shadow: var(--nc-shadow-card);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 16px;
}
.nc-archive-head h1 {
  margin: 0 0 6px;
  font-family: var(--nc-font-serif);
  font-size: 32px;
  color: var(--nc-ink);
}
.nc-archive-head p {
  margin: 0;
  color: var(--nc-ink-light);
  font-size: 15px;
}
.nc-archive-count {
  background: var(--nc-elevated);
  color: var(--nc-roast);
  border: 1px solid var(--nc-border-strong);
  padding: 6px 14px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 13px;
}

/* ==========================================================
   4. STREAM FILTER TABS & TABLET-ON-WOOD NEWS CARD GRID
   ========================================================== */
.nc-region-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 14px;
  border-bottom: 1px solid var(--nc-border);
  padding-bottom: 14px;
  overflow-x: auto;
}
.nc-tab {
  background: var(--nc-paper);
  border: 1px solid var(--nc-border);
  font-size: 13.5px;
  font-weight: 700;
  padding: 8px 16px;
  cursor: pointer;
  border-radius: 8px;
  color: var(--nc-ink-light);
  white-space: nowrap;
  transition: all 0.2s ease;
}
.nc-tab:hover {
  border-color: var(--nc-roast);
  color: var(--nc-ink);
}
.nc-tab.active {
  background: var(--nc-wood);
  color: #fff;
  border-color: var(--nc-wood);
}

.nc-category-filter-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 28px;
  overflow-x: auto;
  padding-bottom: 6px;
}
.nc-cat-filter-btn {
  background: var(--nc-paper);
  border: 1px solid var(--nc-border);
  border-radius: 999px;
  padding: 7px 15px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
  color: var(--nc-ink-light);
  white-space: nowrap;
  transition: all 0.2s ease;
}
.nc-cat-filter-btn:hover {
  border-color: var(--nc-roast);
  color: var(--nc-ink);
}
.nc-cat-filter-btn.active {
  background: var(--nc-roast);
  color: #fff !important;
  border-color: var(--nc-roast);
}

/* News Card Grid */
.nc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(350px, 1fr));
  gap: 28px;
  margin-bottom: 60px;
}
.nc-card {
  background: var(--nc-card);
  border: 1px solid var(--nc-border);
  border-radius: 14px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  box-shadow: var(--nc-shadow-card);
  transition: transform 0.25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s cubic-bezier(0.16, 1, 0.3, 1);
}
.nc-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--nc-shadow-hover);
}
.nc-card-img {
  position: relative;
  height: 220px;
  background: #20150E;
  overflow: hidden;
  display: block;
}
.nc-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}
.nc-card:hover .nc-card-img img {
  transform: scale(1.04);
}
.nc-card-cat {
  position: absolute;
  top: 14px;
  left: 14px;
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 11px;
  border-radius: 6px;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.35);
}
.nc-card-vid {
  position: absolute;
  top: 14px;
  right: 14px;
  background: rgba(18, 13, 10, 0.85);
  color: #fff;
  font-size: 11px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 6px;
}
.nc-card-content {
  padding: 24px;
  display: flex;
  flex-direction: column;
  flex: 1;
}
.nc-card-meta {
  font-size: 12px;
  font-weight: 600;
  color: var(--nc-ink-muted);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.nc-card-content h3 {
  font-family: var(--nc-font-serif);
  font-size: 21px;
  font-weight: 700;
  line-height: 1.32;
  margin: 0 0 12px;
}
.nc-card-content h3 a {
  text-decoration: none;
  color: var(--nc-ink);
  transition: color 0.2s ease;
}
.nc-card-content h3 a:hover {
  color: var(--nc-roast);
}
.nc-card-excerpt {
  font-size: 14.5px;
  color: var(--nc-ink-light);
  line-height: 1.58;
  margin: 0 0 20px;
  flex: 1;
}
.nc-card-actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
  font-weight: 700;
  padding-top: 14px;
  border-top: 1px solid var(--nc-border);
}
.nc-link-read {
  color: var(--nc-roast);
  text-decoration: none;
}
.nc-link-read:hover {
  text-decoration: underline;
}
.nc-link-source {
  color: var(--nc-botanical);
  text-decoration: none;
  font-size: 12.5px;
}
.nc-link-source:hover {
  text-decoration: underline;
}

/* ==========================================================
   5. SINGLE POST FULL-IMMERSION VIEW (.nc-single)
   ========================================================== */
.nc-single {
  max-width: 920px;
  margin: 0 auto;
  padding: 36px 24px 80px;
}
.nc-article {
  background: var(--nc-paper);
  border: 1px solid var(--nc-border);
  border-radius: 16px;
  padding: 44px 48px;
  box-shadow: var(--nc-shadow-card);
}
.nc-article-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 18px;
}
.nc-article-cat {
  display: inline-block;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.7px;
  padding: 5px 14px;
  border-radius: 6px;
  text-decoration: none;
}
.nc-article-title {
  font-family: var(--nc-font-serif);
  font-size: 36px;
  font-weight: 800;
  line-height: 1.22;
  margin: 0 0 18px;
  color: var(--nc-ink);
}
.nc-article-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--nc-ink-muted);
  padding-bottom: 22px;
  margin-bottom: 26px;
  border-bottom: 1px solid var(--nc-border);
}
.nc-article-hero {
  margin: 0 0 30px;
  border-radius: 12px;
  overflow: hidden;
  border: 1px solid var(--nc-border);
  background: #1A110B;
}
.nc-article-hero img {
  width: 100%;
  max-height: 520px;
  object-fit: cover;
  display: block;
}
.nc-article-hero figcaption {
  padding: 10px 16px;
  font-size: 12.5px;
  color: var(--nc-ink-muted);
  background: var(--nc-elevated);
}
.nc-video-embed {
  position: relative;
  padding-bottom: 56.25%;
  height: 0;
  overflow: hidden;
  border-radius: 12px;
  margin: 24px 0 30px;
  background: #000;
}
.nc-video-embed iframe,
.nc-video-embed video {
  position: absolute;
  top: 0; left: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.nc-article-body {
  font-size: 17.5px;
  line-height: 1.8;
  color: var(--nc-ink);
}
.nc-article-body p {
  margin: 0 0 22px;
}
.nc-article-body img,
.nc-article-body iframe,
.nc-article-body figure,
.nc-article-body video {
  max-width: 100% !important;
  height: auto !important;
  border-radius: 10px;
  margin: 18px 0;
}
.nc-source-box {
  margin-top: 32px;
  padding: 20px 24px;
  background: var(--nc-elevated);
  border-left: 5px solid var(--nc-botanical);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 14px;
}
.nc-source-box a {
  color: var(--nc-roast);
  font-weight: 700;
  text-decoration: none;
}
.nc-source-box a:hover {
  text-decoration: underline;
}
.nc-back-link {
  display: inline-block;
  margin-top: 26px;
  color: var(--nc-ink-light);
  font-weight: 700;
  text-decoration: none;
}
.nc-back-link:hover {
  color: var(--nc-roast);
}

/* ==========================================================
   6. SUBSCRIPTION SECTION & BUTTONS
   ========================================================== */
.nc-subscribe-section {
  background: linear-gradient(135deg, #20150E 0%, #3A2214 100%);
  color: #F5EFE6;
  border-radius: 16px;
  padding: 48px 36px;
  box-shadow: var(--nc-shadow-card);
  border: 1px solid rgba(217, 155, 82, 0.25);
}
.nc-sub-box {
  max-width: 680px;
  margin: 0 auto;
  text-align: center;
}
.nc-sub-form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 12px;
  margin-top: 24px;
}
.nc-sub-form input {
  padding: 14px 16px;
  border-radius: 8px;
  border: 1px solid rgba(245, 239, 230, 0.2);
  background: rgba(255, 255, 255, 0.95);
  color: #1E140C;
  font-size: 15px;
}
.nc-sub-form button {
  grid-column: 1 / -1;
}

.nc-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 10px 20px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: all 0.2s ease;
}
.nc-btn-primary {
  background: var(--nc-roast);
  color: #fff !important;
}
.nc-btn-primary:hover {
  background: var(--nc-wood);
}

/* Pagination */
.nc-pagination {
  margin-top: 36px;
  text-align: center;
}
.nc-pagination .nav-links {
  display: inline-flex;
  gap: 8px;
  flex-wrap: wrap;
}
.nc-pagination .page-numbers {
  padding: 8px 14px;
  background: var(--nc-paper);
  border: 1px solid var(--nc-border-strong);
  border-radius: 8px;
  text-decoration: none;
  color: var(--nc-ink);
  font-weight: 700;
}
.nc-pagination .page-numbers.current,
.nc-pagination .page-numbers:hover {
  background: var(--nc-roast);
  color: #fff;
  border-color: var(--nc-roast);
}

@media (max-width: 768px) {
  .nc-ticker-meta { display: none; }
  .nc-hero-inner { grid-template-columns: 1fr; }
  .nc-hero { padding: 24px; }
  .nc-hero-title { font-size: 28px; }
  .nc-header-inner { flex-direction: column; gap: 12px; }
  .nc-category-bar { padding: 8px 12px; }
  .nc-cat-btn { padding: 7px 13px; font-size: 12.5px; }
  .nc-grid { grid-template-columns: 1fr; }
  .nc-article { padding: 24px 20px; }
  .nc-article-title { font-size: 26px; }
}
