/*
Theme Name: Antonio Reda Portfolio
Theme URI: https://antonioreda.art/
Author: Antonio Reda
Description: Portfolio editoriale per filmmaker e fotografo sportivo. Progetti semplici da gestire con foto, gallerie e video.
Version: 1.0.0
Requires at least: 6.2
Tested up to: 6.8
Requires PHP: 7.4
Text Domain: antonio-reda-portfolio
*/

:root {
  --paper: #f2ebdd;
  --ink: #0b0b0a;
  --red: #e1261c;
  --grey: #aaa398;
  --line: rgba(11, 11, 10, .32);
  --pad: clamp(20px, 3.3vw, 54px);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Arial, Helvetica, sans-serif;
  overflow-x: hidden;
}
a { color: inherit; text-decoration: none; }
img { display: block; width: 100%; height: 100%; object-fit: cover; }
button { font: inherit; }
::selection { background: var(--red); color: white; }
.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; }

.site-header {
  position: relative;
  z-index: 30;
  height: 104px;
  margin: 0 var(--pad);
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--ink);
}
.brand { display: flex; flex-direction: column; line-height: 1; text-transform: uppercase; }
.brand strong {
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  font-size: clamp(1.75rem, 2.6vw, 2.75rem);
  letter-spacing: -.035em;
}
.brand span { margin-top: 8px; font-size: .64rem; letter-spacing: .16em; }
.site-nav { display: flex; gap: clamp(1rem, 3vw, 3.5rem); }
.site-nav a,
.eyebrow,
.index,
.filter-button,
.project-type,
.project-info p,
.site-footer {
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
}
.site-nav a { position: relative; padding: 12px 0; }
.site-nav a::after { content: ""; position: absolute; left: 0; bottom: 4px; width: 100%; height: 2px; background: var(--red); transform: scaleX(0); transform-origin: right; transition: transform 180ms ease; }
.site-nav a:hover::after, .site-nav a:focus-visible::after { transform: scaleX(1); transform-origin: left; }

.hero {
  position: relative;
  min-height: 780px;
  height: calc(100svh - 104px);
  max-height: 920px;
  overflow: hidden;
  border-bottom: 1px solid var(--ink);
  background-image: linear-gradient(90deg, transparent 24.95%, var(--line) 25%, transparent 25.05%, transparent 49.95%, var(--line) 50%, transparent 50.05%, transparent 74.95%, var(--line) 75%, transparent 75.05%);
}
.hero-copy { position: absolute; z-index: 5; top: 8%; left: 5.4%; }
.eyebrow { margin: 0 0 24px; }
.hero h1,
.section-title,
.archive-title,
.single-title,
.statement h2,
.contact h2 {
  margin: 0;
  font-family: Impact, Haettenschweiler, "Arial Narrow Bold", sans-serif;
  line-height: .8;
  letter-spacing: -.04em;
  text-transform: uppercase;
  font-weight: 900;
}
.hero h1 { font-size: clamp(7.2rem, 14vw, 13rem); }
.hero h1 span { display: block; animation: title-in 700ms cubic-bezier(.2,.75,.2,1) both; }
.hero h1 span:last-child { animation-delay: 100ms; }
.hero-media { position: absolute; inset: 0; z-index: 4; pointer-events: none; }
.hero-photo { position: absolute; margin: 0; overflow: hidden; border: 1px solid var(--ink); background: var(--ink); }
.hero-photo img { filter: grayscale(1) contrast(1.1); }
.hero-photo-main { width: 28vw; height: 63vh; right: 12.5vw; top: 7%; transform: rotate(1.5deg); }
.hero-photo-secondary { width: 23vw; height: 33vh; left: 18vw; bottom: -2%; transform: rotate(-2deg); }
.placeholder-media { background: linear-gradient(145deg, #0b0b0a 0 55%, #292927 55% 65%, #0b0b0a 65%); }
.placeholder-media::after { content: "YOUR WORK"; position: absolute; inset: auto 18px 18px; color: white; font-size: .68rem; font-weight: 800; letter-spacing: .15em; }
.hero-location { position: absolute; z-index: 7; left: 50%; bottom: 23%; font-size: .7rem; font-weight: 800; letter-spacing: .15em; text-transform: uppercase; }
.hero-cta { position: absolute; z-index: 8; left: 50%; bottom: 10%; min-width: 300px; padding: 22px 24px; display: flex; align-items: center; justify-content: space-between; background: var(--red); color: white; border: 1px solid var(--red); font-size: .75rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; transition: background 180ms ease; }
.hero-cta:hover, .hero-cta:focus-visible { background: var(--ink); }
.red-rail { position: absolute; z-index: 2; top: -104px; right: 0; bottom: 0; width: 12.5vw; min-width: 145px; background: var(--red); display: flex; flex-direction: column; align-items: center; justify-content: space-around; font-family: Impact, sans-serif; font-size: clamp(2rem, 4vw, 4rem); }
.red-rail i { width: 1px; height: 25%; background: var(--ink); }

.section-pad { padding: clamp(85px, 10vw, 160px) var(--pad); }
.selected { display: grid; grid-template-columns: minmax(230px, .65fr) 1.8fr; gap: 5vw; border-bottom: 1px solid var(--ink); }
.section-heading { position: sticky; top: 30px; align-self: start; }
.index { margin: 0 0 36px; }
.section-title { font-size: clamp(4rem, 8vw, 8rem); }
.selected-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8vw 2vw; }
.project-card { display: block; }
.project-card:nth-child(even) { margin-top: 90px; }
.project-image { position: relative; height: clamp(350px, 45vw, 650px); overflow: hidden; background: #c9c1b4; }
.project-image img { transition: transform 600ms cubic-bezier(.2,.7,.2,1), filter 400ms ease; }
.project-card:hover .project-image img { transform: scale(1.035); }
.project-info { display: grid; grid-template-columns: 36px 1fr; gap: 3px 14px; padding-top: 14px; border-top: 1px solid var(--ink); }
.project-info > span { grid-row: 1 / 3; font-size: .7rem; font-weight: 800; }
.project-info h3 { margin: 0; font-size: clamp(1.25rem, 1.8vw, 2rem); line-height: 1; }
.project-info p { margin: 7px 0 0; color: #504c46; }
.project-type { position: absolute; right: 12px; bottom: 12px; padding: 10px 14px; background: var(--red); color: white; }
.empty-card { min-height: 400px; display: grid; place-items: center; border: 1px solid var(--ink); background: linear-gradient(135deg, var(--red) 0 28%, transparent 28%); text-align: center; text-transform: uppercase; }
.empty-card strong { max-width: 220px; font-size: 1.25rem; }

.statement { min-height: 88vh; background: var(--red); border-bottom: 1px solid var(--ink); }
.statement h2 { max-width: 1180px; font-size: clamp(5rem, 12vw, 12rem); }
.statement-meta { margin: 10vh 0 0 48%; display: grid; grid-template-columns: repeat(2, 1fr); gap: 3vw; max-width: 730px; font-size: .82rem; line-height: 1.55; text-transform: uppercase; letter-spacing: .07em; }
.contact { min-height: 82vh; display: flex; flex-direction: column; }
.contact h2 { max-width: 980px; font-size: clamp(5rem, 11vw, 11rem); }
.contact-mail { align-self: flex-end; margin: 9vh 4vw 12vh 0; padding-bottom: 7px; border-bottom: 4px solid var(--red); font-size: clamp(1.1rem, 2.5vw, 2.5rem); font-weight: 700; }
.site-footer { margin-top: auto; padding: 25px var(--pad) 32px; display: flex; justify-content: space-between; gap: 30px; border-top: 1px solid var(--ink); }
.site-footer-links { display: flex; gap: 25px; }
.site-footer a:hover { color: var(--red); }

.archive-intro { min-height: 540px; padding: 65px var(--pad) 50px; display: grid; grid-template-columns: 1fr auto; align-items: end; border-bottom: 1px solid var(--ink); background-image: linear-gradient(90deg, transparent 24.95%, var(--line) 25%, transparent 25.05%, transparent 74.95%, var(--line) 75%, transparent 75.05%); }
.archive-title { font-size: clamp(7rem, 15vw, 14rem); }
.archive-note { margin: 0 4vw 10px 0; font-size: .75rem; line-height: 1.55; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.archive-wrap { padding: 0 var(--pad) 120px; }
.filter-bar { position: sticky; top: 0; z-index: 20; display: flex; gap: 8px; padding: 18px 0; background: rgba(242,235,221,.94); backdrop-filter: blur(12px); border-bottom: 1px solid var(--ink); }
.filter-button { min-width: 110px; padding: 12px 18px; border: 1px solid var(--ink); background: transparent; color: var(--ink); cursor: pointer; }
.filter-button.active, .filter-button:hover { background: var(--red); color: white; border-color: var(--red); }
.archive-grid { display: grid; grid-template-columns: repeat(12, 1fr); gap: 90px 2vw; padding-top: 70px; }
.archive-grid .project-card { grid-column: span 6; }
.archive-grid .project-card:nth-child(3n + 2) { grid-column: span 5; margin: 100px 0 0; }
.archive-grid .project-card:nth-child(3n + 3) { grid-column: 3 / span 7; margin: 0; }
.archive-grid .project-card.is-hidden { display: none; }

.single-head { padding: 70px var(--pad) 55px; border-bottom: 1px solid var(--ink); }
.single-title { max-width: 1160px; font-size: clamp(5rem, 11vw, 11rem); }
.single-meta { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; margin: 60px 0 0 50%; font-size: .7rem; font-weight: 800; letter-spacing: .13em; text-transform: uppercase; }
.single-media { position: relative; min-height: 68vh; background: var(--ink); }
.single-media > img { max-height: 1100px; min-height: 70vh; }
.single-media iframe { display: block; width: 100%; height: min(56.25vw, 900px); border: 0; }
.single-media video { display: block; width: 100%; max-height: 90vh; background: #000; }
.media-label { position: absolute; left: var(--pad); bottom: 28px; z-index: 3; padding: 11px 15px; background: var(--paper); font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.gallery { display: grid; grid-template-columns: repeat(12, 1fr); gap: 3vw 2vw; padding: clamp(65px, 8vw, 120px) var(--pad); }
.gallery figure { grid-column: span 6; margin: 0; }
.gallery figure:nth-child(3n) { grid-column: 3 / span 8; }
.gallery img { height: auto; }
.project-nav { padding: 90px var(--pad) 120px; display: grid; grid-template-columns: 1fr 2fr; align-items: end; gap: 40px; }
.back-link { width: max-content; padding-bottom: 8px; border-bottom: 2px solid var(--red); font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.next-project { display: grid; grid-template-columns: 1fr auto; gap: 12px 24px; padding-top: 18px; border-top: 1px solid var(--ink); }
.next-project small { grid-column: 1 / -1; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.next-project strong { font-size: clamp(2rem, 4.5vw, 5rem); line-height: .9; text-transform: uppercase; }
.next-project b { color: var(--red); font-size: 2.5rem; }

.simple-page { min-height: 70vh; padding: 80px var(--pad); }
.simple-page h1 { font-family: Impact, sans-serif; font-size: clamp(5rem, 12vw, 11rem); line-height: .8; text-transform: uppercase; }

@keyframes title-in { from { opacity: 0; transform: translateY(35px); clip-path: inset(0 0 100%); } to { opacity: 1; transform: none; clip-path: inset(0); } }

@media (max-width: 900px) {
  .site-header { height: 84px; }
  .brand span { display: none; }
  .site-nav { gap: 15px; }
  .hero { height: calc(100svh - 84px); min-height: 760px; }
  .hero h1 { font-size: clamp(5.8rem, 24vw, 9rem); }
  .red-rail { top: -84px; width: 18px; min-width: 18px; }
  .red-rail span, .red-rail i { display: none; }
  .hero-photo-main { width: 56vw; height: 47vh; right: 18px; top: 29%; }
  .hero-photo-secondary { width: 46vw; height: 27vh; left: 18px; }
  .hero-location { left: 20px; bottom: 29%; writing-mode: vertical-rl; }
  .hero-cta { left: auto; right: 18px; bottom: 4%; }
  .selected { grid-template-columns: 1fr; }
  .section-heading { position: static; }
  .project-card:nth-child(even) { margin-top: 55px; }
  .statement-meta { margin-left: 0; }
  .archive-title { font-size: clamp(6rem, 19vw, 10rem); }
  .archive-grid .project-card, .archive-grid .project-card:nth-child(3n + 2), .archive-grid .project-card:nth-child(3n + 3) { grid-column: span 6; margin-top: 0; }
  .single-meta { margin-left: 25%; }
}

@media (max-width: 560px) {
  .site-header { margin-inline: 18px; }
  .brand strong { font-size: 1.45rem; }
  .site-nav { gap: 10px; }
  .site-nav a { font-size: .57rem; letter-spacing: .09em; }
  .hero-copy { left: 20px; }
  .hero h1 { font-size: clamp(5rem, 25vw, 7rem); }
  .hero-photo-main { width: 62vw; }
  .hero-photo-secondary { left: 8px; width: 52vw; }
  .hero-cta { left: 20px; min-width: 0; }
  .selected-grid { grid-template-columns: 1fr; }
  .project-card:nth-child(even) { margin-top: 0; }
  .project-image { height: 112vw; max-height: 570px; }
  .section-title, .statement h2, .contact h2 { font-size: clamp(4rem, 21vw, 7rem); }
  .statement-meta { grid-template-columns: 1fr; }
  .contact-mail { align-self: stretch; margin-right: 0; font-size: 1.1rem; }
  .site-footer { flex-direction: column; }
  .archive-intro { min-height: 400px; grid-template-columns: 1fr; }
  .archive-title { font-size: clamp(5.2rem, 25vw, 7.5rem); }
  .archive-note { margin-top: 30px; }
  .filter-bar { overflow-x: auto; }
  .filter-button { min-width: 92px; }
  .archive-grid { grid-template-columns: 1fr; gap: 60px; }
  .archive-grid .project-card, .archive-grid .project-card:nth-child(3n + 2), .archive-grid .project-card:nth-child(3n + 3) { grid-column: 1; }
  .single-title { font-size: clamp(4.3rem, 21vw, 7rem); }
  .single-meta { margin-left: 0; grid-template-columns: 1fr 1fr; }
  .single-media > img { min-height: 65vh; }
  .gallery { grid-template-columns: 1fr; }
  .gallery figure, .gallery figure:nth-child(3n) { grid-column: 1; }
  .project-nav { grid-template-columns: 1fr; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
