/*
Theme Name: AnB Smart Tech Professional
Theme URI: https://anbstudio.com/anb-smart-tech-professional
Author: AnB Studio
Author URI: https://anbstudio.com
Description: Professional Media WordPress Theme inspired by Engadget, CNN.com, and BBC.com. Features complete global design token architecture, breaking news announcement bar, Engadget dark slate tech aesthetics, CNN high-impact headline typography, and BBC crisp modular grid structures.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: anb-smart-tech-professional
Tags: news, entertainment, grid-layout, custom-colors, custom-menu, dark-mode, responsive-layout, theme-options, translation-ready
*/

/* ==========================================================================
   GLOBAL DESIGN TOKENS (CSS CUSTOM PROPERTIES)
   ========================================================================== */
:root {
  /* Brand & Editorial Accent Palette */
  --anb-accent: #0066cc;          /* Classic CNN/BBC Blue Accent */
  --anb-accent-strong: #004080;   /* Deep Blue Hover/Gradient End */
  --anb-notice: #d0021b;          /* Breaking News Red (CNN Style) */
  --anb-panel: #11141a;           /* Dark Tech Surface (Engadget Style) */

  /* Neutral Surface & Ink Scale */
  --anb-ink: #0f1419;             /* High-contrast dark text */
  --anb-body: #3e4c59;            /* Readable editorial mid-grey */
  --anb-muted: #657786;           /* Meta & timestamp labels */
  --anb-surface: #ffffff;         /* Pure white card surface */
  --anb-canvas: #f8f9fa;          /* Crisp newsroom background canvas */
  --anb-canvas-alt: #f0f3f6;      /* Faint cool-grey contrast bands */
  --anb-border: #e1e8ed;          /* Crisp hairline dividers */

  /* Editorial Hero Gradients */
  --anb-hero-from: #0f172a;       /* Deep slate navy */
  --anb-hero-to: #1e293b;         /* Dark modern industrial slate */

  /* Typography Stacks */
  --anb-font-display: "Poppins", "Helvetica Neue", Arial, sans-serif;
  --anb-font-body: "Open Sans", -apple-system, BlinkMacSystemFont, sans-serif;

  /* Scale & Spacing Rules */
  --anb-fs-hero: clamp(2.75rem, 6.5vw, 5.5rem);
  --anb-fs-h2: clamp(1.85rem, 3.5vw, 2.75rem);
  --anb-fs-h3: clamp(1.25rem, 2.2vw, 1.75rem);
  --anb-lh-tight: 1.15;
  --anb-lh-body: 1.65;
  --anb-radius-card: 4px;        /* Crisp, modern semi-sharp corners */
  --anb-radius-pill: 999px;
  --anb-shadow-card: 0 1px 3px rgba(0, 0, 0, 0.08);
  --anb-shadow-float: 0 12px 28px rgba(0, 0, 0, 0.12);
  --anb-shadow-glow: 0 0 25px rgba(0, 102, 204, 0.25);

  /* Layout Boundaries */
  --anb-container-max: 1320px;
  --anb-header-height: 72px;
  --anb-notice-height: 42px;
}

/* Dark Mode Overrides */
[data-theme="dark"] {
  --anb-ink: #f8fafc;
  --anb-body: #cbd5e1;
  --anb-muted: #94a3b8;
  --anb-surface: #1e293b;
  --anb-canvas: #0f172a;
  --anb-canvas-alt: #1e293b;
  --anb-border: #334155;
  --anb-shadow-card: 0 4px 20px rgba(0, 0, 0, 0.4);
  --anb-shadow-float: 0 16px 36px rgba(0, 0, 0, 0.6);
}

/* Reset & Global Base Styles */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--anb-font-body);
  font-size: 16px;
  line-height: var(--anb-lh-body);
  color: var(--anb-body);
  background-color: var(--anb-canvas);
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
}

body {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
  transition: background-color 0.3s ease, color 0.3s ease;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--anb-font-display);
  color: var(--anb-ink);
  line-height: var(--anb-lh-tight);
  font-weight: 700;
  letter-spacing: -0.02em;
}

a {
  color: var(--anb-accent);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--anb-accent-strong);
}

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

.container {
  width: 100%;
  max-width: var(--anb-container-max);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* NOTICE BAR (CNN Style Breaking News) */
.notice-bar {
  background-color: var(--anb-notice);
  color: #ffffff;
  font-size: 0.875rem;
  font-weight: 600;
  min-height: var(--anb-notice-height);
  display: flex;
  align-items: center;
  position: relative;
  z-index: 1010;
  box-shadow: 0 2px 8px rgba(208, 2, 27, 0.25);
  transition: max-height 0.3s ease, opacity 0.3s ease;
}

.notice-bar.hidden {
  display: none;
}

.notice-bar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.notice-content {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  overflow: hidden;
}

.notice-badge {
  background: #ffffff;
  color: var(--anb-notice);
  font-family: var(--anb-font-display);
  font-size: 0.725rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  padding: 0.2rem 0.6rem;
  border-radius: 2px;
  white-space: nowrap;
  animation: pulse-notice 2s infinite ease-in-out;
}

@keyframes pulse-notice {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.9; transform: scale(0.97); }
}

.notice-headline {
  color: #ffffff;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.notice-headline:hover {
  text-decoration: underline;
  color: #ffffff;
}

.notice-close {
  background: transparent;
  border: none;
  color: rgba(255, 255, 255, 0.8);
  font-size: 1.25rem;
  cursor: pointer;
  padding: 0 0.5rem;
  line-height: 1;
}

/* PRIMARY NAVIGATION HEADER */
.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background-color: rgba(15, 23, 42, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--anb-header-height);
}

.header-left {
  display: flex;
  align-items: center;
  gap: 2.5rem;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-family: var(--anb-font-display);
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: -0.03em;
  color: #ffffff;
  text-transform: uppercase;
}

.brand-logo .logo-dot {
  width: 10px;
  height: 10px;
  background-color: var(--anb-notice);
  border-radius: 50%;
  display: inline-block;
  box-shadow: 0 0 10px var(--anb-notice);
}

.primary-nav {
  display: flex;
  align-items: center;
  gap: 1.8rem;
  list-style: none;
}

.primary-nav li {
  position: relative;
}

.primary-nav a {
  font-family: var(--anb-font-display);
  font-size: 0.925rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.82);
  padding: 0.5rem 0;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  transition: color 0.2s ease;
}

.primary-nav a:hover, .primary-nav li.current-menu-item > a {
  color: #ffffff;
}

.primary-nav li.current-menu-item > a::after {
  content: '';
  position: absolute;
  bottom: -4px;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--anb-accent);
  box-shadow: 0 0 8px var(--anb-accent);
}

/* WordPress Sub-Menu / Dropdown */
.primary-nav ul.sub-menu {
  position: absolute;
  top: 100%;
  left: 0;
  min-width: 210px;
  background: var(--anb-panel);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: var(--anb-radius-card);
  box-shadow: var(--anb-shadow-float);
  padding: 0.6rem 0;
  opacity: 0;
  visibility: hidden;
  transform: translateY(8px);
  transition: all 0.25s cubic-bezier(0.16, 1, 0.3, 1);
  list-style: none;
  z-index: 100;
}

.primary-nav li:hover > ul.sub-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.primary-nav ul.sub-menu a {
  padding: 0.6rem 1.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: rgba(255, 255, 255, 0.75);
}

.primary-nav ul.sub-menu a:hover {
  background-color: rgba(0, 102, 204, 0.15);
  color: #ffffff;
  padding-left: 1.5rem;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-family: var(--anb-font-display);
  font-weight: 600;
  font-size: 0.875rem;
  padding: 0.6rem 1.35rem;
  border-radius: var(--anb-radius-pill);
  cursor: pointer;
  transition: all 0.25s ease;
  border: none;
  outline: none;
  white-space: nowrap;
}

.btn-accent {
  background: linear-gradient(135deg, var(--anb-accent), var(--anb-accent-strong));
  color: #ffffff;
  box-shadow: 0 4px 14px rgba(0, 102, 204, 0.35);
}

.btn-accent:hover {
  box-shadow: 0 6px 20px rgba(0, 102, 204, 0.5);
  transform: translateY(-1px);
  color: #ffffff;
}

.icon-btn {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: #ffffff;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
}

.icon-btn:hover {
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.3);
  transform: scale(1.05);
}

/* SECTION 01: HERO SPOTLIGHT */
.hero-spotlight {
  position: relative;
  background: linear-gradient(135deg, var(--anb-hero-from) 0%, var(--anb-hero-to) 100%);
  color: #ffffff;
  padding: 5rem 0 7rem 0;
  overflow: hidden;
}

.hero-spotlight::before {
  content: '';
  position: absolute;
  top: -20%;
  right: -10%;
  width: 600px;
  height: 600px;
  background: radial-gradient(circle, rgba(0, 102, 204, 0.18) 0%, rgba(0,0,0,0) 70%);
  pointer-events: none;
  border-radius: 50%;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3.5rem;
  align-items: center;
  position: relative;
  z-index: 2;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--anb-font-display);
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--anb-accent);
  background: rgba(0, 102, 204, 0.15);
  border: 1px solid rgba(0, 102, 204, 0.3);
  padding: 0.35rem 0.85rem;
  border-radius: var(--anb-radius-pill);
  margin-bottom: 1.25rem;
}

.hero-headline {
  font-size: var(--anb-fs-hero);
  font-weight: 800;
  color: #ffffff;
  margin-bottom: 1.25rem;
  letter-spacing: -0.03em;
}

.hero-subheadline {
  font-size: 1.25rem;
  line-height: 1.6;
  color: rgba(255, 255, 255, 0.82);
  margin-bottom: 2rem;
  max-width: 90%;
}

.hero-actions {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.btn-hero-secondary {
  background: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: #ffffff;
}

.hero-media-tilt {
  position: relative;
  transform: rotate3d(0.5, -1, 0, 4deg) rotate(-2deg);
  transition: transform 0.5s ease;
  border-radius: calc(var(--anb-radius-card) * 2);
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.5), var(--anb-shadow-glow);
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: var(--anb-panel);
}

.hero-media-tilt:hover {
  transform: rotate3d(0, 0, 0, 0deg) scale(1.02);
}

.hero-media-tilt img {
  width: 100%;
  height: 380px;
  object-fit: cover;
}

.divider-diagonal {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  line-height: 0;
  z-index: 3;
}

.divider-diagonal svg {
  width: calc(100% + 1.3px);
  height: 50px;
  fill: var(--anb-canvas);
}

/* SECTION 02: EDITORIAL THESIS INTRO */
.intro-statement {
  padding: 5.5rem 0 4.5rem 0;
  background-color: var(--anb-canvas);
  text-align: center;
}

.intro-container {
  max-width: 860px;
  margin: 0 auto;
}

.intro-headline {
  font-size: var(--anb-fs-h2);
  color: var(--anb-accent);
  margin-bottom: 1rem;
}

.intro-subheadline {
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--anb-ink);
  margin-bottom: 1.5rem;
}

.intro-body {
  font-size: 1.125rem;
  line-height: 1.8;
  color: var(--anb-body);
}

/* SECTION 03: FEATURE GRID */
.feature-icon-grid {
  padding: 4.5rem 0 5.5rem 0;
  background-color: var(--anb-canvas-alt);
  border-top: 1px solid var(--anb-border);
  border-bottom: 1px solid var(--anb-border);
}

.section-header-center {
  text-align: center;
  max-width: 680px;
  margin: 0 auto 3.5rem auto;
}

.section-eyebrow {
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--anb-accent);
  margin-bottom: 0.5rem;
}

.section-title {
  font-size: var(--anb-fs-h2);
  color: var(--anb-ink);
}

.grid-4-col {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.75rem;
}

.feature-card {
  background: var(--anb-surface);
  border: 1px solid var(--anb-border);
  border-radius: var(--anb-radius-card);
  padding: 2.25rem 1.75rem;
  box-shadow: var(--anb-shadow-card);
  transition: all 0.3s ease;
  position: relative;
  overflow: hidden;
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 3px;
  background: var(--icon-color, var(--anb-accent));
}

.feature-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--anb-shadow-float);
}

.feature-icon-box {
  width: 70px;
  height: 70px;
  border-radius: 12px;
  background: rgba(0, 0, 0, 0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 1.5rem;
}

.feature-title {
  font-size: var(--anb-fs-h3);
  margin-bottom: 0.75rem;
  color: var(--anb-ink);
}

.card-color-1 { --icon-color: #0066cc; }
.card-color-2 { --icon-color: #2f80ed; }
.card-color-3 { --icon-color: #9b7bea; }
.card-color-4 { --icon-color: #f2b134; }

/* SECTION 04: VISUAL SHOWCASES */
.showcase-cards {
  padding: 6rem 0;
  background-color: var(--anb-canvas);
}

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

.showcase-card {
  background: var(--anb-surface);
  border: 1px solid var(--anb-border);
  border-radius: var(--anb-radius-card);
  overflow: hidden;
  box-shadow: var(--anb-shadow-card);
  transition: all 0.35s ease;
  display: flex;
  flex-direction: column;
}

.showcase-card:hover {
  transform: translateY(-8px);
  box-shadow: var(--anb-shadow-float);
}

.showcase-media {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: hidden;
}

.showcase-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.showcase-card:hover .showcase-media img {
  transform: scale(1.06);
}

.showcase-content {
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.showcase-meta {
  font-size: 0.8rem;
  color: var(--anb-muted);
  margin-bottom: 0.5rem;
  font-weight: 600;
  text-transform: uppercase;
}

.showcase-title {
  font-size: 1.25rem;
  margin-bottom: 0.75rem;
  color: var(--anb-ink);
}

.btn-outline-card {
  align-self: flex-start;
  background: transparent;
  border: 1.5px solid var(--anb-accent);
  color: var(--anb-accent);
  padding: 0.5rem 1.15rem;
  border-radius: var(--anb-radius-card);
  font-size: 0.85rem;
}

.btn-outline-card:hover {
  background: var(--anb-accent);
  color: #ffffff;
}

/* SECTION 05: SUMMARY INDEX MENU */
.split-tile-menu {
  padding: 6rem 0;
  background: var(--anb-canvas-alt);
  border-top: 1px solid var(--anb-border);
}

.split-layout {
  display: grid;
  grid-template-columns: 40% 60%;
  gap: 3rem;
  align-items: center;
}

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

.tile-item {
  background: var(--anb-panel);
  color: #ffffff;
  padding: 2rem;
  border-radius: var(--anb-radius-card);
  border: 1px solid rgba(255, 255, 255, 0.1);
  transition: all 0.3s ease;
  cursor: pointer;
  min-height: 160px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.tile-item:hover {
  border-color: var(--anb-accent);
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(0, 0, 0, 0.3), var(--anb-shadow-glow);
}

.tile-number {
  font-size: 0.75rem;
  font-weight: 800;
  color: var(--anb-accent);
}

.tile-title {
  font-size: 1.15rem;
  color: #ffffff;
}

/* FOOTER */
.site-footer {
  background-color: var(--anb-panel);
  color: #ffffff;
  padding: 4.5rem 0 2.5rem 0;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3.5rem;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding-top: 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: rgba(255, 255, 255, 0.5);
}

/* MODALS & DRAWERS */
.modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(15, 23, 42, 0.75);
  backdrop-filter: blur(6px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  padding: 1.5rem;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal-card {
  background: var(--anb-surface);
  border: 1px solid var(--anb-border);
  border-radius: var(--anb-radius-card);
  max-width: 680px;
  width: 100%;
  box-shadow: var(--anb-shadow-float);
  padding: 2.5rem;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 1.25rem;
  right: 1.25rem;
  background: transparent;
  border: none;
  font-size: 1.5rem;
  color: var(--anb-muted);
  cursor: pointer;
}

.drawer {
  position: fixed;
  top: 0;
  right: 0;
  width: 440px;
  max-width: 100vw;
  height: 100vh;
  background: var(--anb-panel);
  color: #ffffff;
  z-index: 3000;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
  display: flex;
  flex-direction: column;
}

.drawer.active {
  transform: translateX(0);
}

.drawer-header {
  padding: 1.5rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.drawer-body {
  padding: 1.5rem;
  overflow-y: auto;
  flex-grow: 1;
}

pre.code-block {
  background: #090d14;
  padding: 1rem;
  border-radius: 6px;
  font-family: monospace;
  font-size: 0.8rem;
  color: #38bdf8;
}

/* RESPONSIVE */
@media (max-width: 1024px) {
  .hero-grid, .split-layout { grid-template-columns: 1fr; }
  .grid-4-col { grid-template-columns: repeat(2, 1fr); }
  .grid-3-col { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 768px) {
  .primary-nav { display: none; }
  .grid-4-col, .grid-3-col, .tiles-grid, .footer-grid { grid-template-columns: 1fr; }
}
