/*
Theme Name: Rassegna Economia
Theme URI: https://example.com/rassegna-economia
Author: Smart Italy Communications
Author URI: https://example.com
Description: Tema editoriale WordPress per un sito finanziario con homepage configurabile, ricerca in header, pubblicita e lettura continua degli articoli.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.6
Requires PHP: 7.4
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: rassegna-economia
*/

:root {
  --vf-black: #050505;
  --vf-ink: #111111;
  --vf-muted: #646464;
  --vf-line: #dedede;
  --vf-surface: #ffffff;
  --vf-purple: #9147ff;
  --vf-pink: #d94bc5;
  --vf-orange: #ff934a;
  --vf-blue: #0d5b94;
  --vf-radius: 6px;
  --vf-shadow: 0 18px 44px rgba(0, 0, 0, .2);
  --vf-content: 1120px;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  color: var(--vf-ink);
  background: #fff;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  line-height: 1.45;
}

a { color: inherit; text-decoration: none; }
a:hover { color: var(--vf-purple); }
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;
}

.vf-wrap {
  width: min(var(--vf-content), calc(100% - 40px));
  margin-inline: auto;
}

.vf-site-header {
  position: sticky;
  top: 0;
  z-index: 30;
  background: #000;
  color: #fff;
  border-bottom: 1px solid rgba(255,255,255,.14);
}

.admin-bar .vf-site-header { top: 32px; }

.vf-header-inner {
  min-height: 78px;
  display: flex;
  align-items: center;
  gap: 28px;
}

.vf-logo {
  flex: 0 0 auto;
  font-size: clamp(25px, 3vw, 33px);
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1;
  background: linear-gradient(90deg, var(--vf-purple), #ec5ca6 55%, var(--vf-orange));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.vf-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 24px;
  font-size: 14px;
  font-weight: 650;
}

.vf-nav ul {
  display: flex;
  align-items: center;
  gap: 24px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.vf-header-tools {
  display: flex;
  align-items: center;
  gap: 14px;
}

.vf-search-toggle,
.vf-menu-toggle,
.vf-icon-link {
  width: 36px;
  height: 36px;
  display: inline-grid;
  place-items: center;
  border: 0;
  color: #fff;
  background: transparent;
  cursor: pointer;
}

.vf-menu-toggle { display: none; }

.vf-search-panel {
  display: none;
  padding: 0 0 18px;
}

.vf-search-panel.is-open { display: block; }

.vf-search-form {
  display: flex;
  gap: 10px;
}

.vf-search-form input[type="search"],
.vf-newsletter input[type="email"] {
  width: 100%;
  min-height: 46px;
  border: 1px solid rgba(255,255,255,.22);
  background: rgba(255,255,255,.08);
  color: #fff;
  border-radius: var(--vf-radius);
  padding: 0 16px;
  font: inherit;
}

.vf-search-form input[type="search"]::placeholder,
.vf-newsletter input[type="email"]::placeholder { color: rgba(255,255,255,.7); }

.vf-button,
.vf-search-form button,
.vf-newsletter button {
  min-height: 46px;
  border-radius: var(--vf-radius);
  border: 1px solid currentColor;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 0 22px;
  font-weight: 850;
  font-size: 13px;
  text-transform: uppercase;
  cursor: pointer;
  color: inherit;
  background: transparent;
}

.vf-button:hover {
  color: #fff;
  background: linear-gradient(90deg, var(--vf-purple), var(--vf-orange));
  border-color: transparent;
}

.vf-gradient-button,
.vf-search-form button,
.vf-newsletter button {
  color: #fff;
  border-color: transparent;
  background: linear-gradient(90deg, var(--vf-pink), var(--vf-orange));
}

.vf-hero {
  min-height: 475px;
  display: flex;
  align-items: center;
  color: #fff;
  background-color: #06080c;
  background-size: cover;
  background-position: center;
  position: relative;
}

.vf-hero::before,
.vf-image-card::before,
.vf-mini-feature::before,
.vf-article-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, rgba(0,0,0,.86) 0%, rgba(0,0,0,.54) 42%, rgba(0,0,0,.08) 100%);
}

.vf-hero-content {
  position: relative;
  width: min(620px, 92%);
  padding: 72px 0;
}

.vf-kicker {
  display: inline-block;
  color: var(--vf-orange);
  font-weight: 900;
  font-size: 13px;
  text-transform: uppercase;
}

.vf-kicker.is-purple { color: var(--vf-purple); }
.vf-kicker.is-pink { color: var(--vf-pink); }

.vf-hero h1,
.vf-article-hero h1 {
  margin: 18px 0 20px;
  font-size: clamp(38px, 5vw, 58px);
  line-height: 1.03;
  letter-spacing: 0;
}

.vf-hero p {
  max-width: 600px;
  margin: 0 0 32px;
  font-size: clamp(18px, 2vw, 22px);
}

.vf-mini-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  background: #000;
}

.vf-mini-feature {
  min-height: 170px;
  position: relative;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  color: #fff;
  background: #111 center / cover;
}

.vf-mini-feature::before {
  background: linear-gradient(100deg, rgba(0,0,0,.95), rgba(0,0,0,.44));
}

.vf-mini-feature-inner {
  position: relative;
  padding: 26px 34px;
  width: 100%;
}

.vf-mini-feature h2 {
  margin: 18px 0 20px;
  max-width: 310px;
  font-size: 19px;
  line-height: 1.25;
}

.vf-arrow {
  font-size: 30px;
  line-height: 1;
  color: var(--vf-orange);
}

.vf-section {
  padding: 42px 0;
}

.vf-section + .vf-section .vf-wrap {
  border-top: 1px solid var(--vf-line);
  padding-top: 34px;
}

.vf-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 24px;
}

.vf-section-title {
  margin: 0;
  font-size: clamp(26px, 3vw, 34px);
  line-height: 1.1;
}

.vf-featured-grid {
  display: grid;
  grid-template-columns: 1.1fr .72fr .72fr;
  gap: 22px;
}

.vf-image-card {
  min-height: 190px;
  position: relative;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  color: #fff;
  border-radius: var(--vf-radius);
  background: #171717 center / cover;
  box-shadow: var(--vf-shadow);
}

.vf-image-card::before {
  background: linear-gradient(180deg, rgba(0,0,0,.08), rgba(0,0,0,.88));
}

.vf-image-card.is-large {
  min-height: 410px;
  grid-row: span 2;
}

.vf-card-content {
  position: relative;
  padding: 22px;
  width: 100%;
}

.vf-image-card h3 {
  margin: 12px 0 12px;
  font-size: 20px;
  line-height: 1.2;
}

.vf-image-card.is-large h3 { font-size: 27px; }

.vf-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: rgba(255,255,255,.88);
  font-size: 13px;
}

.vf-meta a { color: inherit; text-decoration: underline; text-underline-offset: 3px; }

.vf-more-row {
  display: flex;
  justify-content: center;
  margin-top: 28px;
}

.vf-latest-list {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 24px;
}

.vf-latest-card {
  display: grid;
  grid-template-columns: 96px 1fr;
  gap: 14px;
  align-items: start;
}

.vf-latest-card img {
  width: 96px;
  height: 96px;
  object-fit: cover;
  border-radius: var(--vf-radius);
}

.vf-latest-card h3 {
  margin: 6px 0;
  font-size: 15px;
  line-height: 1.22;
}

.vf-date { color: var(--vf-muted); font-size: 13px; }

.vf-opinion-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.vf-opinion-card {
  border-top: 4px solid var(--vf-purple);
  padding: 20px;
  background: #f7f7f7;
  border-radius: var(--vf-radius);
}

.vf-opinion-card h3 {
  margin: 10px 0;
  font-size: 21px;
  line-height: 1.22;
}

.vf-ad {
  width: min(var(--vf-content), calc(100% - 40px));
  min-height: 90px;
  margin: 28px auto;
  display: grid;
  place-items: center;
  overflow: hidden;
  border: 1px dashed #b9b9b9;
  border-radius: var(--vf-radius);
  background: #f3f3f3;
  color: #777;
  font-size: 13px;
  text-align: center;
}

.vf-ad iframe,
.vf-ad img { max-width: 100%; }

.vf-newsletter {
  margin-top: 30px;
  padding: 28px 32px;
  display: grid;
  grid-template-columns: 1fr 1.8fr;
  gap: 30px;
  align-items: center;
  color: #fff;
  background: #050505;
  border-radius: var(--vf-radius);
}

.vf-newsletter h2 {
  margin: 0 0 4px;
  font-size: 24px;
}

.vf-newsletter p { margin: 0; }
.vf-newsletter form { display: grid; grid-template-columns: 1fr 180px; gap: 12px; }

.vf-site-footer {
  padding: 32px 0;
  color: #464646;
}

.vf-footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  font-size: 13px;
}

.vf-footer-links {
  display: flex;
  gap: 28px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.vf-article-hero {
  min-height: 430px;
  position: relative;
  display: flex;
  align-items: flex-end;
  color: #fff;
  background: #050505 center / cover;
}

.vf-article-hero .vf-wrap {
  position: relative;
  padding-top: 90px;
  padding-bottom: 58px;
}

.vf-article-main {
  display: grid;
  grid-template-columns: minmax(0, 740px) 300px;
  gap: 56px;
  padding: 44px 0;
}

.vf-content {
  font-size: 19px;
  line-height: 1.75;
}

.vf-content p { margin: 0 0 1.35em; }
.vf-content a { color: var(--vf-purple); text-decoration: underline; text-underline-offset: 3px; }
.vf-content h2, .vf-content h3 { line-height: 1.18; margin: 1.35em 0 .55em; }

.vf-sidebar {
  position: sticky;
  top: 110px;
  align-self: start;
}

.vf-author-box {
  margin-top: 34px;
  padding: 24px;
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 18px;
  border: 1px solid var(--vf-line);
  border-radius: var(--vf-radius);
  background: #fafafa;
}

.vf-author-box img { border-radius: 50%; }
.vf-author-box h2 { margin: 0 0 8px; font-size: 21px; }
.vf-author-box p { margin: 0 0 12px; color: #454545; }

.vf-next-post {
  margin-top: 34px;
  padding: 24px;
  color: #fff;
  background: #050505;
  border-radius: var(--vf-radius);
}

.vf-next-post h2 { margin: 8px 0 0; }

.vf-archive-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
}

.vf-load-more {
  margin: 34px auto 0;
  display: flex;
}

.vf-empty {
  padding: 70px 0;
}

@media (max-width: 980px) {
  .vf-menu-toggle { display: inline-grid; }
  .vf-nav {
    position: absolute;
    inset: 78px 0 auto;
    display: none;
    margin: 0;
    padding: 18px 20px 24px;
    background: #000;
    border-top: 1px solid rgba(255,255,255,.14);
  }
  .vf-nav.is-open,
  .vf-nav ul { display: grid; }
  .vf-nav ul { gap: 14px; }
  .vf-header-inner { gap: 16px; }
  .vf-header-tools { margin-left: auto; }
  .vf-mini-grid,
  .vf-featured-grid,
  .vf-latest-list,
  .vf-opinion-grid,
  .vf-archive-grid,
  .vf-article-main,
  .vf-newsletter { grid-template-columns: 1fr; }
  .vf-image-card.is-large { grid-row: auto; }
  .vf-latest-list { gap: 18px; }
  .vf-sidebar { position: static; }
}

@media (max-width: 640px) {
  .admin-bar .vf-site-header { top: 0; }
  .vf-wrap { width: min(100% - 28px, var(--vf-content)); }
  .vf-logo { font-size: 25px; }
  .vf-hero { min-height: 520px; }
  .vf-hero h1,
  .vf-article-hero h1 { font-size: 39px; }
  .vf-mini-feature-inner,
  .vf-card-content { padding: 20px; }
  .vf-newsletter { padding: 22px; }
  .vf-newsletter form,
  .vf-author-box { grid-template-columns: 1fr; }
  .vf-footer-inner { align-items: flex-start; flex-direction: column; }
  .vf-footer-links { flex-wrap: wrap; gap: 16px; }
}
