/* =============================================
   CILINDRADA.COM — Design System "Racing White"
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Rajdhani:wght@500;600;700&family=Inter:wght@300;400;500;600&display=swap');

:root {
  --bg:          #ffffff;
  --bg2:         #f4f4f8;
  --card:        #ffffff;
  --card2:       #f0f0f5;
  --border:      #e0e0e8;
  --border2:     #d0d0da;
  --red:         #cc1111;
  --red-l:       #e63030;
  --red-dark:    #a00d0d;
  --red-glow:    rgba(204,17,17,.12);
  --red-pale:    rgba(204,17,17,.07);
  /* legacy aliases used in components */
  --orange:      #cc1111;
  --orange-l:    #e63030;
  --orange-glow: rgba(204,17,17,.12);
  --orange-pale: rgba(204,17,17,.07);
  --text:        #1a1a22;
  --text-mid:    #4a4a5a;
  --muted:       #888898;
  --white:       #0d0d14;
  --nav-bg:      #111111;
  --footer-bg:   #111111;
  --success:     #16a34a;
  --radius:      8px;
  --radius-l:    14px;
  --shadow:      0 2px 16px rgba(0,0,0,.08);
  --shadow-md:   0 4px 28px rgba(0,0,0,.12);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { scroll-behavior: smooth; }

body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 16px;
}

a { color: var(--red); text-decoration: none; transition: color .2s; }
a:hover { color: var(--red-dark); }

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

/* ── TYPOGRAPHY ── */
h1,h2,h3,h4,h5 {
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  color: var(--white);
  line-height: 1.2;
}
h1 { font-size: clamp(2rem, 5vw, 3.2rem); }
h2 { font-size: clamp(1.6rem, 3.5vw, 2.2rem); }
h3 { font-size: clamp(1.2rem, 2.5vw, 1.55rem); }
h4 { font-size: 1.15rem; }

p { margin-bottom: 1rem; color: var(--text-mid); }
p:last-child { margin-bottom: 0; }

strong { color: var(--text); font-weight: 600; }

ul, ol { padding-left: 1.4rem; color: var(--text-mid); }
li { margin-bottom: .4rem; }

/* ── LAYOUT ── */
.container { max-width: 1160px; margin: 0 auto; padding: 0 20px; }
.section    { padding: 64px 0; }
.section--sm { padding: 40px 0; }

.grid-2 { display: grid; grid-template-columns: repeat(2,1fr); gap: 24px; }
.grid-3 { display: grid; grid-template-columns: repeat(3,1fr); gap: 24px; }
.grid-4 { display: grid; grid-template-columns: repeat(4,1fr); gap: 20px; }
.split  { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; }
.split--60 { grid-template-columns: 3fr 2fr; }

/* ── NAV ── */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--nav-bg);
  border-bottom: 3px solid var(--red);
}
.nav__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 68px;
  gap: 16px;
}
.nav__logo img {
  height: 62px;
  width: auto;
  max-width: 280px;
  object-fit: contain;
  object-position: left center;
  display: block;
}
.nav__links {
  display: flex;
  list-style: none;
  gap: 4px;
  padding: 0;
}
.nav__links a {
  display: block;
  padding: 7px 13px;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: .95rem;
  letter-spacing: .5px;
  color: #cccccc;
  border-radius: var(--radius);
  transition: background .2s, color .2s;
}
.nav__links a:hover,
.nav__links a.active { color: #ffffff; background: var(--red); }

.nav__burger {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
  flex-direction: column;
  gap: 5px;
}
.nav__burger span {
  display: block;
  width: 24px;
  height: 2px;
  background: #cccccc;
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}
.nav__burger.open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav__burger.open span:nth-child(2) { opacity: 0; }
.nav__burger.open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ── HERO ── */
.hero {
  padding: 90px 0 80px;
  background:
    radial-gradient(ellipse 70% 60% at 60% 40%, rgba(204,17,17,.06) 0%, transparent 70%),
    var(--bg2);
  border-bottom: 1px solid var(--border);
  text-align: center;
}
.hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-family: 'Rajdhani', sans-serif;
  font-size: .88rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 18px;
}
.hero__eyebrow::before,
.hero__eyebrow::after {
  content: '';
  width: 30px;
  height: 1px;
  background: var(--red);
}
.hero h1 span { color: var(--red); }
.hero__lead {
  font-size: 1.15rem;
  color: var(--text-mid);
  max-width: 640px;
  margin: 18px auto 36px;
}
.hero__btns { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 26px;
  border-radius: var(--radius);
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: .5px;
  cursor: pointer;
  border: none;
  transition: transform .15s, box-shadow .15s, background .2s;
}
.btn:active { transform: scale(.97); }
.btn--orange {
  background: var(--red);
  color: #fff;
  box-shadow: 0 3px 14px rgba(204,17,17,.3);
}
.btn--orange:hover {
  background: var(--red-l);
  color: #fff;
  box-shadow: 0 4px 20px rgba(204,17,17,.45);
}
.btn--ghost {
  background: transparent;
  color: var(--text);
  border: 1.5px solid var(--border2);
}
.btn--ghost:hover { border-color: var(--red); color: var(--red); background: var(--red-pale); }
.btn--sm { padding: 9px 18px; font-size: .9rem; }

/* ── CARDS ── */
.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-l);
  padding: 28px;
  box-shadow: var(--shadow);
  transition: border-color .25s, box-shadow .25s, transform .2s;
}
.card:hover {
  border-color: var(--red);
  box-shadow: 0 6px 28px rgba(204,17,17,.14);
  transform: translateY(-2px);
}
.card__icon {
  width: 48px;
  height: 48px;
  background: var(--red-pale);
  border: 1px solid rgba(204,17,17,.18);
  border-radius: var(--radius);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  margin-bottom: 16px;
}
.card h3 { margin-bottom: 8px; font-size: 1.2rem; }
.card p { font-size: .95rem; margin: 0; }
.card__link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: .9rem;
  color: var(--red);
  letter-spacing: .5px;
}
.card__link::after { content: '→'; transition: transform .2s; }
.card:hover .card__link::after { transform: translateX(4px); }

/* ── STAT STRIP ── */
.stat-strip {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  border: 1px solid var(--border);
  border-radius: var(--radius-l);
  overflow: hidden;
  background: var(--card);
  box-shadow: var(--shadow);
}
.stat-strip__item {
  padding: 28px 24px;
  text-align: center;
  border-right: 1px solid var(--border);
}
.stat-strip__item:last-child { border-right: none; }
.stat-strip__num {
  font-family: 'Rajdhani', sans-serif;
  font-size: 2.4rem;
  font-weight: 700;
  color: var(--red);
  line-height: 1;
}
.stat-strip__label {
  font-size: .82rem;
  color: var(--muted);
  margin-top: 4px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* ── FORMULA BOX ── */
.formula-box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-left: 4px solid var(--red);
  border-radius: var(--radius);
  padding: 28px 32px;
  text-align: center;
  margin: 24px 0;
}
.formula-box__eq {
  font-family: 'Rajdhani', sans-serif;
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 700;
  color: var(--white);
  letter-spacing: 2px;
}
.formula-box__eq span { color: var(--red); }
.formula-box p { margin-top: 12px; font-size: .92rem; }

/* ── TABLE ── */
.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: .92rem;
}
.data-table th {
  background: #1a1a22;
  color: #ffffff;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: .9rem;
  letter-spacing: .5px;
  text-transform: uppercase;
  padding: 12px 16px;
  text-align: left;
  border-bottom: 3px solid var(--red);
}
.data-table td {
  padding: 11px 16px;
  border-bottom: 1px solid var(--border);
  color: var(--text-mid);
}
.data-table tr:hover td { background: var(--red-pale); color: var(--text); }
.data-table .orange { color: var(--red); font-weight: 600; }
.table-wrap { overflow-x: auto; border-radius: var(--radius); border: 1px solid var(--border); box-shadow: var(--shadow); }

/* ── HIGHLIGHT / INFO BOX ── */
.info-box {
  background: var(--red-pale);
  border: 1px solid rgba(204,17,17,.2);
  border-radius: var(--radius);
  padding: 20px 24px;
  margin: 20px 0;
  display: flex;
  gap: 14px;
  align-items: flex-start;
}
.info-box__icon { font-size: 1.3rem; flex-shrink: 0; line-height: 1.6; }
.info-box p { margin: 0; font-size: .95rem; }

/* ── BREADCRUMB ── */
.breadcrumb {
  padding: 14px 0;
  font-size: .85rem;
  color: var(--muted);
  border-bottom: 1px solid var(--border);
  background: var(--bg2);
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--red); }
.breadcrumb span { margin: 0 8px; }

/* ── PAGE HERO ── */
.page-hero {
  padding: 52px 0 44px;
  background: var(--bg2);
  border-bottom: 1px solid var(--border);
}
.page-hero h1 { margin-bottom: 10px; }
.page-hero__lead { font-size: 1.1rem; color: var(--text-mid); max-width: 660px; margin: 0; }

/* ── SECTION HEADER ── */
.section-hd { text-align: center; margin-bottom: 44px; }
.section-hd__tag {
  font-family: 'Rajdhani', sans-serif;
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--red);
  display: block;
  margin-bottom: 10px;
}
.section-hd h2 { margin-bottom: 10px; }
.section-hd p { color: var(--text-mid); max-width: 540px; margin: 0 auto; }

/* ── SIDEBAR LAYOUT ── */
.layout-sidebar { display: grid; grid-template-columns: 1fr 300px; gap: 32px; align-items: start; }
.sidebar-box {
  background: var(--bg2);
  border: 1px solid var(--border);
  border-radius: var(--radius-l);
  padding: 24px;
  margin-bottom: 24px;
  position: sticky;
  top: 88px;
  box-shadow: var(--shadow);
}
.sidebar-box h4 {
  font-size: 1rem;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 2px solid var(--red);
  color: var(--red);
  letter-spacing: .5px;
}
.sidebar-box ul { list-style: none; padding: 0; }
.sidebar-box ul li { padding: 6px 0; border-bottom: 1px solid var(--border); }
.sidebar-box ul li:last-child { border-bottom: none; }
.sidebar-box a { font-size: .9rem; color: var(--text-mid); display: flex; align-items: center; gap: 8px; }
.sidebar-box a:hover { color: var(--red); }
.sidebar-box a::before { content: '▸'; color: var(--red); font-size: .75rem; }

/* ── FAQ ── */
.faq { max-width: 780px; margin: 0 auto; }
.faq__item {
  border-bottom: 1px solid var(--border);
}
.faq__q {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 20px 4px;
  cursor: pointer;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--text);
  transition: color .2s;
  user-select: none;
}
.faq__q:hover { color: var(--red); }
.faq__q .faq__arrow {
  width: 26px;
  height: 26px;
  flex-shrink: 0;
  border: 1.5px solid var(--border2);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .75rem;
  transition: transform .3s, border-color .2s, background .2s;
  color: var(--text-mid);
}
.faq__item.open .faq__arrow {
  transform: rotate(180deg);
  border-color: var(--red);
  background: var(--red-pale);
  color: var(--red);
}
.faq__a {
  max-height: 0;
  overflow: hidden;
  transition: max-height .35s ease;
  padding: 0 4px;
}
.faq__a p { color: var(--text-mid); font-size: .95rem; padding-bottom: 16px; margin: 0; }

/* ── RANGE CARDS ── */
.range-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-l);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: border-color .25s, transform .2s, box-shadow .25s;
}
.range-card:hover { border-color: var(--red); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.range-card__head {
  background: #1a1a22;
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.range-card__cc {
  font-family: 'Rajdhani', sans-serif;
  font-size: 1.6rem;
  font-weight: 700;
  color: var(--red);
}
.range-card__label { font-size: .82rem; color: #888; text-transform: uppercase; letter-spacing: 1px; }
.range-card__body { padding: 18px 22px; }
.range-card__body p { font-size: .92rem; margin-bottom: 10px; }
.range-card__examples { list-style: none; padding: 0; }
.range-card__examples li {
  font-size: .88rem;
  color: var(--muted);
  padding: 3px 0;
  display: flex;
  align-items: center;
  gap: 8px;
}
.range-card__examples li::before { content: '▸'; color: var(--red); font-size: .7rem; }

/* ── STEP LIST ── */
.steps { counter-reset: step; }
.step {
  display: flex;
  gap: 20px;
  margin-bottom: 28px;
  counter-increment: step;
}
.step__num {
  flex-shrink: 0;
  width: 42px;
  height: 42px;
  background: var(--red);
  color: #fff;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  font-size: 1.1rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 10px rgba(204,17,17,.3);
}
.step__num::before { content: counter(step); }
.step__body h4 { margin-bottom: 6px; }

/* ── BADGE / TAG ── */
.badge {
  display: inline-flex;
  align-items: center;
  padding: 3px 10px;
  border-radius: 999px;
  font-family: 'Rajdhani', sans-serif;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: 1px;
  text-transform: uppercase;
}
.badge--orange { background: var(--red-pale); color: var(--red); border: 1px solid rgba(204,17,17,.2); }
.badge--gray   { background: var(--bg2); color: var(--muted); border: 1px solid var(--border); }

/* ── ORANGE / RED STRIP (CTA) ── */
.strip {
  background: var(--red);
  color: #fff;
  padding: 52px 0;
  text-align: center;
}
.strip h2 { color: #fff; margin-bottom: 10px; }
.strip p { color: rgba(255,255,255,.88); max-width: 560px; margin: 0 auto 24px; }
.strip .btn--ghost { border-color: rgba(255,255,255,.5); color: #fff; }
.strip .btn--ghost:hover { border-color: #fff; background: rgba(255,255,255,.15); color: #fff; }

/* ── CONTACT FORM ── */
.form-grid { display: grid; gap: 18px; }
.form-group { display: flex; flex-direction: column; gap: 6px; }
.form-group label { font-family: 'Rajdhani', sans-serif; font-size: .9rem; font-weight: 600; color: var(--text); letter-spacing: .5px; }
.form-group input,
.form-group textarea,
.form-group select {
  background: var(--bg2);
  border: 1.5px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 16px;
  color: var(--text);
  font-family: 'Inter', sans-serif;
  font-size: .95rem;
  transition: border-color .2s;
  width: 100%;
}
.form-group input:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--red);
  box-shadow: 0 0 0 3px var(--red-glow);
}
.form-group textarea { resize: vertical; min-height: 130px; }
.form-msg { display: none; padding: 14px 18px; border-radius: var(--radius); font-size: .95rem; margin-top: 8px; }
.form-msg.ok  { background: rgba(22,163,74,.08); border: 1px solid rgba(22,163,74,.3); color: #16a34a; display: block; }
.form-msg.err { background: var(--red-pale); border: 1px solid rgba(204,17,17,.25); color: var(--red); display: block; }

/* ── FOOTER ── */
.footer {
  background: var(--footer-bg);
  border-top: 3px solid var(--red);
  padding: 52px 0 28px;
}
.footer__top { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 36px; margin-bottom: 40px; }
.footer__brand p { font-size: .9rem; color: #888; margin-top: 12px; max-width: 260px; }
.footer__col h5 {
  font-family: 'Rajdhani', sans-serif;
  font-size: .85rem;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 14px;
}
.footer__col ul { list-style: none; padding: 0; }
.footer__col li { margin-bottom: 8px; }
.footer__col a { font-size: .9rem; color: #888; }
.footer__col a:hover { color: #ffffff; }
.footer__bottom {
  border-top: 1px solid #2a2a2a;
  padding-top: 22px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 10px;
}
.footer__bottom p { font-size: .82rem; color: #666; margin: 0; }
.footer__legal { display: flex; gap: 16px; flex-wrap: wrap; }
.footer__legal a { font-size: .82rem; color: #666; }
.footer__legal a:hover { color: #ffffff; }

/* ── COOKIE BANNER ── */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  background: #111111;
  border-top: 2px solid var(--red);
  padding: 18px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  z-index: 200;
  box-shadow: 0 -4px 30px rgba(0,0,0,.15);
  transform: translateY(100%);
  transition: transform .35s ease;
}
.cookie-banner.visible { transform: translateY(0); }
.cookie-banner p { font-size: .88rem; color: #aaa; margin: 0; }
.cookie-banner a { color: var(--red-l); }
.cookie-btns { display: flex; gap: 10px; flex-shrink: 0; }

/* ── LEGAL PAGES ── */
.legal-content { max-width: 820px; }
.legal-content h2 { font-size: 1.4rem; margin: 36px 0 12px; border-bottom: 2px solid var(--border); padding-bottom: 8px; }
.legal-content h3 { font-size: 1.1rem; margin: 24px 0 8px; color: var(--red); }
.legal-content p  { font-size: .95rem; }
.legal-content ul { font-size: .95rem; margin-bottom: 1rem; }

/* ── IMAGES ── */
.img-hero {
  width: 100%;
  height: 360px;
  object-fit: cover;
  object-position: center;
  display: block;
  border-radius: var(--radius-l);
  border: 1px solid var(--border);
  margin-bottom: 36px;
  box-shadow: var(--shadow-md);
}
.img-content {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  margin: 24px 0;
  display: block;
  box-shadow: var(--shadow);
}
.img-full {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
  object-position: center 40%;
  display: block;
}
.img-caption {
  font-size: .78rem;
  color: var(--muted);
  text-align: center;
  margin-top: -12px;
  margin-bottom: 24px;
  font-style: italic;
}
.img-section {
  border-bottom: 1px solid var(--border);
  overflow: hidden;
  position: relative;
}
.img-section::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 120px;
  background: linear-gradient(transparent, var(--bg));
  pointer-events: none;
}
.img-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin: 24px 0;
}
.img-grid img {
  width: 100%;
  height: 220px;
  object-fit: cover;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
}

/* ── UTILITIES ── */
.text-orange { color: var(--red); }
.text-muted  { color: var(--muted); }
.text-center { text-align: center; }
.mt-4  { margin-top: 4px; }
.mt-8  { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.mb-48 { margin-bottom: 48px; }

/* ── RESPONSIVE ── */
@media (max-width: 1024px) {
  .footer__top { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: 1fr 1fr; }
  .grid-4 { grid-template-columns: 1fr 1fr; }
  .split  { grid-template-columns: 1fr; }
  .split--60 { grid-template-columns: 1fr; }
  .layout-sidebar { grid-template-columns: 1fr; }
  .sidebar-box { position: static; }
  .stat-strip { grid-template-columns: repeat(2,1fr); }
  .stat-strip__item:nth-child(2) { border-right: none; }
  .stat-strip__item:nth-child(3) { border-top: 1px solid var(--border); }
}
@media (max-width: 768px) {
  .nav__links { display: none; flex-direction: column; gap: 4px; }
  .nav__links.open {
    display: flex;
    position: absolute;
    top: 68px;
    left: 0;
    right: 0;
    background: #111111;
    border-bottom: 2px solid var(--red);
    padding: 12px 20px 16px;
  }
  .nav__burger { display: flex; }
  .nav { position: relative; }
  .hero { padding: 64px 0 56px; }
  .section { padding: 48px 0; }
  .footer__top { grid-template-columns: 1fr; gap: 24px; }
  .footer__bottom { flex-direction: column; align-items: flex-start; }
  .grid-2 { grid-template-columns: 1fr; }
  .img-hero { height: 220px; }
  .img-content { height: 200px; }
  .img-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .stat-strip { grid-template-columns: 1fr 1fr; }
  h1 { font-size: 2rem; }
}

/* ══════════════════════════════════════════
   NOTICIAS
   ══════════════════════════════════════════ */

/* Filtros */
.news-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 36px;
}
.news-filter {
  padding: 6px 18px;
  border-radius: 99px;
  border: 1px solid var(--border2);
  font-size: .85rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 600;
  color: var(--text-mid);
  transition: all .2s;
  text-decoration: none;
}
.news-filter:hover,
.news-filter--active {
  background: var(--red);
  border-color: var(--red);
  color: #fff;
}

/* Categoría badge inline */
.news-cat {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 99px;
  font-size: .72rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
}
.news-cat--coches       { background: #1a1a5e; color: #fff; }
.news-cat--motos        { background: var(--red); color: #fff; }
.news-cat--tecnología,
.news-cat--tecnologia   { background: #1a4a1a; color: #fff; }
.news-cat--competición,
.news-cat--competicion  { background: #4a2040; color: #fff; }
.news-cat--motor        { background: #2d3436; color: #fff; }

.news-date {
  font-size: .78rem;
  color: var(--muted);
}
.news-read {
  font-size: .78rem;
  color: var(--muted);
}

/* ── Noticia destacada ── */
.news-featured {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border-radius: var(--radius-l);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  margin-bottom: 0;
  text-decoration: none;
  color: inherit;
  transition: box-shadow .2s;
}
.news-featured:hover { box-shadow: 0 8px 40px rgba(0,0,0,.15); }
.news-featured__img { aspect-ratio: 4/3; overflow: hidden; }
.news-featured__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .4s;
}
.news-featured:hover .news-featured__img img { transform: scale(1.04); }
.news-featured__body {
  padding: 36px 32px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--card);
}
.news-featured__meta {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  flex-wrap: wrap;
}
.news-featured__title {
  font-size: 1.55rem;
  line-height: 1.25;
  margin-bottom: 14px;
  color: var(--white);
}
.news-featured__excerpt {
  color: var(--text-mid);
  font-size: .95rem;
  line-height: 1.6;
}

/* ── Grid de noticias ── */
.news-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.news-card {
  display: flex;
  flex-direction: column;
  border-radius: var(--radius-l);
  overflow: hidden;
  border: 1px solid var(--border);
  box-shadow: var(--shadow);
  text-decoration: none;
  color: inherit;
  transition: box-shadow .2s, transform .2s;
}
.news-card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-3px);
  border-color: var(--red);
}
.news-card__img { aspect-ratio: 16/9; overflow: hidden; }
.news-card__img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .35s;
}
.news-card:hover .news-card__img img { transform: scale(1.05); }
.news-card__body {
  padding: 20px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.news-card__meta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  flex-wrap: wrap;
}
.news-card__title {
  font-size: 1.05rem;
  line-height: 1.3;
  margin-bottom: 10px;
  color: var(--white);
  flex: 1;
}
.news-card__excerpt {
  font-size: .86rem;
  color: var(--text-mid);
  line-height: 1.55;
  flex: 1;
  margin-bottom: 14px;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.news-card__link {
  font-size: .82rem;
  font-family: 'Rajdhani', sans-serif;
  font-weight: 700;
  color: var(--red);
  text-transform: uppercase;
  letter-spacing: .05em;
}

/* ── Artículo individual ── */
.news-article__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 18px;
  flex-wrap: wrap;
  font-size: .85rem;
  color: var(--text-mid);
}
.news-article__title {
  font-size: 2.1rem;
  line-height: 1.2;
  margin-bottom: 16px;
  color: var(--white);
}
.news-article__lead {
  font-size: 1.1rem;
  color: var(--text-mid);
  line-height: 1.65;
  margin-bottom: 28px;
  border-left: 3px solid var(--red);
  padding-left: 16px;
}
.news-article__img-wrap {
  border-radius: var(--radius-l);
  overflow: hidden;
  margin-bottom: 32px;
}
.news-article__img-wrap img {
  width: 100%;
  height: 380px;
  object-fit: cover;
}
.news-article__body { line-height: 1.8; }
.news-article__body h2 {
  font-size: 1.45rem;
  margin: 36px 0 14px;
  color: var(--white);
}
.news-article__body p { margin-bottom: 18px; }
.news-article__body ul { padding-left: 20px; margin-bottom: 18px; }
.news-article__body li { margin-bottom: 6px; }
.news-article__source {
  margin-top: 32px;
  padding: 12px 16px;
  background: var(--bg2);
  border-radius: var(--radius);
  font-size: .84rem;
  color: var(--muted);
  border-left: 3px solid var(--border2);
}
.news-article__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 20px;
}
.news-article__nav {
  margin-top: 36px;
  padding-top: 24px;
  border-top: 1px solid var(--border);
}

/* ── Sidebar noticias recientes ── */
.sidebar-news { list-style: none; padding: 0; }
.sidebar-news li {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}
.sidebar-news li:last-child { border-bottom: none; }
.sidebar-news a {
  font-size: .88rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--text);
}
.sidebar-news a:hover { color: var(--red); }

/* ── Responsive noticias ── */
@media (max-width: 900px) {
  .news-featured { grid-template-columns: 1fr; }
  .news-featured__img { aspect-ratio: 16/9; }
  .news-featured__body { padding: 24px 20px; }
  .news-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .news-grid { grid-template-columns: 1fr; }
  .news-article__title { font-size: 1.55rem; }
  .news-article__img-wrap img { height: 220px; }
}

/* ── BACK TO TOP ── */
#backToTop {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 150;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--red);
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s;
  box-shadow: 0 4px 16px rgba(204,17,17,.35);
  color: #fff;
  font-size: 1.1rem;
}
