/*
Theme Name: Capital Standard
Theme URI: https://capitalstandard.com
Author: Capital Standard
Author URI: https://capitalstandard.com
Description: A modern dark news portal theme for Capital Standard
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: capital-standard
Tags: news, magazine, dark, responsive
*/

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

/* =====================
   CSS VARIABLES
===================== */
:root {
  --dark-bg: #0a1a12;
	
  --dark-nav: #071510;
  --dark-card: #111c15;
  --dark-card-hover: #162010;
  --dark-section: #0f1a13;
  --accent: #2ecc71;
  --accent-dark: #27ae60;
  --accent-bright: #39ff88;
  --text-primary: #f0ede8;
  --text-secondary: #9aab9e;
  --text-muted: #5c7264;
  --border: rgba(46, 204, 113, 0.12);
  --border-subtle: rgba(255,255,255,0.06);
  --font-display: 'Playfair Display', serif;
  --font-serif: 'DM Serif Display', serif;
  --font-body: 'DM Sans', sans-serif;
  --radius: 10px;
  --radius-sm: 6px;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* =====================
   RESET & BASE
===================== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  background-color: var(--dark-bg);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; transition: color var(--transition); }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }

/* =====================
   HEADER & NAVIGATION
===================== */
#site-header {
  background: var(--dark-nav);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 20px;
}

.hamburger {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 4px;
}

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

.site-branding a {
  display: flex;
  align-items: center;
  gap: 10px;
}

.site-logo-text {
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.5px;
}

.site-logo-text span {
  color: var(--accent);
}

.logo-icon {
  width: 38px;
  height: 38px;
  border: 2px solid var(--text-primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-size: 14px;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -1px;
}

.header-search-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-primary);
  padding: 4px;
  transition: color var(--transition);
}

.header-search-btn:hover { color: var(--accent); }

.header-search-btn svg {
  width: 22px;
  height: 22px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
}

/* Category Nav */
.category-nav {
  display: flex;
  gap: 0;
  overflow-x: auto;
  padding: 0 20px;
  border-top: 1px solid var(--border-subtle);
  scrollbar-width: none;
}

.category-nav::-webkit-scrollbar { display: none; }

.category-nav a {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--text-secondary);
  padding: 14px 18px 13px;
  white-space: nowrap;
  border-bottom: 2px solid transparent;
  transition: var(--transition);
}

.category-nav a:hover {
  color: var(--text-primary);
}

.category-nav a.active {
  color: var(--accent);
  border-bottom-color: var(--accent);
}

/* Mobile Menu */
.mobile-menu {
  display: none;
  background: var(--dark-nav);
  border-top: 1px solid var(--border);
  padding: 20px;
  flex-direction: column;
  gap: 4px;
}

.mobile-menu.open { display: flex; }

.mobile-menu a {
  font-size: 15px;
  font-weight: 500;
  color: var(--text-secondary);
  padding: 12px 0;
  border-bottom: 1px solid var(--border-subtle);
  transition: color var(--transition);
}

.mobile-menu a:hover { color: var(--accent); }

/* =====================
   HERO / FEATURED ARTICLE
===================== */
.hero-section {
  position: relative;
  height: 420px;
  overflow: hidden;
}

.hero-section .hero-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  filter: brightness(0.5);
  transition: transform 0.6s ease;
}

.hero-section:hover .hero-image {
  transform: scale(1.03);
}

.hero-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(7, 21, 16, 0.1) 0%,
    rgba(7, 21, 16, 0.3) 40%,
    rgba(7, 21, 16, 0.85) 100%
  );
}

.hero-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 30px 20px;
}

.hero-badge {
  display: inline-block;
  background: var(--accent);
  color: var(--dark-bg);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 20px;
  margin-bottom: 14px;
}

.hero-title {
  font-family: var(--font-display);
  font-size: 28px;
  font-weight: 800;
  line-height: 1.2;
  color: #fff;
  margin-bottom: 8px;
  text-shadow: 0 2px 20px rgba(0,0,0,0.5);
}

.hero-excerpt {
  font-size: 14px;
  color: rgba(255,255,255,0.75);
  margin-bottom: 18px;
  font-weight: 300;
}

.hero-read-more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: gap var(--transition);
}

.hero-read-more:hover { gap: 14px; color: var(--accent-bright); }

.hero-read-more svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.5;
}

/* =====================
   SECTION HEADINGS
===================== */
.section-heading {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-bottom: 20px;
}

.section-heading::before {
  content: '';
  display: block;
  width: 4px;
  height: 20px;
  background: var(--accent);
  border-radius: 2px;
  flex-shrink: 0;
}

/* =====================
   FEATURED STORIES
===================== */
.featured-section {
  background: var(--dark-section);
  padding: 28px 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.featured-grid {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  scrollbar-width: none;
  padding-bottom: 4px;
}

.featured-grid::-webkit-scrollbar { display: none; }

.featured-card {
  position: relative;
  min-width: 200px;
  height: 240px;
  border-radius: var(--radius);
  overflow: hidden;
  flex-shrink: 0;
  cursor: pointer;
}

.featured-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
  filter: brightness(0.65);
}

.featured-card:hover img {
  transform: scale(1.06);
  filter: brightness(0.5);
}

.featured-card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    transparent 30%,
    rgba(7, 21, 16, 0.9) 100%
  );
}

.featured-card-content {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  padding: 16px;
}

.featured-card-badge {
  display: inline-block;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.2);
  color: #fff;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  padding: 4px 8px;
  border-radius: 4px;
  margin-bottom: 8px;
}

.featured-card-title {
  font-family: var(--font-serif);
  font-size: 15px;
  line-height: 1.3;
  color: #fff;
  font-weight: 400;
}

/* =====================
   LATEST STORIES
===================== */
.latest-section {
  padding: 28px 20px;
  background: var(--dark-bg);
}

.latest-card {
  display: flex;
  gap: 16px;
  background: var(--dark-card);
  border-radius: var(--radius);
  overflow: hidden;
  margin-bottom: 14px;
  border: 1px solid var(--border-subtle);
  transition: border-color var(--transition), background var(--transition);
  cursor: pointer;
}

.latest-card:hover {
  border-color: var(--border);
  background: var(--dark-card-hover);
}

.latest-card-image {
  width: 120px;
  min-height: 120px;
  flex-shrink: 0;
  overflow: hidden;
}

.latest-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}

.latest-card:hover .latest-card-image img {
  transform: scale(1.08);
}

.latest-card-content {
  padding: 14px 14px 14px 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  flex: 1;
}

.latest-card-title {
  font-family: var(--font-serif);
  font-size: 16px;
  font-weight: 400;
  line-height: 1.35;
  color: var(--text-primary);
  margin-bottom: 6px;
}

.latest-card-excerpt {
  font-size: 12px;
  color: var(--text-secondary);
  line-height: 1.5;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 10px;
}

.latest-card-meta {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.tag-badge {
  background: var(--accent);
  color: var(--dark-bg);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.5px;
  padding: 4px 10px;
  border-radius: 20px;
}

.meta-time, .meta-read {
  font-size: 11px;
  color: var(--text-muted);
}

/* =====================
   SEARCH OVERLAY
===================== */
.search-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(7, 21, 16, 0.97);
  z-index: 200;
  padding: 60px 20px 20px;
  flex-direction: column;
  align-items: center;
}

.search-overlay.open { display: flex; }

.search-overlay-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 28px;
  cursor: pointer;
  line-height: 1;
}

.search-input-wrap {
  width: 100%;
  max-width: 600px;
  position: relative;
  margin-bottom: 30px;
}

.search-input {
  width: 100%;
  background: var(--dark-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--text-primary);
  outline: none;
  transition: border-color var(--transition);
}

.search-input:focus {
  border-color: var(--accent);
}

.search-input::placeholder { color: var(--text-muted); }

/* =====================
   SINGLE POST
===================== */
.single-post-header {
  padding: 30px 20px 20px;
}

.single-post-badge {
  display: inline-block;
  background: var(--accent);
  color: var(--dark-bg);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  padding: 5px 12px;
  border-radius: 20px;
  margin-bottom: 16px;
}

.single-post-title {
  font-family: var(--font-display);
  font-size: 26px;
  font-weight: 800;
  line-height: 1.2;
  margin-bottom: 14px;
}

.single-post-meta {
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 12px;
  color: var(--text-muted);
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-subtle);
}

.single-post-author {
  color: var(--accent);
  font-weight: 600;
}

.single-post-featured-image {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.single-post-content {
  padding: 24px 20px;
  font-size: 15px;
  line-height: 1.8;
  color: var(--text-secondary);
}

.single-post-content p { margin-bottom: 18px; }
.single-post-content h2 {
  font-family: var(--font-display);
  font-size: 20px;
  color: var(--text-primary);
  margin: 28px 0 14px;
}


/* =====================
   FOOTER
===================== */

/* Light top section */
.footer-light {
    background: #f5f5f0;
    padding: 40px 20px;
    text-align: center;
    border-top: 1px solid #ddd;
}

.footer-contact-block {
    margin-bottom: 32px;
}

.footer-contact-block:last-child {
    margin-bottom: 0;
}

.footer-section-label {
    display: block;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 3px;
    color: #888;
    margin-bottom: 10px;
    text-transform: uppercase;
}

.footer-email {
    font-size: 18px;
    color: #222;
    font-weight: 400;
    transition: color var(--transition);
}

.footer-email:hover { color: var(--accent-dark); }

.footer-social-row {
    display: flex;
    justify-content: center;
    gap: 40px;
    margin-top: 8px;
}

.footer-social-row a {
    color: #444;
    transition: color var(--transition);
    display: flex;
    align-items: center;
}

.footer-social-row a:hover { color: var(--accent-dark); }

/* Dark bottom section */
.footer-dark {
    background: #0d1f17;
    padding: 36px 20px 0;
}

.footer-dark-inner {
    display: flex;
    flex-direction: column;
    gap: 28px;
    padding-bottom: 28px;
    border-bottom: 1px solid rgba(255,255,255,0.08);
}

.footer-logo {
    font-family: var(--font-display);
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 8px;
}

.footer-logo span { color: var(--accent); }

.footer-tagline {
    font-size: 13px;
    color: rgba(255,255,255,0.4);
}

.footer-nav-col {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.footer-nav-col a {
    font-size: 15px;
    color: rgba(255,255,255,0.7);
    transition: color var(--transition);
    border-bottom: 1px solid rgba(255,255,255,0.06);
    padding-bottom: 14px;
}

.footer-nav-col a:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.footer-nav-col a:hover { color: var(--accent); }

.footer-copyright {
    padding: 18px 0;
    text-align: center;
    font-size: 12px;
    font-weight: 600;
    color: rgba(255,255,255,0.3);
    letter-spacing: 0.3px;
}
