/*
Theme Name: Officine Teatrali
Theme URI: https://officineteatrali.com
Author: Officine Teatrali
Description: Tema editoriale su misura per Officine Teatrali, ispirato ai programmi di sala.
Version: 1.1.0
Requires at least: 6.4
Tested up to: 6.7
Requires PHP: 7.4
Text Domain: officine-teatrali
*/

:root {
  --paper: #f3eee4;
  --paper-light: #fbf8f1;
  --ink: #171512;
  --muted: #726b61;
  --wine: #851f2d;
  --wine-dark: #5e101b;
  --rule: #cfc5b6;
  --serif: Georgia, "Times New Roman", serif;
  --sans: "Helvetica Neue", Helvetica, Arial, sans-serif;
  --wrap: 1240px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.68;
  text-rendering: optimizeLegibility;
}
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: .18em; }
a:hover { color: var(--wine); }
img { display: block; max-width: 100%; height: auto; }
.screen-reader-text {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0;
}
.skip-link:focus {
  position: fixed; z-index: 9999; top: 1rem; left: 1rem; width: auto; height: auto;
  clip: auto; padding: .7rem 1rem; margin: 0; background: var(--ink); color: #fff;
}
.site-wrap { width: min(calc(100% - 40px), var(--wrap)); margin-inline: auto; }

.site-header {
  position: relative; z-index: 20; border-bottom: 1px solid var(--rule);
  background: rgba(243,238,228,.96);
}
.header-inner {
  min-height: 104px; display: flex; align-items: center; justify-content: flex-start;
}
.brand { display: inline-flex; align-items: center; gap: 16px; text-decoration: none; }
.brand .custom-logo { max-height: 64px; width: auto; }
.brand-name {
  display: block; font-family: var(--serif); font-size: clamp(1.4rem,2.2vw,2rem);
  font-weight: 700; line-height: 1; letter-spacing: -.03em;
}
.brand-kicker {
  display: block; margin-top: 7px; color: var(--muted); font-size: .7rem;
  letter-spacing: .18em; text-transform: uppercase;
}
.button {
  display: inline-flex; align-items: center; justify-content: center; min-height: 46px;
  padding: .72rem 1.15rem; border: 1px solid var(--wine); background: var(--wine);
  color: #fff; font-size: .75rem; font-weight: 800; letter-spacing: .08em;
  text-decoration: none; text-transform: uppercase; transition: .2s ease;
}
.button:hover { background: var(--wine-dark); color: #fff; transform: translateY(-1px); }
.button--ghost { background: transparent; color: var(--ink); border-color: var(--ink); }
.button--ghost:hover { background: var(--ink); color: #fff; }

.hero {
  min-height: 68vh; display: grid; grid-template-columns: 1.05fr .95fr;
  border-bottom: 1px solid var(--rule); background: var(--paper-light);
}
.hero-copy { display: flex; flex-direction: column; justify-content: center; padding: clamp(50px,8vw,120px) max(30px,6vw); }
.eyebrow {
  margin: 0 0 1.2rem; color: var(--wine); font-size: .72rem; font-weight: 800;
  letter-spacing: .2em; text-transform: uppercase;
}
.hero h1, .page-title, .entry-title {
  margin: 0; font-family: var(--serif); font-weight: 500; letter-spacing: -.045em;
  line-height: .98;
}
.hero h1 { font-size: clamp(3.3rem,7vw,7.2rem); }
.hero-deck { max-width: 680px; margin: 1.7rem 0 0; font-family: var(--serif); font-size: clamp(1.1rem,1.8vw,1.45rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 2rem; }
.hero-media { min-height: 480px; background: #26221d; overflow: hidden; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; filter: saturate(.82) contrast(1.04); }
.hero-placeholder {
  height: 100%; display: grid; place-items: center; padding: 3rem;
  background: radial-gradient(circle at 65% 35%, #a0444f 0, #5e101b 28%, #191512 75%);
  color: var(--paper); font-family: var(--serif); font-size: clamp(2rem,5vw,5rem); text-align: center;
}

.intro-band { padding: clamp(60px,9vw,120px) 0; border-bottom: 1px solid var(--rule); }
.intro-grid { display: grid; grid-template-columns: .45fr 1.55fr; gap: clamp(30px,7vw,100px); }
.section-number { color: var(--wine); font: 700 .72rem/1 var(--sans); letter-spacing: .18em; text-transform: uppercase; }
.intro-copy { max-width: 900px; }
.intro-copy h2, .section-heading {
  margin: 0; font-family: var(--serif); font-size: clamp(2.2rem,4.2vw,4.5rem);
  font-weight: 500; letter-spacing: -.04em; line-height: 1.05;
}
.intro-copy p { max-width: 760px; margin: 1.5rem 0 0; font-size: 1.1rem; }
.text-link { display: inline-block; margin-top: 1.25rem; color: var(--wine); font-weight: 800; font-size: .77rem; letter-spacing: .08em; text-transform: uppercase; }

.editorial { padding: clamp(60px,8vw,110px) 0; }
.section-head {
  display: flex; justify-content: space-between; align-items: end; gap: 20px;
  margin-bottom: 36px; padding-bottom: 18px; border-bottom: 1px solid var(--ink);
}
.section-head .section-heading { font-size: clamp(2rem,3.4vw,3.8rem); }
.cards {
  display: grid; grid-template-columns: repeat(12,1fr); gap: 32px 24px;
}
.card { grid-column: span 4; border-top: 1px solid var(--rule); padding-top: 14px; }
.card:nth-child(1), .card:nth-child(5) { grid-column: span 8; }
.card-media { position: relative; aspect-ratio: 4/3; overflow: hidden; background: #d8cfc1; }
.card:nth-child(1) .card-media, .card:nth-child(5) .card-media { aspect-ratio: 16/9; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card-media img { transform: scale(1.025); }
.card-meta { display: flex; justify-content: space-between; gap: 12px; margin-top: 15px; color: var(--muted); font-size: .68rem; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; }
.card-category { color: var(--wine); }
.card-title { margin: .65rem 0 0; font-family: var(--serif); font-size: clamp(1.45rem,2vw,2.25rem); line-height: 1.08; letter-spacing: -.025em; }
.card-title a { text-decoration: none; }
.card-excerpt { margin: .75rem 0 0; color: #4f4a44; font-size: .92rem; line-height: 1.55; }

.activity-grid {
  display: grid; grid-template-columns: repeat(12,1fr); gap: 24px;
}
.activity-card {
  position: relative; grid-column: span 6; min-height: 460px; overflow: hidden;
  background: #2b2621;
}
.activity-card:nth-child(1), .activity-card:nth-child(4) { grid-column: span 7; }
.activity-card:nth-child(2), .activity-card:nth-child(3) { grid-column: span 5; }
.activity-card a { position: absolute; inset: 0; color: #fff; text-decoration: none; }
.activity-card img {
  width: 100%; height: 100%; object-fit: cover; filter: saturate(.78) contrast(1.05);
  transition: transform .55s ease, filter .3s ease;
}
.activity-card:hover img { transform: scale(1.035); filter: saturate(.95) contrast(1.08); }
.activity-card::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(10,8,6,.06) 15%, rgba(10,8,6,.86) 100%);
}
.activity-placeholder { width: 100%; height: 100%; background: radial-gradient(circle at 70% 25%, #88404a, #241d19 70%); }
.activity-year {
  position: absolute; z-index: 2; left: 18px; top: 20px; color: #fff;
  font-size: .72rem; font-weight: 800; letter-spacing: .18em;
  writing-mode: vertical-rl; transform: rotate(180deg);
}
.activity-content { position: absolute; z-index: 2; left: 58px; right: 30px; bottom: 30px; }
.activity-category { display: block; margin-bottom: .6rem; color: #e7aab0; font-size: .68rem; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.activity-title { margin: 0; font-family: var(--serif); font-size: clamp(2rem,3.5vw,4.1rem); font-weight: 500; line-height: .98; letter-spacing: -.04em; }

.news-stream { padding: clamp(55px,7vw,90px) 0; border-top: 1px solid var(--rule); }
.news-list { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--ink); }
.news-item { border-bottom: 1px solid var(--rule); }
.news-item a {
  display: grid; grid-template-columns: 130px 1fr auto; align-items: baseline; gap: 22px;
  padding: 22px 0; text-decoration: none;
}
.news-date { color: var(--muted); font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.news-title { font-family: var(--serif); font-size: clamp(1.25rem,2.2vw,2rem); line-height: 1.1; }
.news-arrow { color: var(--wine); font-size: 1.4rem; transition: transform .2s ease; }
.news-item a:hover .news-arrow { transform: translateX(5px); }

.archive-band { padding: clamp(60px,8vw,110px) 0; background: var(--ink); color: var(--paper); }
.archive-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(40px,8vw,120px); align-items: end; }
.archive-band .eyebrow { color: #d88a91; }
.archive-band .section-heading { max-width: 700px; }
.archive-copy p { max-width: 620px; color: #d7d0c5; }
.archive-band .button--ghost { color: var(--paper); border-color: var(--paper); }
.archive-band .button--ghost:hover { background: var(--paper); color: var(--ink); }

.support-band { padding: clamp(55px,7vw,90px) 0; background: var(--wine); color: #fff; }
.support-inner { display: grid; grid-template-columns: 1.5fr auto; gap: 40px; align-items: center; }
.support-inner h2 { margin: 0; font-family: var(--serif); font-size: clamp(2.2rem,4vw,4.2rem); line-height: 1; font-weight: 500; }
.support-inner p { margin: 1rem 0 0; max-width: 700px; }
.support-inner .button { background: #fff; color: var(--wine); border-color: #fff; }
.support-inner .button:hover { background: var(--ink); color: #fff; border-color: var(--ink); }

.content-shell { width: min(calc(100% - 40px), 920px); margin: 0 auto; padding: clamp(60px,9vw,120px) 0; }
.page-header { padding-bottom: 35px; margin-bottom: 45px; border-bottom: 1px solid var(--rule); }
.page-title, .entry-title { font-size: clamp(2.8rem,6vw,6rem); }
.entry-meta { margin-top: 1.2rem; color: var(--muted); font-size: .73rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; }
.entry-featured { margin: 0 0 45px; }
.entry-content { font-family: var(--serif); font-size: clamp(1.08rem,1.6vw,1.25rem); }
.entry-content > * { max-width: 760px; margin-left: auto; margin-right: auto; }
.entry-content > .alignwide { max-width: 1080px; }
.entry-content > .alignfull { max-width: none; width: 100vw; margin-left: calc(50% - 50vw); }
.entry-content h2, .entry-content h3 { margin-top: 2.2em; line-height: 1.15; }
.entry-content h2 { font-size: 2rem; }
.entry-content blockquote { border-left: 4px solid var(--wine); padding-left: 1.5rem; font-size: 1.35em; }
.pagination { display: flex; justify-content: space-between; margin-top: 60px; padding-top: 24px; border-top: 1px solid var(--rule); }

.site-footer { background: #0f0e0c; color: #d5cec2; padding: 65px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 1.2fr .8fr .8fr; gap: 40px; }
.footer-brand { color: #fff; font-family: var(--serif); font-size: 2rem; }
.footer-title { margin: 0 0 1rem; color: #fff; font-size: .72rem; letter-spacing: .15em; text-transform: uppercase; }
.footer-menu { list-style: none; padding: 0; margin: 0; }
.footer-menu li { margin: .4rem 0; }
.footer-menu a { text-decoration: none; }
.footer-bottom { margin-top: 55px; padding-top: 20px; border-top: 1px solid #39352f; color: #918a80; font-size: .74rem; }

@media (max-width: 980px) {
  .header-inner { min-height: 86px; }
  .hero { grid-template-columns: 1fr; }
  .hero-copy { order: 2; }
  .hero-media { min-height: 48vh; }
  .intro-grid, .archive-grid { grid-template-columns: 1fr; }
  .card, .card:nth-child(1), .card:nth-child(5) { grid-column: span 6; }
  .activity-card, .activity-card:nth-child(n) { grid-column: span 6; min-height: 400px; }
  .support-inner { grid-template-columns: 1fr; }
}

@media (max-width: 640px) {
  body { font-size: 16px; }
  .site-wrap, .content-shell { width: min(calc(100% - 28px), var(--wrap)); }
  .brand-kicker { display: none; }
  .hero h1 { font-size: clamp(3rem,17vw,5rem); }
  .hero-media { min-height: 360px; }
  .cards { display: block; }
  .card { margin-bottom: 38px; }
  .activity-grid { display: block; }
  .activity-card { margin-bottom: 14px; min-height: 370px; }
  .news-item a { grid-template-columns: 1fr auto; gap: 8px 16px; }
  .news-date { grid-column: 1 / -1; }
  .section-head { align-items: flex-start; flex-direction: column; }
  .footer-grid { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition: none !important; }
}
