/*
Theme Name: Calcio Inglese
Theme URI: https://calcioinglese.org
Author: Calcio Inglese
Description: Кастомная тема, воссоздающая дизайн старого Astro-сайта calcioinglese.org на WordPress.
Version: 1.0
Requires PHP: 8.0
Text Domain: calcio-inglese
*/

:root {
  --navy: #0b1930;
  --navy-2: #122544;
  --green: #16a34a;
  --green-dark: #0e7c38;
  --amber: #f5a623;
  --bg: #f4f5f7;
  --white: #fff;
  --ink: #111827;
  --gray: #6b7280;
  --line: #e5e7eb;
  --wrap: 1180px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  font-size: 16px;
  line-height: 1.5;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, .display {
  font-family: 'Archivo Black', 'Inter', sans-serif;
  font-weight: 400;
  margin: 0;
}
.wrap { max-width: var(--wrap); margin: 0 auto; padding: 0 20px; }
:focus-visible { outline: 3px solid var(--green); outline-offset: 2px; }
@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; transition-duration: 0.001ms !important; }
}

.ticker {
  background: var(--green);
  color: var(--white);
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: .03em;
}
.ticker .wrap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 8px;
  padding-bottom: 8px;
  gap: 12px;
  flex-wrap: wrap;
}

.site-logo-band {
  background: var(--navy);
  text-align: center;
  padding: 22px 20px;
}
.site-logo-band img { margin: 0 auto; max-height: 90px; }
.site-logo-band .text-logo {
  color: var(--white);
  font-family: 'Archivo Black', sans-serif;
  font-size: 22px;
}
.site-logo-band .text-logo span { color: var(--green); }

.site-nav-bar { background: var(--navy-2); border-top: 1px solid rgba(255,255,255,.08); }
.site-nav-bar .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 58px;
  gap: 20px;
}
.brand-wordmark {
  color: var(--white);
  font-family: 'Archivo Black', sans-serif;
  font-size: 17px;
  letter-spacing: .01em;
  white-space: nowrap;
}
.brand-wordmark span { color: var(--green); }

.primary-nav { display: flex; gap: 28px; }
.primary-nav a {
  color: rgba(255,255,255,.82);
  font-weight: 700;
  font-size: 14.5px;
  padding: 20px 0;
  position: relative;
}
.primary-nav a:hover, .primary-nav a.current { color: var(--white); }
.primary-nav a.current::after {
  content: '';
  position: absolute; left: 0; right: 0; bottom: 0;
  height: 3px; background: var(--green); border-radius: 2px;
}

.nav-toggle {
  display: none;
  background: none; border: 0; color: var(--white);
  font-size: 26px; line-height: 1; cursor: pointer;
  min-width: 44px; min-height: 44px;
}

@media (max-width: 860px) {
  .primary-nav {
    display: none;
    position: absolute;
    top: 100%; left: 0; right: 0;
    background: var(--navy-2);
    flex-direction: column;
    gap: 0;
    padding: 6px 20px 18px;
    border-top: 1px solid rgba(255,255,255,.08);
  }
  .primary-nav.is-open { display: flex; }
  .primary-nav a { padding: 12px 0; border-bottom: 1px solid rgba(255,255,255,.06); }
  .site-nav-bar { position: relative; }
  .nav-toggle { display: block; }
}

.cat-pill {
  display: inline-block;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: .05em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 3px;
  background: #cfe4ff;
  color: #1b3a63;
}
.cat-pill.cat-transfer-news { background: var(--amber); color: #3a2400; }
.cat-pill.cat-club-news { background: #cfe4ff; color: #1b3a63; }
.cat-pill.cat-match-report { background: #d6f5df; color: var(--green-dark); }
.cat-pill.cat-analysis { background: #ece0ff; color: #4a2c8f; }
.cat-pill.cat-injury-news { background: #ffd9d9; color: #7a1414; }
.cat-pill.cat-pre-season { background: #fff2c2; color: #665300; }
.cat-label {
  font-size: 11px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase;
  color: var(--green-dark);
}

.card-thumb {
  position: relative;
  aspect-ratio: 16/9.4;
  background: var(--navy);
  border-radius: 10px 10px 0 0;
  overflow: hidden;
  display: flex; align-items: flex-end;
}
.card-thumb::after {
  content: '';
  position: absolute; top: -30%; right: -15%;
  width: 60%; height: 160%;
  background: var(--navy-2);
  border-radius: 50%;
}
.card-thumb .cat-pill { position: absolute; top: 14px; left: 14px; z-index: 2; }
.card-thumb .thumb-word {
  position: relative; z-index: 2;
  padding: 0 18px 18px;
  font-family: 'Archivo Black', sans-serif;
  color: var(--white);
  font-size: 22px;
  line-height: 1.15;
}
.card-thumb .thumb-word span { display: block; color: var(--green); }
.card-thumb.has-image { background-size: cover; background-position: center; }
.card-thumb.has-image::after { display: none; }
.card-thumb.has-image img { width: 100%; height: 100%; object-fit: cover; position: relative; z-index: 1; }

.hero-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 24px; margin-top: 26px; }
.hero-card { background: var(--white); border-radius: 10px; overflow: hidden; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.hero-card .card-thumb { aspect-ratio: 16/10; }
.hero-card .card-body { padding: 20px 22px 24px; }
.hero-card h2 { font-size: 28px; line-height: 1.2; margin-bottom: 10px; }
.hero-card p.dek { color: var(--gray); font-size: 15.5px; margin: 0 0 10px; }
.hero-side { display: flex; flex-direction: column; gap: 20px; }
.hero-side .hero-card .card-thumb { aspect-ratio: 16/9; }
.hero-side .hero-card h2 { font-size: 17px; }
.meta-line { color: var(--gray); font-size: 12.5px; font-weight: 600; }

.sec-head {
  display: flex; align-items: baseline; justify-content: space-between;
  margin: 46px 0 18px;
}
.sec-head h2 { font-size: 21px; }
.sec-head a { color: var(--green-dark); font-weight: 700; font-size: 13.5px; }

.content-layout { display: grid; grid-template-columns: 1fr 320px; gap: 30px; align-items: start; }
.news-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.news-grid .hero-card h2 { font-size: 16.5px; line-height: 1.3; }
.news-grid .card-body { padding: 14px 16px 18px; }

@media (max-width: 980px) {
  .hero-grid { grid-template-columns: 1fr; }
  .content-layout { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .news-grid { grid-template-columns: 1fr; }
}

.widget-box { background: var(--white); border-radius: 10px; padding: 18px 18px 20px; margin-bottom: 20px; box-shadow: 0 1px 2px rgba(0,0,0,.04); }
.widget-box h3 { font-size: 15px; margin-bottom: 4px; }
.widget-box .widget-sub { font-size: 12px; color: var(--gray); margin-bottom: 12px; }

.standings-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.standings-table th { text-align: left; color: var(--gray); font-weight: 600; font-size: 11px; padding: 4px 6px; }
.standings-table td { padding: 6px 6px; border-top: 1px solid var(--line); }
.standings-table tr.zone-cl td:first-child { border-left: 3px solid #3b6fd8; }
.standings-table tr.zone-el td:first-child { border-left: 3px solid var(--amber); }
.standings-table tr.zone-ecl td:first-child { border-left: 3px solid var(--green); }
.standings-table tr.zone-rel td:first-child { border-left: 3px solid #c0392b; }
.standings-table .club-dot { display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 7px; vertical-align: middle; }
.standings-table .pts { font-weight: 800; }
.standings-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 12px; font-size: 11px; color: var(--gray); }
.standings-legend span { display: inline-flex; align-items: center; gap: 5px; }
.standings-legend i { width: 9px; height: 9px; border-radius: 50%; display: inline-block; }

.fixture-item { padding: 10px 0; border-top: 1px solid var(--line); font-size: 13.5px; }
.fixture-item:first-child { border-top: 0; padding-top: 0; }
.fixture-item .fx-date { color: var(--gray); font-size: 11.5px; font-weight: 700; text-transform: uppercase; margin-bottom: 3px; }
.fixture-item .fx-teams { font-weight: 700; }
.widget-box .see-all { display: block; margin-top: 12px; font-size: 13px; font-weight: 700; color: var(--green-dark); }

.trending-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.trending-tags a {
  background: var(--bg); border: 1px solid var(--line); border-radius: 20px;
  padding: 6px 12px; font-size: 12.5px; font-weight: 700;
}
.trending-tags a:hover { border-color: var(--green); color: var(--green-dark); }

.article-page { max-width: 760px; padding-top: 28px; padding-bottom: 60px; margin: 0 auto; }
.breadcrumb { font-size: 12.5px; color: var(--gray); margin-bottom: 16px; }
.breadcrumb a { color: var(--gray); }
.article-page h1 { font-size: 32px; line-height: 1.2; margin-bottom: 14px; }
.article-page .dek { font-size: 17px; color: var(--gray); margin-bottom: 14px; }
.article-page .byline { font-size: 13px; color: var(--gray); font-weight: 600; margin-bottom: 22px; }
.article-page .byline b { color: var(--ink); }
.hero-thumb { border-radius: 10px; overflow: hidden; margin-bottom: 26px; }
.hero-thumb img { width: 100%; height: auto; display: block; }
.prose { font-size: 17px; line-height: 1.75; color: var(--ink); }
.prose p { margin-bottom: 20px; }
.prose h2 { font-family: 'Archivo Black', sans-serif; font-size: 22px; margin: 32px 0 14px; }
.prose blockquote {
  border-left: 4px solid var(--green); padding-left: 16px; margin: 24px 0;
  font-style: italic; color: var(--gray);
}
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 30px; }
.tags a {
  background: var(--bg); border: 1px solid var(--line); border-radius: 20px;
  padding: 6px 12px; font-size: 12.5px; font-weight: 700;
}
.related { margin-top: 50px; }
.related-grid { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 16px; }

@media (max-width: 860px) {
  .article-page h1 { font-size: 24px; }
  .related-grid { grid-template-columns: 1fr; }
}

.archive-header { padding: 30px 0 6px; }
.archive-header h1 { font-size: 26px; }
.archive-list { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 18px; margin: 24px 0 40px; }
@media (max-width: 860px) { .archive-list { grid-template-columns: 1fr; } }

.pagination { display: flex; gap: 10px; justify-content: center; margin: 20px 0 50px; }
.pagination a, .pagination span {
  padding: 8px 14px; border-radius: 6px; background: var(--white); border: 1px solid var(--line);
  font-weight: 700; font-size: 13px;
}
.pagination .current { background: var(--navy); color: var(--white); border-color: var(--navy); }

.site-footer { background: var(--navy); color: rgba(255,255,255,.75); margin-top: 60px; padding: 46px 0 26px; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 30px; }
.footer-grid img { max-height: 40px; margin-bottom: 10px; }
.footer-grid p { font-size: 13.5px; line-height: 1.6; max-width: 340px; }
.footer-grid h4 { color: var(--white); font-size: 13px; letter-spacing: .04em; margin-bottom: 12px; }
.footer-grid ul { list-style: none; margin: 0; padding: 0; }
.footer-grid li { margin-bottom: 9px; font-size: 13.5px; }
.footer-grid a:hover { color: var(--white); }
.footer-bottom {
  margin-top: 34px; padding-top: 20px; border-top: 1px solid rgba(255,255,255,.1);
  font-size: 12.5px; color: rgba(255,255,255,.5);
}
@media (max-width: 700px) { .footer-grid { grid-template-columns: 1fr; } }

.error-404 { text-align: center; padding: 90px 20px; }
.error-404 h1 { font-size: 64px; color: var(--navy); }
.error-404 a { color: var(--green-dark); font-weight: 700; }
