/*
Theme Name: Alessandro Rosati Photo
Theme URI: https://alessandrorosatiphoto.com
Author: Alessandro Rosati
Description: Custom minimalist photography portfolio theme for Alessandro Rosati, featuring rich dark aesthetic (#382525), responsive portfolio galleries, fullscreen lightbox, and seamless project management.
Version: 1.0.0
Text Domain: alessandro-rosati
*/

:root {
  /* Alternativa A: The Gallery Darkroom (Onyx Antracite Neutro) */
  --bg-color: #121212;
  --bg-darker: #0d0d0d;
  --bg-card: #1c1c1c;
  --text-color: #f4f4f4;
  --text-muted: #9e9e9e;
  --text-subtle: #757575;
  --accent-color: #707070;
  --border-color: rgba(255, 255, 255, 0.08);
  --lightbox-bg: rgba(18, 18, 18, 0.98);
  --font-main: 'Sansation', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --container-max: 1600px;
  --transition: all 0.25s cubic-bezier(0.2, 0, 0.2, 1);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  background-color: var(--bg-color);
  color: var(--text-color);
  font-family: var(--font-main);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg-color);
  color: var(--text-color);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
  transition: var(--transition);
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

ul, ol {
  list-style: none;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: 0.02em;
}

.site-container {
  width: 100%;
  max-width: var(--container-max);
  margin-left: auto;
  margin-right: auto;
  padding-left: 5%;
  padding-right: 5%;
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */
.site-header {
  position: relative;
  width: 100%;
  padding-top: 36px;
  padding-bottom: 36px;
  z-index: 100;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.site-nav-wrap {
  flex: 1;
}

.primary-nav ul {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.5rem;
}

/* Separazione visiva tra le Gallerie fotografiche e le pagine Info/Area Riservata nel menu principale */
.primary-nav ul > li:nth-child(6),
.primary-nav ul > li.menu-item-12,
.primary-nav ul > li:has(a[href*="/about"]),
.primary-nav ul > li:has(a[href*="/chi-sono"]) {
  margin-left: 3rem !important;
  position: relative;
}

.primary-nav ul > li:nth-child(6)::before,
.primary-nav ul > li.menu-item-12::before,
.primary-nav ul > li:has(a[href*="/about"])::before,
.primary-nav ul > li:has(a[href*="/chi-sono"])::before {
  content: "";
  position: absolute;
  left: -1.65rem;
  top: 20%;
  height: 60%;
  width: 1px;
  background-color: rgba(255, 255, 255, 0.22);
  pointer-events: none;
}

@media (max-width: 1200px) {
  .primary-nav ul > li:nth-child(6),
  .primary-nav ul > li.menu-item-12,
  .primary-nav ul > li:has(a[href*="/about"]),
  .primary-nav ul > li:has(a[href*="/chi-sono"]) {
    margin-left: 2rem !important;
  }
  .primary-nav ul > li:nth-child(6)::before,
  .primary-nav ul > li.menu-item-12::before,
  .primary-nav ul > li:has(a[href*="/about"])::before,
  .primary-nav ul > li:has(a[href*="/chi-sono"])::before {
    left: -1.15rem;
  }
}

/* Separazione visiva nel drawer menu (mobile e tablet) */
.drawer-menu-list > li:nth-child(6),
.drawer-menu-list > li.menu-item-12,
.drawer-menu-list > li:has(a[href*="/about"]),
.drawer-menu-list > li:has(a[href*="/chi-sono"]) {
  margin-top: 1.5rem !important;
  padding-top: 1.25rem !important;
  border-top: 1px solid rgba(255, 255, 255, 0.15) !important;
}

.primary-nav li a {
  font-size: 0.9375rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-color);
  position: relative;
  padding: 4px 0;
}

.primary-nav li a:hover,
.primary-nav li.current-menu-item > a,
.primary-nav li.active > a {
  color: var(--text-color);
  text-decoration: underline;
  text-underline-offset: 6px;
}

.primary-nav li a:hover {
  color: var(--text-muted);
}

/* Logo */
.site-logo {
  flex-shrink: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
}

/* Home / Splash Page - Center Logo & Hide Menu Wrapper */
body.home .site-nav-wrap,
body.home .hamburger-toggle {
  display: none !important;
}

body.home .header-inner {
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  width: 100% !important;
}

body.home .site-logo {
  display: flex !important;
  flex-direction: column !important;
  justify-content: center !important;
  align-items: center !important;
  width: 100% !important;
  text-align: center !important;
  margin: 0 auto !important;
  float: none !important;
}

body.home .site-logo a,
body.home .site-logo img {
  margin: 0 auto !important;
  display: block !important;
}

/* ==========================================================================
   Language Selector (EN / IT) Under Logo
   ========================================================================== */
.site-lang-switch {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-top: 6px;
  font-family: inherit;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  user-select: none;
  line-height: 1;
}

body.home .site-lang-switch {
  margin: 10px auto 0;
  justify-content: center;
}

body:not(.home) .site-lang-switch {
  justify-content: flex-end;
  margin-right: 2px;
}

@media (max-width: 992px) {
  body:not(.home) .site-lang-switch {
    margin-top: 4px;
    font-size: 0.68rem;
  }
}

.site-lang-switch .lang-opt,
.drawer-lang-switch .lang-opt {
  color: #888888;
  text-decoration: none;
  padding: 2px 4px;
  transition: color 0.2s ease, opacity 0.2s ease, border-color 0.2s ease;
  font-weight: 500;
  line-height: 1;
  position: relative;
}

.site-lang-switch .lang-opt:hover,
.drawer-lang-switch .lang-opt:hover {
  color: #ffffff;
}

.site-lang-switch .lang-opt.is-active,
.drawer-lang-switch .lang-opt.is-active {
  color: #ffffff;
  font-weight: 700;
  border-bottom: 1.5px solid #ffffff;
  pointer-events: none;
}

.site-lang-switch .lang-sep,
.drawer-lang-switch .lang-sep {
  color: #555555;
  font-size: 0.7rem;
  user-select: none;
}

/* Language selector inside mobile drawer */
.drawer-lang-switch {
  margin-top: 1.5rem;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.85rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

body.home .wp-block-button__link:hover {
  background-color: #ffffff !important;
  color: #121212 !important;
  border-color: #ffffff !important;
}

.site-logo,
.site-logo a,
.site-logo img,
.custom-logo {
  background: transparent !important;
}

.site-logo a {
  display: inline-block;
}

.site-logo img {
  max-height: 48px;
  width: auto;
  object-fit: contain;
}

/* Logo in tutte le pagine tranne la Home: ingrandito del 20% */
body:not(.home) .site-header .custom-logo,
body:not(.home) .site-logo img,
body:not(.home) header img.custom-logo,
body:not(.home) header [data-id="logo"] img {
  max-height: 86px !important;
  height: auto !important;
  width: auto !important;
  transform: scale(1) !important;
  transform-origin: right center;
  background: transparent !important;
}

/* ==========================================================================
   Logo & Sfondo Trasparente Allineato su /portfolio/ (Page ID 8 & Portfolio Hub)
   ========================================================================== */
body.page-id-8,
body.page-portfolio,
body.page-template-template-portfolio-hub,
.page-template-template-portfolio-hub {
  background-color: #121212 !important;
  background: #121212 !important;
}

body.page-id-8 .site-header,
body.page-id-8 .header-inner,
body.page-id-8 .site-logo,
body.page-id-8 .site-logo img,
body.page-id-8 .custom-logo,
body.page-id-8 .wp-image-414,
body.page-id-8 figure.wp-block-image img,
body.page-id-8 .wp-block-image,
.portfolio-logo-wrap,
.portfolio-logo-wrap figure,
.portfolio-logo-wrap img {
  background: transparent !important;
  background-color: transparent !important;
  box-shadow: none !important;
  border: none !important;
}

.portfolio-logo-wrap a,
.portfolio-logo-wrap img,
a.portfolio-logo-link {
  cursor: pointer !important;
  pointer-events: auto !important;
}

.portfolio-page-lang-switch .lang-opt {
  color: #888888;
  text-decoration: none;
  font-weight: 500;
  transition: color 0.2s ease;
  padding: 2px 4px;
}

.portfolio-page-lang-switch .lang-opt.is-active {
  color: #ffffff;
  border-bottom: 1.5px solid #ffffff;
}

.portfolio-page-lang-switch .lang-opt:hover {
  color: #ffffff;
}

@media (max-width: 768px) {
  body:not(.home) .site-header .custom-logo,
  body:not(.home) .site-logo img,
  body:not(.home) header img.custom-logo {
    max-height: 60px !important;
    max-width: 240px !important;
  }
}

.site-logo-text {
  font-size: 1.35rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 400;
}

/* Hamburger Button */
.hamburger-toggle {
  display: none;
  background: transparent;
  border: none;
  cursor: pointer;
  padding: 10px;
  z-index: 1001;
}

.hamburger-box {
  width: 26px;
  height: 20px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.hamburger-line {
  display: block;
  width: 100%;
  height: 2px;
  background-color: var(--text-color);
  transition: var(--transition);
}

/* Responsive Drawer Navigation */
.responsive-drawer {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: var(--bg-color);
  z-index: 1000;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 2rem 1.5rem 6rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
  overflow-y: auto;
}

.responsive-drawer.is-open {
  opacity: 1;
  visibility: visible;
}

.responsive-drawer-nav ul {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
  text-align: center;
}

.responsive-drawer-nav li a {
  font-size: 1.35rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-color);
}

.responsive-drawer-nav li a:hover {
  color: var(--text-muted);
}

.drawer-social {
  margin-top: 2.5rem;
  display: flex;
  gap: 1.5rem;
}

.drawer-social a svg {
  width: 28px;
  height: 28px;
  fill: var(--text-color);
  transition: var(--transition);
}

.drawer-social a:hover svg {
  fill: var(--text-muted);
}

.drawer-close-btn {
  position: absolute;
  top: 30px;
  right: 5%;
  background: transparent;
  border: none;
  cursor: pointer;
  width: 32px;
  height: 32px;
  color: var(--text-color);
}

.drawer-close-btn::before,
.drawer-close-btn::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 2px;
  background-color: var(--text-color);
}

.drawer-close-btn::before {
  transform: rotate(45deg);
}

.drawer-close-btn::after {
  transform: rotate(-45deg);
}

/* ==========================================================================
   Page Headers
   ========================================================================== */
.page-intro-header {
  padding-top: 1rem;
  padding-bottom: 3.5rem;
  max-width: 960px;
}

.page-intro-title {
  font-size: 2.75rem;
  font-weight: 400;
  margin-bottom: 1.25rem;
  color: var(--text-color);
  letter-spacing: -0.01em;
}

.page-intro-desc {
  font-size: 1.125rem;
  color: #f0ebeb;
  line-height: 1.7;
  white-space: pre-line;
}

/* ==========================================================================
   Splash / Benvenuto Landing Page
   ========================================================================== */
.splash-wrapper {
  min-height: calc(100vh - 120px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 3rem 1.5rem;
}

.splash-card {
  max-width: 1100px;
  width: 100%;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.splash-badge {
  max-width: 260px;
  margin-bottom: 2rem;
}

.splash-title {
  font-size: 2.75rem;
  line-height: 1.2;
  margin-bottom: 1.5rem;
  color: #fbf7f7;
}

.splash-subtitle {
  font-size: 1.2rem;
  max-width: 780px;
  color: #e5e0e0;
  margin-bottom: 2.5rem;
  line-height: 1.6;
}

/* 3D Parallax Tilt & Glare Effect */
.splash-hero-wrap {
  perspective: 1200px;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  max-width: 1060px;
  margin: 0 auto 2.5rem;
  overflow: visible;
  pointer-events: auto !important;
}

.tilt-card {
  position: relative;
  width: 100%;
  border-radius: 8px;
  transform-style: preserve-3d;
  transition: transform 0.12s ease-out, box-shadow 0.25s ease-out;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55), 0 0 0 1px rgba(255, 255, 255, 0.08);
  will-change: transform, box-shadow;
  overflow: hidden;
  cursor: default !important;
  pointer-events: auto !important;
}

.tilt-card .splash-hero-image {
  width: 100%;
  height: auto;
  display: block;
  margin-bottom: 0;
  border-radius: 8px;
  transform: translateZ(0);
  box-shadow: none;
  pointer-events: none;
  user-select: none;
}

.tilt-glare {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: 8px;
  pointer-events: none;
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.25) 0%, rgba(255, 255, 255, 0) 65%);
  opacity: 0;
  mix-blend-mode: overlay;
  transition: opacity 0.3s ease;
  will-change: opacity, background;
}

/* Floating animation on devices without hover (mobile/touch) */
@media (hover: none) {
  .tilt-card {
    animation: gentleFloat 6s ease-in-out infinite;
  }
}

@keyframes gentleFloat {
  0%, 100% {
    transform: translateY(0px) scale(1);
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.55);
  }
  50% {
    transform: translateY(-8px) scale(1.01);
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.65);
  }
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 2.2rem;
  border: 1px solid rgba(255, 255, 255, 0.4);
  background: transparent;
  color: var(--text-color);
  font-size: 0.95rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  border-radius: 3px;
  transition: all 0.25s cubic-bezier(0.2, 0, 0.2, 1);
}

/* Project Bottom Navigation Container & Buttons */
.arp-project-nav-container {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1.25rem;
  margin: 3.5rem auto 2.5rem auto;
  flex-wrap: wrap;
  width: 100%;
}

.arp-nav-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.85rem 2.2rem;
  background-color: #1a1a1a;
  color: #e0e0e0;
  border: 1px solid #3a3a3a;
  font-size: 0.875rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  border-radius: 4px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.4);
  transition: all 0.25s cubic-bezier(0.2, 0, 0.2, 1);
}

/* ==========================================================================
   Button Hover Styles - Refined Graphite & Titanium Palette (White Text Guaranteed)
   ========================================================================== */
html body .btn:hover,
html body .wp-block-button__link:hover,
html body .wp-block-buttons .wp-block-button a:hover,
html body a.button:hover,
html body .button:hover,
html body .ct-button:hover,
html body a[class*="button"]:hover,
html body a[class*="btn"]:hover,
html body .arp-project-nav-container .arp-nav-btn:hover,
html body.home .wp-block-button__link:hover {
  background-color: #2c2c2c !important; /* Grafite profondo satinato */
  color: #ffffff !important;            /* Testo BIANCO puro visibilissimo */
  border-color: #6e6e6e !important;    /* Bordo titanio medio */
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.55) !important;
  transform: translateY(-2px);
}

/* Forza il colore bianco su qualsiasi elemento interno al pulsante (span, a, label, svg) */
html body .btn:hover *,
html body .wp-block-button__link:hover *,
html body .wp-block-buttons .wp-block-button a:hover *,
html body a.button:hover *,
html body .button:hover *,
html body .ct-button:hover *,
html body a[class*="button"]:hover *,
html body a[class*="btn"]:hover *,
html body .arp-project-nav-container .arp-nav-btn:hover * {
  color: #ffffff !important;
  fill: #ffffff !important;
}

.splash-social {
  margin-top: 3rem;
  display: flex;
  gap: 1.5rem;
  justify-content: center;
}

.splash-social a svg {
  width: 32px;
  height: 32px;
  fill: var(--text-color);
  transition: var(--transition);
}

.splash-social a:hover svg {
  fill: var(--text-muted);
}

/* ==========================================================================
   Project Covers Grid (Series / Categories)
   ========================================================================== */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
  gap: 2.5rem;
  margin-bottom: 5rem;
}

.project-card {
  display: block;
  position: relative;
  overflow: hidden;
}

.project-card-image-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 66.66%; /* 3:2 ratio */
  background-color: var(--bg-card);
  overflow: hidden;
}

.project-card-image-wrap img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s cubic-bezier(0.2, 0, 0.2, 1);
}

.project-card:hover .project-card-image-wrap img {
  transform: scale(1.03);
}

.project-card-details {
  padding-top: 1rem;
}

.project-card-title {
  font-size: 1.35rem;
  font-weight: 400;
  color: var(--text-color);
  margin-bottom: 0.25rem;
  transition: var(--transition);
}

.project-card:hover .project-card-title {
  color: var(--text-muted);
}

.project-card-count {
  font-size: 0.85rem;
  color: var(--text-subtle);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* ==========================================================================
   Single Project Gallery & Photos Grid
   ========================================================================== */
.single-project-gallery {
  display: flex;
  flex-direction: column;
  gap: 3.5rem;
  margin-bottom: 6rem;
}

.gallery-item {
  position: relative;
  width: 100%;
  display: flex;
  justify-content: center;
}

.gallery-item img {
  max-width: 100%;
  height: auto;
  border-radius: 0px;
  cursor: zoom-in;
  transition: opacity 0.3s ease;
}

.gallery-item-full {
  width: 100%;
}

.gallery-item-half-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 2rem;
  width: 100%;
}

/* ==========================================================================
   About Page
   ========================================================================== */
.about-container {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  min-height: calc(100vh - 200px);
  padding-top: 2rem;
  padding-bottom: 5rem;
}

.about-content {
  max-width: 620px;
}

.about-title {
  font-size: 2.8rem;
  margin-bottom: 2rem;
  font-weight: 400;
}

.about-text {
  font-size: 1.15rem;
  line-height: 1.85;
  color: #f2ecec;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  margin-bottom: 2.5rem;
}

.about-image img {
  width: 100%;
  height: auto;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.4);
}

/* ==========================================================================
   Contact Page & Form - Editorial Two-Column Dark Layout
   ========================================================================== */
.page-contact-main {
  padding-top: 1rem;
  padding-bottom: 5rem;
}

.contact-intro-header {
  margin-bottom: 3.5rem;
  max-width: 800px;
}

.contact-editorial-layout {
  display: grid;
  grid-template-columns: 1fr 1.35fr;
  gap: 4.5rem;
  align-items: start;
}

@media (max-width: 960px) {
  .contact-editorial-layout {
    grid-template-columns: 1fr;
    gap: 3.5rem;
  }
}

/* Colonna Sinistra: Info Dirette */
.contact-info-col {
  padding-top: 0.5rem;
}

.contact-badge {
  display: inline-block;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: var(--accent-color, #d4af37);
  margin-bottom: 0.75rem;
  font-weight: 500;
}

.contact-info-title {
  font-size: 1.9rem;
  font-weight: 400;
  line-height: 1.3;
  margin-bottom: 1.15rem;
  color: var(--text-color);
}

.contact-info-text {
  font-size: 1.02rem;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: 2.25rem;
}

.contact-meta-list {
  display: flex;
  flex-direction: column;
  gap: 1.6rem;
  margin-bottom: 2.25rem;
  padding-bottom: 2.25rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.contact-meta-item {
  display: flex;
  align-items: flex-start;
  gap: 1.15rem;
}

.meta-icon {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text-color);
}

.meta-icon svg {
  width: 18px;
  height: 18px;
}

.meta-content {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.meta-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
}

.meta-link,
.meta-value {
  font-size: 1.02rem;
  color: var(--text-color);
  text-decoration: none;
  transition: var(--transition);
}

.meta-link:hover {
  color: #ffffff;
  text-decoration: underline;
  text-underline-offset: 4px;
}

.contact-social-wrap {
  margin-top: 1rem;
}

.social-label {
  display: block;
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--text-muted);
  margin-bottom: 0.85rem;
}

.contact-social-icons {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
}

.social-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.55rem 1.15rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  color: var(--text-color);
  font-size: 0.88rem;
  text-decoration: none;
  transition: var(--transition);
}

.social-btn:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.2);
  color: #ffffff;
  transform: translateY(-2px);
}

.social-btn svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
}

/* Colonna Destra: Card del Form */
.contact-card {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 6px;
  padding: 2.8rem 2.4rem;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
}

@media (max-width: 600px) {
  .contact-card {
    padding: 1.8rem 1.35rem;
  }
}

.contact-form {
  display: flex;
  flex-direction: column;
  margin-top: 0;
}

.form-row-2col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}

@media (max-width: 600px) {
  .form-row-2col {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.45rem;
  margin-bottom: 1.35rem;
}

.form-group label {
  font-size: 0.88rem;
  color: var(--text-color);
  letter-spacing: 0.03em;
  font-weight: 400;
}

.form-control {
  width: 100%;
  padding: 0.85rem 1.1rem;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 4px;
  color: var(--text-color);
  font-family: inherit;
  font-size: 0.95rem;
  transition: var(--transition);
}

.form-control::placeholder {
  color: rgba(255, 255, 255, 0.3);
}

.form-control:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.45);
  background-color: rgba(255, 255, 255, 0.06);
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.04);
}

.form-select {
  appearance: none;
  -webkit-appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239e9e9e' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 1rem center;
  background-size: 16px;
  padding-right: 2.5rem;
  cursor: pointer;
}

.form-select option {
  background-color: #1a1a1a;
  color: #f4f4f4;
  padding: 8px 10px;
}

textarea.form-control {
  min-height: 140px;
  resize: vertical;
}

.form-privacy-group {
  margin-top: 0.35rem;
  margin-bottom: 1.75rem;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  cursor: pointer;
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
  width: 17px;
  height: 17px;
  margin-top: 2px;
  accent-color: #ffffff;
  cursor: pointer;
  flex-shrink: 0;
}

.privacy-text {
  user-select: none;
}

.btn-submit {
  width: 100%;
  padding: 1.05rem 2rem;
  font-size: 1rem;
  letter-spacing: 0.06em;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
}

.btn-loader {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}

.spinner {
  width: 18px;
  height: 18px;
  animation: arSpin 1s linear infinite;
}

@keyframes arSpin {
  100% {
    transform: rotate(360deg);
  }
}

.form-alert {
  padding: 1.1rem 1.25rem;
  border-radius: 4px;
  font-size: 0.95rem;
  line-height: 1.5;
  margin-top: 1.5rem;
}

.form-alert:empty {
  display: none !important;
}

.form-alert.success {
  background: rgba(46, 125, 50, 0.18);
  border: 1px solid rgba(76, 175, 80, 0.45);
  color: #c8e6c9;
}

.form-alert.error {
  background: rgba(198, 40, 40, 0.18);
  border: 1px solid rgba(239, 83, 80, 0.45);
  color: #ffcdd2;
}

/* ==========================================================================
   Site Footer
   ========================================================================== */
.site-footer {
  margin-top: auto;
  padding-top: 4rem;
  padding-bottom: 3.5rem;
  text-align: center;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.footer-social {
  display: flex;
  justify-content: center;
  gap: 1.75rem;
  margin-bottom: 1.5rem;
}

.footer-social a svg {
  width: 30px;
  height: 30px;
  fill: var(--text-color);
  transition: var(--transition);
}

.footer-social a:hover svg {
  fill: var(--text-muted);
}

.footer-link a {
  font-size: 1.15rem;
  color: var(--text-color);
  letter-spacing: 0.04em;
  transition: var(--transition);
}

.footer-link a:hover {
  color: var(--text-muted);
  text-decoration: underline;
}

.footer-copy {
  margin-top: 1.25rem;
  font-size: 0.85rem;
  color: var(--text-subtle);
}

/* ==========================================================================
   Back To Top Button
   ========================================================================== */
.back-to-top-btn {
  position: fixed;
  bottom: 35px;
  right: 35px;
  width: 48px;
  height: 48px;
  background-color: rgba(0, 0, 0, 0.5);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-color);
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 900;
}

.back-to-top-btn.is-visible {
  opacity: 1;
  visibility: visible;
}

.back-to-top-btn:hover {
  background-color: var(--text-color);
  color: var(--bg-color);
}

.back-to-top-btn svg {
  width: 20px;
  height: 20px;
  fill: currentColor;
}

/* ==========================================================================
   Custom Vanilla Lightbox
   ========================================================================== */
.lightbox-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background-color: var(--lightbox-bg);
  backdrop-filter: blur(8px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox-modal.is-active {
  opacity: 1;
  visibility: visible;
}

.lightbox-img-wrapper {
  max-width: 92vw;
  max-height: 88vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.lightbox-img {
  max-width: 92vw;
  max-height: 82vh;
  object-fit: contain;
  box-shadow: 0 15px 50px rgba(0, 0, 0, 0.6);
  user-select: none;
}

.lightbox-caption {
  margin-top: 1rem;
  font-size: 0.95rem;
  color: var(--text-color);
  text-align: center;
  max-width: 800px;
}

.lightbox-close,
.lightbox-prev,
.lightbox-next {
  position: absolute;
  background: transparent;
  border: none;
  color: var(--text-color);
  cursor: pointer;
  padding: 15px;
  z-index: 2010;
  transition: var(--transition);
}

.lightbox-close {
  top: 25px;
  right: 35px;
  font-size: 2rem;
  line-height: 1;
}

.lightbox-prev {
  left: 25px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-next {
  right: 25px;
  top: 50%;
  transform: translateY(-50%);
}

.lightbox-prev svg,
.lightbox-next svg {
  width: 36px;
  height: 36px;
  fill: currentColor;
}

.lightbox-close:hover,
.lightbox-prev:hover,
.lightbox-next:hover {
  color: var(--text-muted);
}

/* ==========================================================================
   Cookie Banner
   ========================================================================== */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background-color: rgba(22, 22, 22, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  color: var(--text-color);
  padding: 1.25rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
  z-index: 1500;
  box-shadow: 0 -4px 30px rgba(0, 0, 0, 0.6);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  font-size: 0.9rem;
}

.cookie-banner.is-hidden {
  display: none !important;
}

.cookie-banner-text {
  flex: 1;
  min-width: 280px;
}

.cookie-banner-actions {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.cookie-btn {
  padding: 0.5rem 1.25rem;
  border-radius: 3px;
  font-size: 0.875rem;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: transparent;
  color: var(--text-color);
  transition: var(--transition);
}

.cookie-btn.accept {
  background-color: #ffffff;
  color: #121212;
  border-color: #ffffff;
  font-weight: 500;
}

.cookie-btn:hover {
  opacity: 0.85;
}

/* ==========================================================================
   Responsive Breakpoints
   ========================================================================== */
@media (max-width: 992px) {
  .primary-nav {
    display: none;
  }

  .hamburger-toggle {
    display: block;
  }

  .about-container {
    grid-template-columns: 1fr;
    gap: 3rem;
  }

  .about-image {
    order: -1;
  }

  .splash-title {
    font-size: 2.2rem;
  }

  .page-intro-title {
    font-size: 2.2rem;
  }

  .gallery-item-half-row {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 576px) {
  .site-header {
    padding-top: 24px;
    padding-bottom: 24px;
  }

  .splash-title {
    font-size: 1.75rem;
  }

  .splash-subtitle {
    font-size: 1rem;
  }

  .page-intro-title {
    font-size: 1.75rem;
  }

  .page-intro-desc {
    font-size: 1rem;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }

  .lightbox-prev {
    left: 10px;
  }

  .lightbox-next {
    right: 10px;
  }

  .back-to-top-btn {
    bottom: 20px;
    right: 20px;
    width: 42px;
    height: 42px;
  }
}

/* ==========================================================================
   Area Riservata — Disclaimer & Interactive Gatekeeper
   ========================================================================== */
.page-area-riservata-main {
  padding-top: 1.5rem;
  padding-bottom: 6rem;
}

.area-riservata-intro-header {
  text-align: center;
  margin-bottom: 3rem;
}

.area-riservata-wrapper {
  max-width: 680px;
  margin: 0 auto;
}

/* Disclaimer Box */
.ar-disclaimer-wrapper {
  margin-bottom: 2.5rem;
}

.ar-disclaimer-card {
  background: rgba(255, 255, 255, 0.025);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 8px;
  padding: 2.2rem 2.2rem 1.8rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
  transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.ar-highlight-shake {
  animation: arShake 0.5s ease-in-out;
  border-color: rgba(212, 175, 55, 0.6) !important;
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.25) !important;
}

@keyframes arShake {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-6px); }
  40%, 80% { transform: translateX(6px); }
}

.ar-disclaimer-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 1.35rem;
}

.ar-disclaimer-icon {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(212, 175, 55, 0.12);
  border: 1px solid rgba(212, 175, 55, 0.3);
  color: #d4af37;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ar-disclaimer-icon svg {
  width: 18px;
  height: 18px;
}

.ar-disclaimer-title {
  font-size: 1.25rem;
  font-weight: 500;
  color: #ffffff;
  line-height: 1.35;
  margin: 0;
  letter-spacing: 0.01em;
}

.ar-disclaimer-body {
  font-size: 0.95rem;
  line-height: 1.75;
  color: var(--text-muted, #a0a0a0);
  margin-bottom: 1.5rem;
}

.ar-disclaimer-body p {
  margin-bottom: 0.85rem;
}

.ar-disclaimer-body p:last-child {
  margin-bottom: 0;
}

/* Checkbox "Ho capito" */
.ar-disclaimer-consent {
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.ar-checkbox-container {
  display: inline-flex;
  align-items: center;
  gap: 0.85rem;
  cursor: pointer;
  user-select: none;
  padding: 0.4rem 0.6rem;
  margin-left: -0.6rem;
  border-radius: 4px;
  transition: background-color 0.2s ease;
}

.ar-checkbox-container:hover {
  background-color: rgba(255, 255, 255, 0.04);
}

.ar-checkbox-container input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: #ffffff;
  cursor: pointer;
  flex-shrink: 0;
}

.ar-checkbox-label {
  font-size: 1.05rem;
  font-weight: 600;
  color: #ffffff;
  letter-spacing: 0.02em;
}

/* Box di login velato / spento */
.ar-locked-target-container {
  position: relative;
  max-width: 680px;
  margin: 0 auto;
  transition: opacity 0.4s ease, filter 0.4s ease;
}

.ar-box-locked {
  opacity: 0.35;
  filter: grayscale(85%);
  pointer-events: none;
  user-select: none;
  cursor: not-allowed;
}

.ar-box-locked::before {
  content: '';
  position: absolute;
  top: -12px;
  left: -12px;
  right: -12px;
  bottom: -12px;
  background: rgba(18, 18, 18, 0.65);
  backdrop-filter: blur(2.5px);
  -webkit-backdrop-filter: blur(2.5px);
  border-radius: 8px;
  border: 1px dashed rgba(255, 255, 255, 0.15);
  z-index: 50;
  pointer-events: all;
  cursor: not-allowed;
  transition: all 0.3s ease;
}

.ar-box-locked::after {
  content: '🔒 Spunta "Ho capito" sopra per abilitare l\'accesso';
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  background: rgba(30, 30, 30, 0.94);
  border: 1px solid rgba(255, 255, 255, 0.16);
  color: #eaeaea;
  padding: 0.75rem 1.4rem;
  border-radius: 30px;
  font-size: 0.88rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.65);
  z-index: 51;
  pointer-events: none;
  white-space: nowrap;
}

@media (max-width: 600px) {
  .ar-disclaimer-card {
    padding: 1.75rem 1.35rem 1.5rem;
  }
  .ar-disclaimer-title {
    font-size: 1.1rem;
  }
  .ar-box-locked::after {
    white-space: normal;
    text-align: center;
    width: 85%;
    font-size: 0.8rem;
    padding: 0.65rem 1rem;
  }
}

.ar-box-unlocked {
  opacity: 1;
  filter: none;
  pointer-events: auto;
  user-select: auto;
}

.ar-box-unlocked::before,
.ar-box-unlocked::after {
  display: none !important;
}

/* ==========================================================================
   Parete Fotografica Portfolio (Photo Wall - Onda Superficie Liquida)
   - Moto fluido e costante ad onda marina da sinistra verso destra (60/120 FPS GPU)
   - Miniature in Bianco & Nero elegante nello stato di riposo
   - All'hover: ingrandimento potenziato del 20% (1.78x) e passaggio immediato
     ai Colori Originali brillanti ad altissima definizione (No-Lightbox)
   ========================================================================== */
.ar-photo-wall-wrapper {
  position: relative;
  width: 100%;
  max-width: 1340px;
  margin: 30px auto 70px auto;
  padding: 65px 45px;
  box-sizing: border-box;
  overflow: visible;
}

.ar-photo-wall-grid {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 12px;
  width: 100%;
  box-sizing: border-box;
  overflow: visible;
  position: relative;
}

/* Animazione onda superficiale liquida (oscillazione sinusoidale e lieve beccheggio) */
@keyframes arLiquidWave {
  0% {
    transform: translateY(0px) rotate(0deg);
  }
  24% {
    transform: translateY(-9px) rotate(-1.4deg);
  }
  48% {
    transform: translateY(-1px) rotate(-0.3deg);
  }
  74% {
    transform: translateY(5px) rotate(1.1deg);
  }
  100% {
    transform: translateY(0px) rotate(0deg);
  }
}

/* Singolo mattoncino fotografico nel moto ondoso liquido */
.ar-wall-item {
  position: relative;
  aspect-ratio: 3 / 2;
  overflow: visible;
  cursor: pointer;
  user-select: none;
  animation: arLiquidWave 3.8s ease-in-out infinite;
  animation-delay: var(--liquid-delay, 0s);
  will-change: transform;
  z-index: 1;
  transition: opacity 0.4s ease, filter 0.4s ease;
}

/* Sfasamento progressivo predefinito dell'onda da sinistra a destra (7 colonne) */
.ar-wall-item:nth-child(7n + 1) { --liquid-delay: 0.00s; }
.ar-wall-item:nth-child(7n + 2) { --liquid-delay: -3.26s; }
.ar-wall-item:nth-child(7n + 3) { --liquid-delay: -2.71s; }
.ar-wall-item:nth-child(7n + 4) { --liquid-delay: -2.17s; }
.ar-wall-item:nth-child(7n + 5) { --liquid-delay: -1.63s; }
.ar-wall-item:nth-child(7n + 6) { --liquid-delay: -1.09s; }
.ar-wall-item:nth-child(7n + 7) { --liquid-delay: -0.54s; }

/* Card fotografica interna:
   In modalità riposo è in Bianco & Nero satinato ad alto contrasto.
   All'hover sboccia nei suoi colori originali vivaci con ingrandimento maggiorato. */
.ar-wall-card {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 6px;
  overflow: hidden;
  background-color: #161616;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.45);
  border: 1.5px solid rgba(255, 255, 255, 0.08);
  filter: grayscale(100%) contrast(0.98) brightness(0.92);
  transition: transform 0.38s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.38s ease,
              box-shadow 0.38s ease,
              border-color 0.38s ease;
  will-change: transform, filter, box-shadow;
  cursor: pointer;
}

.ar-wall-img {
  width: 100% !important;
  height: 100% !important;
  object-fit: cover !important;
  display: block !important;
  border-radius: 5px;
  image-rendering: auto !important;
  image-rendering: smooth !important;
  -webkit-font-smoothing: antialiased;
  pointer-events: auto;
  user-select: none;
  filter: grayscale(100%) contrast(0.98) brightness(0.92);
  -webkit-filter: grayscale(100%) contrast(0.98) brightness(0.92);
  transition: transform 0.38s cubic-bezier(0.16, 1, 0.3, 1),
              filter 0.38s ease,
              -webkit-filter 0.38s ease;
}

/* ==========================================================================
   Effetto Spotlight all'Hover:
   Quando si passa sopra alla griglia, tutte le miniature non selezionate
   rimangono in Bianco & Nero e sfumano dolcemente in penombra.
   ========================================================================== */
.ar-photo-wall-grid:hover .ar-wall-item:not(:hover) {
  opacity: 0.32;
}
.ar-photo-wall-grid:hover .ar-wall-item:not(:hover) .ar-wall-img,
.ar-photo-wall-grid:hover .ar-wall-item:not(:hover) .ar-wall-card {
  filter: grayscale(100%) brightness(0.48) contrast(0.88) !important;
  -webkit-filter: grayscale(100%) brightness(0.48) contrast(0.88) !important;
}

/* La fotografia selezionata con il mouse:
   - Blocca l'oscillazione ondosa per permettere una visione stabile
   - Si ingrandisce del 20% in più (da 1.48x a 1.78x)
   - Passa istantaneamente ai COLORI originali ad altissima risoluzione
   - Riceve bordo bianco luminoso e ombra tridimensionale profonda */
.ar-wall-item:hover {
  z-index: 120 !important;
  animation-play-state: paused !important;
}

.ar-wall-item:hover .ar-wall-card {
  transform: scale(1.78) !important;
  filter: none !important;
  -webkit-filter: none !important;
  box-shadow: 0 30px 70px -10px rgba(0, 0, 0, 0.98),
              0 0 0 3px #ffffff,
              0 0 32px rgba(255, 255, 255, 0.28) !important;
  border-color: #ffffff !important;
}

.ar-wall-item:hover .ar-wall-img,
.ar-wall-card:hover .ar-wall-img {
  filter: grayscale(0%) contrast(1.10) saturate(1.22) brightness(1.03) !important;
  -webkit-filter: grayscale(0%) contrast(1.10) saturate(1.22) brightness(1.03) !important;
  transform: scale(1.02);
}

/* Responsive Breakpoints */
@media (max-width: 1200px) {
  .ar-photo-wall-grid {
    grid-template-columns: repeat(6, 1fr);
    gap: 10px;
  }
  .ar-wall-item:hover .ar-wall-card {
    transform: scale(1.70) !important;
  }
}

@media (max-width: 900px) {
  .ar-photo-wall-grid {
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
  }
  .ar-wall-item:hover .ar-wall-card {
    transform: scale(1.58) !important;
  }
}

@media (max-width: 600px) {
  .ar-photo-wall-wrapper {
    padding: 35px 15px;
    margin: 20px auto 40px auto;
  }
  .ar-photo-wall-grid {
    grid-template-columns: repeat(3, 1fr);
    gap: 8px;
  }
  .ar-wall-item:hover .ar-wall-card {
    transform: scale(1.42) !important;
  }
}

@media (max-width: 400px) {
  .ar-photo-wall-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }
  .ar-wall-item:hover .ar-wall-card {
    transform: scale(1.30) !important;
  }
}

/* ==========================================================================
   Separazione Pulsanti Gallery vs Info/Area Riservata (/portfolio/)
   ========================================================================== */
.wp-block-buttons > .wp-block-button:nth-child(6),
.wp-block-buttons > .wp-block-button:has(a[href*="/about"]),
.wp-block-buttons > .wp-block-button:has(a[href*="/chi-sono"]) {
  margin-left: 3.5rem !important;
  position: relative;
}

.wp-block-buttons > .wp-block-button:nth-child(6)::before,
.wp-block-buttons > .wp-block-button:has(a[href*="/about"])::before,
.wp-block-buttons > .wp-block-button:has(a[href*="/chi-sono"])::before {
  content: "";
  position: absolute;
  left: -1.9rem;
  top: 20%;
  height: 60%;
  width: 1px;
  background: rgba(255, 255, 255, 0.22);
  pointer-events: none;
}

@media (max-width: 900px) {
  .wp-block-buttons > .wp-block-button:nth-child(6),
  .wp-block-buttons > .wp-block-button:has(a[href*="/about"]) {
    margin-left: 1.5rem !important;
  }
  .wp-block-buttons > .wp-block-button:nth-child(6)::before {
    display: none !important;
  }
}

@media (max-width: 600px) {
  .wp-block-buttons > .wp-block-button:nth-child(6),
  .wp-block-buttons > .wp-block-button:has(a[href*="/about"]) {
    margin-left: 0.35rem !important;
  }
}



