/*
Theme Name: Chips & Change
Theme URI: https://chipsandchange.tech
Author: Qanit
Author URI: https://chipsandchange.tech
Description: A trade-journal theme set on the fab floor: cleanroom white, slate ink, one copper accent. Libre Franklin headlines, Newsreader body. Built for Chips & Change.
Requires at least: 6.4
Tested up to: 6.7
Requires PHP: 7.4
Version: 1.1
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: chipsandchange
Tags: blog, news, editorial, block-styles, full-site-editing, custom-colors
*/

/* =====================================================
   Chips & Change — trade-floor edition
   ===================================================== */

:root {
  --cc-paper: #F4F5F6;
  --cc-ink: #1C2530;
  --cc-steel: #5D6874;
  --cc-rule: #C9CFD5;
  --cc-copper: #A8501C;
  --cc-copper-deep: #7E3512;
  --cc-ember: #2B211B;
  --cc-copper-light: #D98E5F;
}

body {
  background: var(--cc-paper);
  color: var(--cc-ink);
}

/* ---------- Masthead ---------- */

.cc-masthead {
  text-align: center;
  padding: 3.5rem 0 2rem;
  border-bottom: 3px solid var(--cc-ink);
}

.cc-masthead .wp-block-site-title a {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 800;
  font-size: clamp(2.75rem, 7vw, 4.5rem);
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--cc-ink);
  text-decoration: none;
}

.cc-masthead .wp-block-site-title a:hover {
  color: var(--cc-copper);
}

.cc-tagline {
  font-family: 'Newsreader', serif;
  font-style: italic;
  font-size: 1.15rem;
  color: var(--cc-steel);
  margin-top: 0.75rem;
}

.cc-wafer {
  display: inline-block;
  vertical-align: middle;
  margin-bottom: 0.5rem;
}

/* ---------- Section strip (nav) ---------- */

.cc-section-nav {
  border-bottom: 1px solid var(--cc-ink);
  margin-bottom: 3rem;
}

.cc-section-nav ul.wp-block-navigation {
  justify-content: center;
  gap: 2.25rem;
}

.cc-section-nav ul.wp-block-navigation li {
  list-style: none;
}

.cc-section-nav ul.wp-block-navigation a {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--cc-ink);
  text-decoration: none;
  padding: 0.9rem 0;
  display: inline-block;
}

.cc-section-nav ul.wp-block-navigation a:hover {
  color: var(--cc-copper);
}

/* ---------- Kickers and datelines ---------- */

.cc-kicker {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 700;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cc-copper);
  margin-bottom: 0.6rem;
}

.cc-kicker a {
  color: var(--cc-copper);
  text-decoration: none;
}

.cc-kicker a:hover {
  color: var(--cc-copper-deep);
}

.cc-dateline {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 500;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cc-steel);
}

/* ---------- Front page: lead story (dynamic) ---------- */

.cc-lead .wp-block-post-title {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 800;
  font-size: clamp(1.9rem, 4.2vw, 3rem);
  line-height: 1.1;
  letter-spacing: -0.015em;
  margin: 0.35rem 0 0.75rem;
}

.cc-lead .wp-block-post-title a {
  color: var(--cc-ink);
  text-decoration: none;
}

.cc-lead .wp-block-post-title a:hover {
  color: var(--cc-copper);
}

.cc-lead .wp-block-post-excerpt {
  font-family: 'Newsreader', serif;
  font-size: 1.25rem;
  line-height: 1.55;
  color: var(--cc-steel);
}

.cc-lead .wp-block-post-excerpt__more-text {
  display: none;
}

/* ---------- Deep dive spotlight band ---------- */

.cc-spotlight {
  background: var(--cc-ember);
  color: var(--cc-paper);
  padding: 2.75rem;
  margin: 3.5rem 0;
}

.cc-spotlight .cc-kicker {
  color: var(--cc-copper-light);
}

.cc-spotlight .cc-kicker a {
  color: var(--cc-copper-light);
}

.cc-spotlight .wp-block-post-title,
.cc-spotlight h2,
.cc-spotlight h3 {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 700;
  font-size: 1.6rem;
  line-height: 1.2;
  margin: 0.35rem 0 0.75rem;
}

.cc-spotlight .wp-block-post-title a,
.cc-spotlight h2 a,
.cc-spotlight h3 a {
  color: var(--cc-paper);
  text-decoration: none;
}

.cc-spotlight .wp-block-post-title a:hover,
.cc-spotlight h2 a:hover,
.cc-spotlight h3 a:hover {
  color: var(--cc-copper-light);
}

.cc-spotlight p,
.cc-spotlight .wp-block-post-excerpt {
  color: #C9C2BC;
  font-family: 'Newsreader', serif;
}

.cc-spotlight .wp-block-post-excerpt__more-text {
  display: none;
}

/* ---------- Latest analysis rows ---------- */

.cc-latest h2 {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 800;
  font-size: 1.5rem;
  border-bottom: 3px solid var(--cc-ink);
  padding-bottom: 0.5rem;
  margin-bottom: 0;
}

.cc-latest ul {
  margin: 0;
  padding: 0;
}

.cc-latest li {
  list-style: none;
  border-bottom: 1px solid var(--cc-rule);
  padding: 1.75rem 0;
}

.cc-latest .wp-block-post-title {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 700;
  font-size: 1.35rem;
  line-height: 1.2;
  margin: 0.35rem 0 0.5rem;
}

.cc-latest .wp-block-post-title a {
  color: var(--cc-ink);
  text-decoration: none;
}

.cc-latest .wp-block-post-title a:hover {
  color: var(--cc-copper);
}

.cc-latest .wp-block-post-excerpt {
  font-family: 'Newsreader', serif;
  font-size: 1.02rem;
  color: var(--cc-steel);
}

.cc-latest .wp-block-post-date {
  margin-top: 0.25rem;
}

/* ---------- Archive pages ---------- */

.cc-archive-title {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 800;
  font-size: clamp(1.8rem, 3.5vw, 2.5rem);
  border-bottom: 3px solid var(--cc-ink);
  padding-bottom: 0.6rem;
  margin-bottom: 1.5rem;
}

.cc-archive-desc {
  font-family: 'Newsreader', serif;
  font-size: 1.1rem;
  color: var(--cc-steel);
  margin-bottom: 2rem;
}

/* ---------- Single post pages ---------- */

.cc-post-header .wp-block-post-title {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 800;
  font-size: clamp(2rem, 4.5vw, 3rem);
  letter-spacing: -0.015em;
  line-height: 1.12;
  margin: 0.35rem 0 0.75rem;
}

.cc-post-header .wp-block-post-date,
.cc-post-header .wp-block-post-author-name {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 500;
  font-size: 0.78rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cc-steel);
}

.cc-post-header .wp-block-post-author-name {
  text-transform: none;
  letter-spacing: 0.02em;
}

.wp-block-post-content {
  font-family: 'Newsreader', serif;
  font-size: 1.08rem;
  line-height: 1.75;
}

.wp-block-post-content h2,
.wp-block-post-content h3 {
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 700;
  line-height: 1.25;
  margin-top: 2rem;
}

/* ---------- Buttons ---------- */

.wp-block-button .wp-block-button__link.cc-button {
  background: var(--cc-copper);
  color: #FFFFFF;
  border-radius: 0;
  font-family: 'Libre Franklin', sans-serif;
  font-weight: 700;
  font-size: 0.82rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  padding: 0.85rem 1.75rem;
}

.wp-block-button .wp-block-button__link.cc-button:hover {
  background: var(--cc-copper-deep);
  color: #FFFFFF;
}

/* ---------- Links in body text ---------- */

.entry-content a,
.wp-block-post-content a {
  color: var(--cc-copper);
  text-decoration: underline;
  text-decoration-thickness: 1.5px;
  text-underline-offset: 3px;
}

.entry-content a:hover,
.wp-block-post-content a:hover {
  color: var(--cc-copper-deep);
}

/* ---------- Footer ---------- */

.cc-footer {
  border-top: 3px solid var(--cc-ink);
  margin-top: 4rem;
  padding-top: 1.5rem;
  padding-bottom: 2.5rem;
}

.cc-footer p,
.cc-footer a {
  font-family: 'Libre Franklin', sans-serif;
  font-size: 0.85rem;
  color: var(--cc-steel);
  text-decoration: none;
}

.cc-footer a:hover {
  color: var(--cc-copper);
}

/* ---------- Search form ---------- */

.wp-block-search__input {
  border: 1px solid var(--cc-rule) !important;
  border-radius: 0 !important;
  background: #FFFFFF;
}

.wp-block-search__button {
  background: var(--cc-copper) !important;
  color: #FFFFFF !important;
  border-radius: 0 !important;
  font-family: 'Libre Franklin', sans-serif;
}

/* ---------- Mobile ---------- */

@media (max-width: 600px) {
  .cc-section-nav ul.wp-block-navigation {
    gap: 1.25rem;
    flex-wrap: wrap;
  }
  .cc-spotlight {
    padding: 1.75rem;
  }
}

/* ---------- Reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  * {
    transition: none !important;
  }
}
