/*
Theme Name: Profe Claudio
Theme URI: https://profeclaudionieto.substack.com
Author: Profe Claudio
Description: Tema limpio para la web personal de Profe Claudio con integracion oficial de Substack en la home.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
Text Domain: profe-claudio
*/

:root {
  --pc-color-text: #161616;
  --pc-color-muted: #565656;
  --pc-color-soft: #f6f4ef;
  --pc-color-border: #e7e0d4;
  --pc-color-accent: #1f6f5b;
  --pc-color-accent-dark: #174d40;
  --pc-font-sans: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --pc-max-page: 1120px;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--pc-color-text);
  background: #fff;
  font-family: var(--pc-font-sans);
  line-height: 1.6;
}

a {
  color: var(--pc-color-accent-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

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

.site-header {
  border-bottom: 1px solid rgba(22, 22, 22, 0.08);
  background: rgba(255, 255, 255, 0.94);
}

.site-header__inner,
.pc-section__inner {
  width: min(calc(100% - 40px), var(--pc-max-page));
  margin: 0 auto;
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 72px;
  gap: 24px;
}

.site-branding {
  color: var(--pc-color-text);
  font-size: 1.05rem;
  font-weight: 800;
  letter-spacing: 0;
  text-decoration: none;
}

.main-navigation ul {
  display: flex;
  align-items: center;
  gap: 22px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.main-navigation a {
  color: var(--pc-color-text);
  font-size: 0.95rem;
  font-weight: 650;
  text-decoration: none;
}

.main-navigation a:hover {
  color: var(--pc-color-accent-dark);
}

.pc-section {
  padding: clamp(56px, 8vw, 96px) 0;
}

.pc-hero {
  background: linear-gradient(180deg, #fff 0%, var(--pc-color-soft) 100%);
}

.pc-hero__content {
  max-width: 760px;
}

.pc-eyebrow {
  margin: 0 0 14px;
  color: var(--pc-color-accent-dark);
  font-size: 0.92rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.pc-hero h1,
.pc-book h2,
.profe-newsletter h2 {
  margin: 0;
  color: var(--pc-color-text);
  font-weight: 850;
  line-height: 1.08;
  letter-spacing: 0;
}

.pc-hero h1 {
  max-width: 820px;
  font-size: clamp(2.3rem, 6vw, 4.9rem);
}

.pc-hero__lead {
  max-width: 680px;
  margin: 24px 0 0;
  color: #343434;
  font-size: clamp(1.08rem, 2vw, 1.28rem);
}

.pc-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 32px;
}

.pc-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid var(--pc-color-accent-dark);
  border-radius: 6px;
  background: var(--pc-color-accent-dark);
  color: #fff;
  font-weight: 750;
  text-decoration: none;
}

.pc-button:hover {
  background: var(--pc-color-accent);
  color: #fff;
}

.pc-button--secondary {
  background: transparent;
  color: var(--pc-color-accent-dark);
}

.pc-button--secondary:hover {
  background: rgba(31, 111, 91, 0.08);
  color: var(--pc-color-accent-dark);
}

.profe-newsletter {
  background: #fff;
  border-top: 1px solid rgba(22, 22, 22, 0.06);
  border-bottom: 1px solid rgba(22, 22, 22, 0.06);
}

.profe-newsletter__inner {
  width: min(calc(100% - 40px), 860px);
  margin: 0 auto;
  text-align: center;
}

.profe-newsletter h2 {
  font-size: clamp(2rem, 4vw, 3.35rem);
}

.profe-newsletter__text {
  max-width: 760px;
  margin: 22px auto 0;
  color: #303030;
  font-size: clamp(1.03rem, 1.6vw, 1.18rem);
}

.profe-newsletter__form {
  width: min(100%, 520px);
  margin: 34px auto 0;
  overflow: hidden;
}

.profe-newsletter__form iframe {
  display: block;
  width: 100%;
  max-width: 480px;
  height: 150px;
  margin: 0 auto;
  border: 0;
  background: transparent;
}

.profe-newsletter__note {
  margin: 14px 0 0;
  color: #424242;
  font-size: 0.96rem;
  font-weight: 650;
}

.profe-newsletter__fallback {
  display: inline-block;
  margin-top: 12px;
  color: var(--pc-color-muted);
  font-size: 0.92rem;
}

.pc-book {
  background: var(--pc-color-soft);
}

.pc-book__grid {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  gap: clamp(32px, 6vw, 72px);
  align-items: center;
}

.pc-book h2 {
  font-size: clamp(1.9rem, 3.6vw, 3rem);
}

.pc-book p {
  max-width: 620px;
  margin: 18px 0 0;
  color: #343434;
  font-size: 1.05rem;
}

.pc-book__placeholder {
  min-height: 360px;
  border: 1px solid var(--pc-color-border);
  border-radius: 8px;
  background:
    linear-gradient(145deg, rgba(31, 111, 91, 0.18), transparent 62%),
    #fff;
}

.site-footer {
  padding: 32px 0;
  border-top: 1px solid rgba(22, 22, 22, 0.08);
}

.site-footer p {
  width: min(calc(100% - 40px), var(--pc-max-page));
  margin: 0 auto;
  color: var(--pc-color-muted);
  font-size: 0.92rem;
}

@media (max-width: 760px) {
  .site-header__inner {
    align-items: flex-start;
    flex-direction: column;
    justify-content: center;
    padding: 18px 0;
  }

  .main-navigation ul {
    flex-wrap: wrap;
    gap: 12px 18px;
  }

  .pc-section {
    padding: 52px 0;
  }

  .pc-book__grid {
    grid-template-columns: 1fr;
  }

  .pc-book__placeholder {
    min-height: 260px;
  }
}

@media (max-width: 480px) {
  .site-header__inner,
  .pc-section__inner,
  .profe-newsletter__inner,
  .site-footer p {
    width: min(calc(100% - 28px), var(--pc-max-page));
  }

  .pc-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .pc-button {
    width: 100%;
  }

  .profe-newsletter__form {
    margin-top: 28px;
  }
}
