/* Centro Solare Nuovo Sole — one stylesheet, no framework. */

@font-face {
  font-family: "Open Sans";
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url("../fonts/open-sans-normal.woff2") format("woff2");
}
@font-face {
  font-family: "Open Sans";
  font-style: italic;
  font-weight: 300 700;
  font-display: swap;
  src: url("../fonts/open-sans-italic.woff2") format("woff2");
}

:root {
  --sand-dark: #a58b6d;
  --sand-light: #dcc89c;
  --bg: #f6f1ed;
  --card: #fff;
  --text: #6a5c4f;
  --heading: #54463a;
  --muted: #8d7f72;
  --line: #ece3da;
  --orange: #f07a1f;
  --orange-dark: #c85a0c;
  --red: #c9302c;
  --whatsapp: #128c4a;
  --shadow: 0 1px 2px rgb(84 70 58 / 0.08), 0 6px 18px rgb(84 70 58 / 0.08);
  --radius: 4px;
  --wrap: 1120px;
  --gutter: 16px;
}

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

html {
  scrollbar-gutter: stable;
  background: var(--bg);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem/1.65 "Open Sans", system-ui, sans-serif;
}

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

a {
  color: var(--orange-dark);
}

a:hover {
  color: var(--orange);
}

:focus-visible {
  outline: 3px solid var(--orange);
  outline-offset: 2px;
}

h1,
h2,
h3 {
  color: var(--heading);
  line-height: 1.25;
  font-weight: 400;
  margin: 0 0 0.6em;
}

h2 {
  font-size: 1.5rem;
}

h3 {
  font-size: 1.15rem;
  font-weight: 600;
}

p {
  margin: 0 0 1em;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: var(--gutter);
  top: -100px;
  z-index: 100;
  padding: 0.5em 1em;
  background: var(--card);
}

.skip-link:focus {
  top: 8px;
}

.icon {
  width: 1.25em;
  height: 1.25em;
  flex: none;
}

/* ── Header and navigation ─────────────────────────────────────────── */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: var(--card);
  border-bottom: 4px solid var(--sand-dark);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
  min-height: 64px;
}

.brand img {
  width: 150px;
}

.nav-toggle {
  display: none;
}

.site-nav ul {
  display: flex;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav a {
  display: block;
  padding: 20px 14px;
  border-top: 3px solid transparent;
  color: var(--muted);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-decoration: none;
  text-transform: uppercase;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--heading);
  background: var(--bg);
  border-top-color: var(--orange);
}

@media (max-width: 900px) {
  .nav-toggle {
    display: grid;
    place-items: center;
    width: 44px;
    height: 44px;
    border: 0;
    background: none;
    cursor: pointer;
  }

  .nav-toggle__bar,
  .nav-toggle__bar::before,
  .nav-toggle__bar::after {
    display: block;
    width: 24px;
    height: 2px;
    background: var(--heading);
    transition: transform 0.2s;
  }

  .nav-toggle__bar {
    position: relative;
  }

  .nav-toggle__bar::before,
  .nav-toggle__bar::after {
    content: "";
    position: absolute;
    left: 0;
  }

  .nav-toggle__bar::before {
    top: -7px;
  }

  .nav-toggle__bar::after {
    top: 7px;
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle__bar {
    background: transparent;
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle__bar::before {
    transform: translateY(7px) rotate(45deg);
  }

  .nav-toggle[aria-expanded="true"] .nav-toggle__bar::after {
    transform: translateY(-7px) rotate(-45deg);
  }

  .site-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    display: none;
    background: var(--card);
    box-shadow: var(--shadow);
  }

  .site-nav.is-open {
    display: block;
  }

  .site-nav ul {
    flex-direction: column;
    padding: 8px 0;
  }

  .site-nav a {
    padding: 12px var(--gutter);
    border-top: 0;
    border-left: 3px solid transparent;
    font-size: 0.95rem;
  }

  .site-nav a[aria-current="page"] {
    border-left-color: var(--orange);
  }
}

/* ── Page structure ────────────────────────────────────────────────── */

.wrap {
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.section {
  padding: 40px 0;
}

.page-head {
  padding: 48px var(--gutter);
  background: linear-gradient(110deg, var(--sand-dark), var(--sand-light));
  color: #fff;
  text-align: center;
}

.page-head h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(1.75rem, 4vw, 2.4rem);
  font-style: italic;
  font-weight: 400;
  text-shadow: 0 1px 2px rgb(0 0 0 / 0.15);
}

.page-head p {
  margin: 0.3em 0 0;
  font-size: clamp(1rem, 2.4vw, 1.25rem);
  font-style: italic;
  font-weight: 300;
}

.card {
  background: var(--card);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 28px;
}

.card + .card {
  margin-top: 24px;
}

.grid > .card,
.split > .card {
  margin-top: 0;
}

.card--flush {
  padding: 0;
  overflow: hidden;
}

@media (max-width: 600px) {
  .card {
    padding: 20px;
  }

  .card .card__title {
    margin: -20px -20px 20px;
    padding: 14px 20px;
  }
}

.card__title {
  margin: -28px -28px 24px;
  padding: 16px 28px;
  background: var(--orange);
  color: #fff;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.grid {
  display: grid;
  gap: 24px;
}

@media (min-width: 720px) {
  .grid--2 {
    grid-template-columns: repeat(2, 1fr);
  }

  .grid--3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

.split {
  display: grid;
  gap: 28px;
  align-items: start;
}

@media (min-width: 820px) {
  .split {
    grid-template-columns: 1fr 1fr;
  }

  .split--media-right > :first-child {
    order: 2;
  }
}

.media img {
  width: 100%;
  border-radius: var(--radius);
}

.eyebrow {
  margin-bottom: 0.4em;
  color: var(--orange-dark);
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.lead {
  font-size: 1.1rem;
}

.note {
  padding: 16px 20px;
  border-left: 4px solid var(--orange);
  background: #fdf3ea;
  border-radius: 0 var(--radius) var(--radius) 0;
}

/* ── Footer ────────────────────────────────────────────────────────── */

.site-footer {
  margin-top: 40px;
  padding: 36px var(--gutter);
  border-top: 4px solid var(--sand-dark);
  background: linear-gradient(110deg, var(--sand-dark), var(--sand-light));
  color: #fff;
  text-align: center;
}

.site-footer a {
  color: #fff;
}

.site-footer p {
  margin: 0.4em 0 0;
  font-size: 0.9rem;
  font-style: italic;
}

.social {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin: 0 0 16px;
  padding: 0;
  list-style: none;
}

.social a {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #fff;
  color: var(--sand-dark);
}

.social a:hover {
  color: var(--orange);
}

/* ── Buttons and contact blocks ────────────────────────────────────── */

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 12px 22px;
  border-radius: var(--radius);
  color: #fff;
  font-weight: 400;
  text-decoration: none;
}

@media (max-width: 600px) {
  .actions .button {
    flex: 1 1 100%;
    justify-content: center;
  }
}

.button:hover {
  color: #fff;
  filter: brightness(1.08);
}

.button--call {
  background: var(--red);
}

.button--whatsapp {
  background: var(--whatsapp);
}

.button--plain {
  background: var(--heading);
}

.contact-list {
  margin: 0 0 1.5em;
  padding: 0;
  list-style: none;
}

.contact-list li {
  display: flex;
  gap: 12px;
  align-items: flex-start;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
  overflow-wrap: anywhere;
}

.contact-list .icon {
  margin-top: 2px;
  color: var(--sand-dark);
}

.contact-list small {
  color: var(--muted);
}

.hours {
  width: 100%;
  border-collapse: collapse;
}

.hours caption {
  margin-bottom: 0.5em;
  color: var(--heading);
  font-weight: 600;
  text-align: left;
}

.hours th,
.hours td {
  padding: 6px 0;
  border-bottom: 1px solid var(--line);
  text-align: left;
  font-weight: 400;
}

.hours th {
  font-weight: 600;
}

.hours td {
  text-align: right;
}

/* ── Lists of services ─────────────────────────────────────────────── */

.service h3 {
  margin-bottom: 0.3em;
}

.service h3 small {
  color: var(--muted);
  font-weight: 400;
}

.service p:last-child {
  margin-bottom: 0;
}

.pill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.pill-list li {
  padding: 6px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--bg);
}

/* ── Tables (fototipo) ─────────────────────────────────────────────── */

.table-scroll {
  overflow-x: auto;
}

.data-table {
  width: 100%;
  min-width: 640px;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.data-table th,
.data-table td {
  padding: 10px 12px;
  border: 1px solid var(--line);
  vertical-align: top;
  text-align: left;
}

.data-table thead th {
  background: var(--sand-dark);
  color: #fff;
  font-weight: 600;
}

.data-table tbody th {
  background: var(--bg);
  color: var(--heading);
  white-space: nowrap;
}

.data-table--center td {
  text-align: center;
}

/* ── Gallery ───────────────────────────────────────────────────────── */

.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(130px, 40%), 1fr));
  gap: 10px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.gallery a {
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: var(--radius);
}

.gallery img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.25s;
}

.gallery a:hover img {
  transform: scale(1.04);
}

.lightbox {
  width: min(96vw, 1080px);
  max-height: 96vh;
  padding: 0;
  border: 0;
  background: transparent;
}

.lightbox::backdrop {
  background: rgb(20 14 10 / 0.88);
}

.lightbox img {
  max-height: 86vh;
  margin: 0 auto;
  border-radius: var(--radius);
}

.lightbox__bar {
  display: flex;
  justify-content: center;
  gap: 12px;
  margin-top: 12px;
}

.lightbox__bar button {
  min-width: 48px;
  min-height: 44px;
  padding: 0 16px;
  border: 0;
  border-radius: var(--radius);
  background: rgb(255 255 255 / 0.92);
  color: var(--heading);
  font: inherit;
  cursor: pointer;
}

/* ── Price list ────────────────────────────────────────────────────── */

.price-list {
  margin: 0 0 1em;
  padding: 0 0 0.6em;
  list-style: none;
  border-bottom: 1px solid var(--line);
}

.price-list:last-of-type {
  border-bottom: 0;
}

.price-list li {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 3px 0;
}

/* Dotted leader between the name and the price. */
.price-list li::after {
  content: "";
  order: 1;
  flex: 1 1 12px;
  border-bottom: 1px dotted var(--sand-dark);
  transform: translateY(-4px);
}

.price-list li span:last-child {
  order: 2;
  color: var(--heading);
  font-weight: 600;
  white-space: nowrap;
}

.price-columns {
  margin-top: 24px;
}

.price-columns .card {
  margin-top: 0;
}

.price-columns + .card {
  margin-top: 24px;
}

.price-table td {
  white-space: nowrap;
}

.price-table__group th[scope="rowgroup"] {
  background: #fdf3ea;
  color: var(--orange-dark);
  font-style: italic;
  font-weight: 600;
}

.price-table__group th[scope="row"] {
  padding-left: 24px;
}

.badge {
  display: inline-block;
  margin-left: 8px;
  padding: 2px 12px;
  border-radius: 999px;
  background: var(--orange);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  vertical-align: middle;
}

/* On phones the solarium table becomes a list: lamp name, then its prices as chips. */
@media (max-width: 600px) {
  .price-table {
    min-width: 0;
  }

  .price-table thead {
    display: none;
  }

  .price-table,
  .price-table tbody,
  .price-table tr {
    display: block;
  }

  .price-table tr {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    padding: 10px 0;
    border-bottom: 1px solid var(--line);
  }

  .price-table th,
  .price-table td {
    border: 0;
    padding: 0;
  }

  .price-table th[scope="row"],
  .price-table th[scope="rowgroup"] {
    flex: 1 1 100%;
    background: none;
  }

  .price-table__group th[scope="row"] {
    padding-left: 0;
  }

  .price-table td {
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--bg);
  }

  .price-table td:empty {
    display: none;
  }
}

/* ── Home ──────────────────────────────────────────────────────────── */

.hero {
  position: relative;
  height: clamp(200px, 28vw, 450px);
  overflow: hidden;
  background: var(--sand-dark);
}

.hero img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero img + img {
  animation: hero-fade 14s ease-in-out infinite;
}

@keyframes hero-fade {
  0%, 42% { opacity: 0; }
  50%, 92% { opacity: 1; }
  100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .hero img + img {
    animation: none;
    opacity: 0;
  }
}

.tagline {
  padding: 28px var(--gutter);
  background: var(--card);
  text-align: center;
  box-shadow: var(--shadow);
}

.tagline h1 {
  margin: 0;
  color: var(--sand-dark);
  font-size: clamp(1.4rem, 3.4vw, 2rem);
  font-style: italic;
}

.tagline p {
  margin: 0.2em 0 0;
  font-size: clamp(1rem, 2.2vw, 1.2rem);
  font-style: italic;
  font-weight: 300;
}

.feature {
  text-align: center;
}

.feature img {
  width: 84px;
  margin: 0 auto 16px;
}

.feature p {
  color: var(--muted);
  font-size: 0.95rem;
  font-style: italic;
}

.feature__link {
  font-weight: 700;
  text-transform: uppercase;
  text-decoration: none;
}

.info {
  display: grid;
}

@media (min-width: 820px) {
  .info {
    grid-template-columns: 1.15fr 1fr;
  }
}

.info__map img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.info__body {
  padding: 28px;
}

.cta {
  display: grid;
  gap: 20px;
  align-items: center;
}

@media (min-width: 820px) {
  .cta {
    grid-template-columns: 1fr auto;
  }
}

.cta p {
  margin: 0;
  font-size: 1.05rem;
}

.post-card {
  display: grid;
}

@media (min-width: 720px) {
  .post-card {
    grid-template-columns: 1fr 1fr;
  }
}

.post-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.post-card__body {
  padding: 28px;
}

.post-card time {
  color: var(--muted);
  font-size: 0.9rem;
}

/* ── Prose pages (privacy, article) ────────────────────────────────── */

.prose {
  max-width: 760px;
  margin: 0 auto;
}

.prose h2 {
  margin-top: 1.4em;
  font-size: 1.25rem;
  font-weight: 600;
}

.map-link {
  display: block;
  max-width: 917px;
  margin: 0 auto;
}

.prose img {
  width: 100%;
  margin-bottom: 24px;
  border-radius: var(--radius);
}
