/* ============================================================
   KARAJOVIC.COM — Main Stylesheet
   ============================================================ */

/* ── RESET ─────────────────────────────────────────────── */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }

/* ── CUSTOM PROPERTIES ─────────────────────────────────── */
:root {
  --cream:        #f5efe4;
  --parchment:    #ede3d0;
  --gold:         #b8923a;
  --gold-light:   #d4aa5a;
  --gold-pale:    #e8d5a8;
  --ink:          #1c1610;
  --ink-mid:      #3a2f20;
  --ink-soft:     #6b5a43;
  --ink-muted:    #9e8b72;
  --border:       rgba(184,146,58,0.25);
  --border-soft:  rgba(184,146,58,0.12);
  --srb-blue:     #0057a0;
  --usa-red:      #b22234;
  --shadow:       0 2px 20px rgba(28,22,16,0.10);
}

/* ── BASE ───────────────────────────────────────────────── */
body {
  font-family: 'EB Garamond', Georgia, serif;
  background: var(--cream);
  color: var(--ink);
  font-size: 17px;
  line-height: 1.75;
  overflow-x: hidden;
}

body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.65' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 0;
  opacity: 0.7;
}

.wrapper { position: relative; z-index: 1; }

/* ── NAVIGATION ─────────────────────────────────────────── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(245,239,228,0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  padding: 0 40px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 60px;
}

.nav-brand {
  font-family: 'Playfair Display', serif;
  font-size: 21px;
  letter-spacing: 0.06em;
  color: var(--ink);
  text-decoration: none;
}
.nav-brand em { color: var(--gold); font-style: italic; }

.nav-links { display: flex; gap: 32px; list-style: none; }
.nav-links a {
  font-family: 'Lato', sans-serif;
  font-size: 11px;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--gold); }

/* ── HERO ───────────────────────────────────────────────── */
.hero {
  min-height: 88vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 80px 24px 60px;
  position: relative;
  overflow: hidden;
}

.hero-bg {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(245,239,228,0) 40%, rgba(245,239,228,1) 100%),
    linear-gradient(135deg, rgba(184,146,58,0.06) 0%, transparent 60%);
  pointer-events: none;
}

.ornament {
  font-size: 13px;
  letter-spacing: 0.5em;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 28px;
  animation: fadeDown 1.2s ease both;
}

.hero-title {
  font-family: 'Playfair Display', serif;
  font-size: clamp(52px, 9vw, 110px);
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 0.92;
  color: var(--ink);
  margin-bottom: 6px;
  animation: fadeDown 1.2s 0.1s ease both;
}

.hero-italic {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 5vw, 56px);
  font-weight: 400;
  font-style: italic;
  color: var(--gold);
  letter-spacing: 0.04em;
  margin-bottom: 32px;
  animation: fadeDown 1.2s 0.2s ease both;
}

.hero-rule {
  display: flex;
  align-items: center;
  gap: 16px;
  justify-content: center;
  margin-bottom: 28px;
  animation: fadeDown 1.2s 0.3s ease both;
}
.hr-line   { width: 80px; height: 1px; background: var(--border); }
.hr-diamond { width: 7px; height: 7px; background: var(--gold); transform: rotate(45deg); }

.hero-sub {
  font-family: 'EB Garamond', serif;
  font-size: 19px;
  font-style: italic;
  color: var(--ink-soft);
  max-width: 480px;
  line-height: 1.6;
  animation: fadeDown 1.2s 0.4s ease both;
}

.hero-flags {
  display: flex;
  gap: 20px;
  align-items: center;
  justify-content: center;
  margin-top: 36px;
  animation: fadeDown 1.2s 0.5s ease both;
}
.hf-tag {
  font-family: 'Lato', sans-serif;
  font-size: 11px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--ink-muted);
  display: flex;
  align-items: center;
  gap: 8px;
}
.pip { width: 9px; height: 9px; border-radius: 50%; }
.pip-srb { background: var(--srb-blue); }
.pip-usa { background: var(--usa-red); }
.hf-sep  { color: var(--gold-pale); font-size: 18px; }

/* ── SECTION SHARED ─────────────────────────────────────── */
.section { padding: 70px 40px; max-width: 1120px; margin: 0 auto; }

.sep {
  max-width: 1120px;
  margin: 0 auto;
  border: none;
  border-top: 1px solid var(--border-soft);
}

.eyebrow {
  font-family: 'Lato', sans-serif;
  font-size: 10px;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 16px;
}

.s-head {
  font-family: 'Playfair Display', serif;
  font-size: clamp(28px, 4vw, 42px);
  font-weight: 600;
  color: var(--ink);
  line-height: 1.15;
  margin-bottom: 8px;
}

.s-sub {
  font-size: 16px;
  color: var(--ink-soft);
  margin-bottom: 40px;
  font-style: italic;
}

/* ── CLOCKS SECTION ─────────────────────────────────────── */
#clocks { background: var(--ink); }
#clocks .eyebrow { color: var(--gold-light); }
#clocks .s-head  { color: var(--cream); }
#clocks .s-sub   { color: rgba(245,239,228,0.5); }

.clocks-duo {
  display: grid;
  grid-template-columns: 1fr 1px 1fr;
  max-width: 700px;
  margin: 0 auto;
  border: 1px solid rgba(245,239,228,0.08);
}
.clocks-sep { background: rgba(245,239,228,0.08); }

.clock-panel { text-align: center; padding: 36px 28px 40px; }

.ck-city {
  font-family: 'Playfair Display', serif;
  font-size: 22px;
  color: var(--cream);
  margin-bottom: 3px;
}
.ck-tz {
  font-family: 'Lato', sans-serif;
  font-size: 10px;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: rgba(184,146,58,0.65);
  margin-bottom: 24px;
}

.analog-wrap {
  width: 130px;
  height: 130px;
  border: 1.5px solid rgba(184,146,58,0.4);
  border-radius: 50%;
  margin: 0 auto 20px;
  position: relative;
  background: rgba(184,146,58,0.04);
}
.acenter {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%,-50%);
  width: 7px; height: 7px;
  border-radius: 50%;
  background: var(--gold);
  z-index: 10;
}
.ahand {
  position: absolute;
  bottom: 50%; left: 50%;
  transform-origin: bottom center;
  border-radius: 3px;
}
.ah  { width: 2.5px; height: 34px; margin-left: -1.25px; background: var(--cream); }
.am  { width: 2px;   height: 46px; margin-left: -1px;    background: var(--gold-light); }
.asec{ width: 1px;   height: 48px; margin-left: -0.5px;  background: #e06060; }

.ck-digi {
  font-family: 'Lato', sans-serif;
  font-size: 28px;
  font-weight: 300;
  letter-spacing: 0.12em;
  color: var(--cream);
}
.ck-date {
  font-family: 'EB Garamond', serif;
  font-size: 14px;
  font-style: italic;
  color: rgba(184,146,58,0.65);
  margin-top: 6px;
}

/* ── WEATHER SECTION ────────────────────────────────────── */
.wgroup { margin-bottom: 40px; }

.wg-title {
  font-family: 'Lato', sans-serif;
  font-size: 10px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 14px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.wg-title::after { content: ''; flex: 1; height: 1px; background: var(--border-soft); }

.wrow {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  background: var(--border-soft);
  border: 1px solid var(--border-soft);
}

.wcard {
  background: var(--cream);
  padding: 22px 18px;
  position: relative;
  transition: background 0.2s;
}
.wcard:hover { background: var(--parchment); }

.wflag { position: absolute; top: 0; left: 0; right: 0; height: 2px; }
.srb-flag { background: linear-gradient(90deg, #0057a0, #d4aa5a, #c0392b); }
.usa-flag { background: linear-gradient(90deg, #b22234, #ffffff, #3c3b6e); }

.wc-city {
  font-family: 'Playfair Display', serif;
  font-size: 17px;
  color: var(--ink);
  margin-bottom: 1px;
}
.wc-region {
  font-family: 'Lato', sans-serif;
  font-size: 10px;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--ink-muted);
  margin-bottom: 14px;
}
.wc-tr   { display: flex; align-items: baseline; gap: 4px; margin-bottom: 4px; }
.wc-temp { font-family: 'Playfair Display', serif; font-size: 38px; color: var(--ink); line-height: 1; }
.wc-unit { font-size: 16px; color: var(--ink-muted); }
.wc-cond { font-size: 13px; color: var(--ink-soft); font-style: italic; }
.wc-icon { position: absolute; top: 18px; right: 16px; font-size: 22px; }
.wc-high { margin-top: 10px; font-family: 'Lato', sans-serif; font-size: 10px; letter-spacing: 0.1em; color: var(--ink-muted); }

/* ── PLACES SECTION ─────────────────────────────────────── */
#places { background: var(--parchment); }


.places-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 56px; }

.pc-head {
  font-family: 'Playfair Display', serif;
  font-size: 24px;
  font-style: italic;
  color: var(--gold);
  margin-bottom: 28px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 12px;
}

.pe {
  padding: 18px 0;
  border-bottom: 1px solid var(--border-soft);
}
.pe:last-child { border-bottom: none; }

.pe-pill {
  display: inline-block;
  font-family: 'Lato', sans-serif;
  font-size: 9px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  padding: 3px 10px;
  border: 1px solid var(--border);
  color: var(--gold);
  margin-bottom: 7px;
}
.pe-name {
  font-family: 'Playfair Display', serif;
  font-size: 20px;
  color: var(--ink);
  margin-bottom: 6px;
}
.pe-desc { font-size: 15px; color: var(--ink-soft); line-height: 1.65; }

/* ── FOOTER ─────────────────────────────────────────────── */
footer {
  background: var(--ink);
  text-align: center;
  padding: 52px 24px 40px;
  border-top: 1px solid rgba(184,146,58,0.2);
}
.fw {
  font-family: 'Playfair Display', serif;
  font-size: 32px;
  font-style: italic;
  color: rgba(184,146,58,0.6);
  margin-bottom: 8px;
}
.fu {
  font-family: 'Lato', sans-serif;
  font-size: 11px;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(245,239,228,0.22);
  margin-bottom: 28px;
}
.fr { width: 40px; height: 1px; background: rgba(184,146,58,0.25); margin: 0 auto 20px; }
.fc { font-size: 12px; color: rgba(245,239,228,0.22); font-family: 'Lato', sans-serif; letter-spacing: 0.05em; }

/* ── SCROLL REVEAL ──────────────────────────────────────── */
.reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible {
  opacity: 1;
  transform: none;
}

/* ── ANIMATIONS ─────────────────────────────────────────── */
@keyframes fadeDown {
  from { opacity: 0; transform: translateY(-18px); }
  to   { opacity: 1; transform: none; }
}

/* ── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 900px) {
  .photo-grid { grid-template-columns: 1fr 1fr; }
  .photo-grid .wide { grid-column: span 2; aspect-ratio: 4/3; }
  .pf.wide { aspect-ratio: 4/3; }
}

@media (max-width: 768px) {
  nav { padding: 0 20px; }
  .nav-links { gap: 16px; }
  .section { padding: 50px 20px; }
  .clocks-duo { grid-template-columns: 1fr; }
  .clocks-sep { display: none; }
  .wrow { grid-template-columns: 1fr 1fr; }
  .places-cols { grid-template-columns: 1fr; gap: 32px; }
}

@media (max-width: 540px) {
  .nav-links { display: none; }
  .wrow { grid-template-columns: 1fr; }
  .photo-grid { grid-template-columns: 1fr; }
  .photo-grid .wide { grid-column: span 1; }
}
