/*
Theme Name: ZeroY Starter
Description: PODRILO HOMES site theme. Global styles: base, header, footer, buttons, sections, media placeholders.
Version: 1.0
*/

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  color: var(--color-ink-900);
  background: var(--color-white);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}
img, svg { max-width: 100%; }
a { color: inherit; }
button, input, select, textarea { font: inherit; }
:focus-visible { outline: 3px solid rgba(34, 184, 207, .55); outline-offset: 3px; }
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: -.035em;
  line-height: 1.08;
  margin: 0;
}
h1 { font-size: clamp(2.375rem, 5vw, 4.5rem); }
h2 { font-size: clamp(1.875rem, 3.2vw, 3rem); }
h3 { font-size: clamp(1.375rem, 1.6vw, 1.75rem); }
p { margin: 0; }

/* ---------- Layout helpers ---------- */
.pd-shell {
  width: min(calc(100% - (var(--page-pad) * 2)), var(--content-max));
  margin-inline: auto;
}
.pd-section { padding-block: var(--section-space); }
.pd-section--mist { background: var(--color-mist); }
.pd-section--dark {
  position: relative;
  overflow: hidden;
  color: #fff;
  background: var(--color-navy-950);
}
.pd-section--dark::before {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, .035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .035) 1px, transparent 1px);
  background-size: 72px 72px;
  content: "";
  pointer-events: none;
}
.pd-section--dark > * { position: relative; z-index: 1; }
.pd-section-head {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, .55fr);
  gap: clamp(2rem, 5vw, 4rem);
  align-items: end;
  margin-bottom: clamp(2.5rem, 5vw, 4.5rem);
}
.pd-section-head h2 { max-width: 20ch; }
.pd-lead {
  color: var(--color-slate-600);
  font-size: clamp(1.05rem, 1.3vw, 1.2rem);
  line-height: 1.75;
  max-width: 62ch;
}
.pd-section--dark .pd-lead { color: rgba(255, 255, 255, .64); }
.pd-copy > * + * { margin-top: 1.1rem; }
.pd-copy p { max-width: 68ch; }
.pd-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .7rem;
  color: var(--color-blue-600);
  font-family: var(--font-data);
  font-size: .76rem;
  font-weight: 500;
  letter-spacing: .14em;
  line-height: 1;
  text-transform: uppercase;
}
.pd-eyebrow::before { width: 1.8rem; height: 1px; background: currentColor; content: ""; }
.pd-section--dark .pd-eyebrow { color: #8eb8ff; }
.pd-section--dark .pd-eyebrow::before { background: var(--color-cyan-500); }

/* ---------- Buttons ---------- */
.pd-button {
  display: inline-flex;
  min-height: 52px;
  align-items: center;
  gap: .6rem;
  padding: .85rem 1.5rem;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: .98rem;
  text-decoration: none;
  transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}
.pd-button--primary { color: #fff; background: var(--color-blue-600); }
.pd-button--primary:hover { background: #1d4fd8; }
.pd-button--ghost { border-color: var(--color-border); color: var(--color-navy-950); background: transparent; }
.pd-button--ghost:hover { background: var(--color-mist); }
.pd-button--on-dark { border-color: rgba(255, 255, 255, .32); color: #fff; background: transparent; }
.pd-button--on-dark:hover { background: rgba(255, 255, 255, .08); }
.pd-button .pd-arrow { transition: transform .2s ease; }
.pd-button:hover .pd-arrow { transform: translateX(3px); }

/* Legacy starter button class (placeholder front page) */
.button {
  display: inline-block;
  padding: 15px 24px;
  border-radius: var(--radius-control);
  color: #fff;
  background: var(--color-blue-600);
  text-decoration: none;
}

/* ---------- Header ---------- */
.pd-header { position: relative; z-index: 30; color: #fff; background: var(--color-navy-950); }
.pd-header__inner { display: flex; min-height: 84px; align-items: center; justify-content: space-between; gap: 1.5rem; }
.pd-brand { display: inline-flex; align-items: center; gap: .8rem; color: #fff; text-decoration: none; }
.pd-brand__mark { width: 34px; height: 34px; color: #fff; }
.pd-brand__mark svg { width: 100%; height: 100%; }
.pd-brand__name { font-family: var(--font-heading); font-weight: 600; font-size: 1.06rem; letter-spacing: .02em; }
.pd-brand__name small { font-family: var(--font-data); font-weight: 500; font-size: .62em; letter-spacing: .22em; opacity: .72; }
.pd-nav { font-size: .95rem; }
.pd-nav__list { display: flex; flex-wrap: wrap; align-items: center; gap: clamp(1rem, 2.4vw, 2rem); margin: 0; padding: 0; list-style: none; }
.pd-nav__link {
  display: inline-flex;
  align-items: center;
  padding: .55rem 0;
  border-bottom: 1px solid transparent;
  color: rgba(255, 255, 255, .78);
  text-decoration: none;
}
.pd-nav__link:hover { color: #fff; }
.pd-nav__link[aria-current="page"],
.pd-nav .current-menu-item > .pd-nav__link,
.pd-nav .current_page_item > .pd-nav__link { color: #fff; border-bottom-color: var(--color-cyan-500); }
.pd-nav__item { position: relative; }
.pd-nav__item--parent > .pd-nav__link::after {
  width: .38rem;
  height: .38rem;
  margin-left: .5rem;
  border-right: 1.5px solid currentColor;
  border-bottom: 1.5px solid currentColor;
  transform: translateY(-1px) rotate(45deg);
  content: "";
}
.pd-nav__item--parent:hover > .pd-nav__link::after,
.pd-nav__item--parent:focus-within > .pd-nav__link::after { transform: translateY(1px) rotate(225deg); }

/* Mega menu: one column per taxonomy, its terms underneath. */
.pd-nav__mega {
  position: absolute;
  top: 100%;
  right: 0;
  z-index: 40;
  width: min(720px, calc(100vw - 2rem));
  margin-top: .35rem;
  padding: 1.6rem 1.7rem 1.15rem;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  background: var(--color-white);
  box-shadow: var(--shadow-soft);
  color: var(--color-ink-900);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-6px);
  transition: opacity .2s ease, transform .2s ease, visibility .2s ease;
}
.pd-nav__mega::before {
  position: absolute;
  top: -1px;
  left: 1.7rem;
  width: 56px;
  height: 2px;
  background: var(--color-cyan-500);
  content: "";
}
.pd-nav__item--parent:hover > .pd-nav__mega,
.pd-nav__item--parent:focus-within > .pd-nav__mega { opacity: 1; visibility: visible; transform: none; }
.pd-nav__mega-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.2rem 1.6rem;
}
.pd-nav__mega-title {
  margin: 0 0 .7rem;
  color: var(--color-blue-600);
  font-family: var(--font-data);
  font-size: .7rem;
  font-weight: 500;
  letter-spacing: .13em;
  text-transform: uppercase;
}
.pd-nav__mega-list { display: grid; gap: .15rem; margin: 0; padding: 0; list-style: none; }
.pd-nav__mega-link {
  display: block;
  padding: .42rem .6rem;
  border-radius: var(--radius-sm);
  color: var(--color-navy-950);
  font-size: .93rem;
  line-height: 1.4;
  text-decoration: none;
  transition: background-color .15s ease, color .15s ease;
}
.pd-nav__mega-link:hover { color: var(--color-blue-600); background: var(--color-mist); }
.pd-nav__mega-link[aria-current="page"] { color: var(--color-blue-600); }
.pd-nav__mega-empty { margin: 0; color: var(--color-steel-400); font-size: .88rem; }
.pd-nav__mega-foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  margin: 1.3rem 0 0;
  padding-top: .95rem;
  border-top: 1px solid var(--color-border);
}
.pd-nav__mega-count {
  color: var(--color-slate-600);
  font-family: var(--font-data);
  font-size: .72rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.pd-nav__mega-all { color: var(--color-blue-600); font-size: .93rem; font-weight: 600; text-decoration: none; }
.pd-nav__mega-all:hover { color: var(--color-navy-950); }
.pd-nav__mega-all .pd-arrow { transition: transform .2s ease; }
.pd-nav__mega-all:hover .pd-arrow { transform: translateX(3px); }
.pd-skip {
  position: absolute;
  top: -100%;
  left: 1rem;
  z-index: 60;
  padding: .6rem 1rem;
  color: var(--color-navy-950);
  background: #fff;
  border-radius: var(--radius-sm);
  font-size: .9rem;
}
.pd-skip:focus { top: 1rem; }

/* ---------- Footer ---------- */
.pd-footer { color: #fff; background: var(--color-footer); }
.pd-footer__inner {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(0, .8fr);
  gap: 2.5rem;
  padding-block: clamp(2.5rem, 5vw, 4rem);
}
.pd-footer__brand .pd-brand__mark { width: 30px; height: 30px; }
.pd-footer__line { max-width: 44ch; margin-top: 1.1rem; color: rgba(255, 255, 255, .56); font-size: .95rem; line-height: 1.7; }
.pd-footer__nav ul { display: flex; flex-wrap: wrap; gap: .4rem 1.6rem; margin: 0; padding: 0; list-style: none; }
.pd-footer__nav a { color: rgba(255, 255, 255, .72); font-size: .95rem; text-decoration: none; }
.pd-footer__nav a:hover { color: #fff; }
.pd-footer__meta {
  grid-column: 1 / -1;
  margin: 0;
  padding-top: 1.8rem;
  border-top: 1px solid rgba(255, 255, 255, .1);
  color: rgba(255, 255, 255, .42);
  font-family: var(--font-data);
  font-size: .68rem;
  letter-spacing: .1em;
  text-transform: uppercase;
}

/* ---------- Media placeholder component ---------- */
.pd-media {
  position: relative;
  display: flex;
  min-height: 180px;
  margin: 0;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  border: 1px dashed var(--color-steel-400);
  border-radius: var(--radius-lg);
  background: var(--color-mist);
}
.pd-media--16x9 { aspect-ratio: 16 / 9; }
.pd-media--3x2 { aspect-ratio: 3 / 2; }
.pd-media--2x1 { aspect-ratio: 2 / 1; }
.pd-media--4x3 { aspect-ratio: 4 / 3; }
.pd-media--1x1 { aspect-ratio: 1 / 1; }
.pd-media__grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(11, 23, 54, .05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(11, 23, 54, .05) 1px, transparent 1px);
  background-size: 44px 44px;
}
.pd-media__caption {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: .45rem;
  padding: 1rem;
  text-align: center;
}
.pd-media__label {
  color: var(--color-slate-600);
  font-family: var(--font-data);
  font-size: .74rem;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.pd-media__note { color: var(--color-steel-400); font-family: var(--font-data); font-size: .66rem; letter-spacing: .06em; }
.pd-media--dark { border-color: rgba(255, 255, 255, .28); background: rgba(255, 255, 255, .05); }
.pd-media--dark .pd-media__grid {
  background-image:
    linear-gradient(rgba(255, 255, 255, .06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .06) 1px, transparent 1px);
}
.pd-media--dark .pd-media__label { color: rgba(255, 255, 255, .78); }
.pd-media--dark .pd-media__note { color: rgba(255, 255, 255, .42); }

/* ---------- Photo slot component (placeholder photography with its size) ---------- */
.pd-pmedia { overflow: hidden; border: 1px solid var(--color-border); border-radius: var(--radius-md); background: var(--color-white); }
/* placehold.co is drawn as a CSS background because an SVG in an <img> is clipped
   rather than scaled by object-fit; the caption states the size to supply. */
.pd-pmedia__frame {
  aspect-ratio: 3 / 2;
  background-color: var(--color-mist);
  background-image: url("https://placehold.co/1200x800/DCE3EA/475569");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
}
.pd-pmedia__image { display: block; width: 100%; height: auto; aspect-ratio: 3 / 2; object-fit: cover; }
/* Generated artwork variant: the drawing replaces the placehold.co frame. */
.pd-pmedia__frame--art { background-image: none; background-color: var(--color-navy-950); }
.pd-pmedia__frame--art svg { display: block; width: 100%; height: auto; }
.pd-pmedia__caption {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: .8rem;
  margin: 0;
  padding: .85rem 1rem .95rem;
  border-top: 1px solid var(--color-border);
}
.pd-pmedia__label { color: var(--color-navy-950); font-size: .9rem; line-height: 1.4; }
.pd-pmedia__size {
  flex: none;
  color: var(--color-slate-600);
  font-family: var(--font-data);
  font-size: .72rem;
  letter-spacing: .08em;
}
.pd-pmedia-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(1.2rem, 2.5vw, 2rem);
  margin: 0;
  padding: 0;
  list-style: none;
}
.pd-pmedia-grid--single { grid-template-columns: 1fr; }
.pd-pmedia-grid--pair { grid-template-columns: repeat(2, minmax(0, 1fr)); }
@media (max-width: 960px) {
  .pd-pmedia-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .pd-pmedia-grid--single { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .pd-pmedia-grid,
  .pd-pmedia-grid--pair { grid-template-columns: 1fr; }
}

/* ---------- Starter front page (placeholder content) ---------- */
.hero { padding-block: clamp(3.5rem, 8vw, 6.5rem); }
.hero > * + * { margin-top: 1.1rem; }
.hero h1 { margin-top: 1.1rem; }
.hero section { margin-top: 3rem; padding-top: 2.5rem; border-top: 1px solid var(--color-border); }

/* ---------- Generic content template ---------- */
.pd-prose { max-width: 70ch; padding-block: clamp(3rem, 7vw, 5rem); }
.pd-prose > * + * { margin-top: 1.1rem; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .pd-section-head { grid-template-columns: 1fr; gap: 1.2rem; }
  .pd-footer__inner { grid-template-columns: 1fr; gap: 2rem; }
}
@media (max-width: 640px) {
  .pd-header__inner { min-height: 0; padding-block: .9rem; flex-wrap: wrap; gap: .7rem; }
  .pd-nav { width: 100%; }
  /* Touch screens have no hover: show the mega menu as an indented list. */
  .pd-nav__item--parent > .pd-nav__link::after { display: none; }
  .pd-nav__mega {
    position: static;
    width: auto;
    margin: .3rem 0 0;
    padding: 0 0 0 .8rem;
    border: 0;
    border-left: 1px solid rgba(255, 255, 255, .22);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
  }
  .pd-nav__mega::before { display: none; }
  .pd-nav__mega-grid { grid-template-columns: 1fr; gap: .9rem; }
  .pd-nav__mega-title { margin-bottom: .4rem; color: rgba(255, 255, 255, .5); }
  .pd-nav__mega-list { display: flex; flex-wrap: wrap; gap: .1rem .8rem; }
  .pd-nav__mega-link { padding: .3rem .4rem; color: rgba(255, 255, 255, .72); }
  .pd-nav__mega-link:hover { color: #fff; background: rgba(255, 255, 255, .08); }
  .pd-nav__mega-link[aria-current="page"] { color: #fff; }
  .pd-nav__mega-empty { color: rgba(255, 255, 255, .38); }
  .pd-nav__mega-foot { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
}

