/* ============================================================
   COLLEGIUM ALOUISI — decentní, konzervativně moderní
   paleta podle tištěné předlohy: šalvěj / krém / vínová / zlatá
   ============================================================ */

:root {
  --cream:      #f0ede3;
  --paper:      #e7e3d4;
  --sage:       #a9b8a1;
  --sage-deep:  #7e9178;
  --green-ink:  #3e4f3c;
  --green-dark: #2e3b2d;
  --ink:        #2b2a24;
  --wine:       #6e3b35;
  --gold:       #a98a4f;
  --line:       rgba(62, 79, 60, .25);

  --serif-display: "Cormorant Garamond", "Georgia", serif;
  --serif-body:    "Crimson Pro", "Georgia", serif;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 4.5rem; }

body {
  font-family: var(--serif-body);
  font-size: 1.18rem;
  font-weight: 400;
  line-height: 1.65;
  color: var(--ink);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  /* skákavé (renesanční) číslice ladí s klasicistní sazbou */
  font-variant-numeric: oldstyle-nums;
}

::selection { background: rgba(169, 184, 161, .55); }

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

p { text-wrap: pretty; }

/* jemné papírové zrno přes celou stránku */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 4;
  opacity: .35;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0.04 0'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)'/%3E%3C/svg%3E");
}

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

h1, h2, h3 {
  font-family: var(--serif-display);
  font-weight: 600;
  color: var(--green-ink);
  text-wrap: balance;
  font-variant-ligatures: common-ligatures;
}

h2 {
  font-size: clamp(2.1rem, 4.5vw, 3rem);
  line-height: 1.1;
  letter-spacing: -.01em; /* velké stupně Cormorantu snesou mírné stažení */
  margin-bottom: 1.4rem;
}

a {
  color: var(--wine);
  text-decoration-color: rgba(110, 59, 53, .35);
  text-underline-offset: 3px;
  transition: text-decoration-color .25s ease, color .25s ease;
}
a:hover { text-decoration-color: var(--wine); }

.kicker {
  font-family: var(--serif-body);
  font-size: .82rem;
  font-weight: 600;
  letter-spacing: .32em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: .9rem;
}
.kicker::after {
  content: "";
  display: inline-block;
  vertical-align: middle;
  width: 3.2rem;
  height: 1px;
  margin-left: 1rem;
  background: linear-gradient(to right, var(--gold), rgba(169, 138, 79, 0));
  opacity: .75;
}
.kicker-center::after { display: none; }
.kicker-center { text-align: center !important; }
.kicker-light { color: #d8c9a3; }

/* ============ TOP BAR ============ */

.topbar {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  gap: 2rem;
  padding: 1rem clamp(1.2rem, 4vw, 3rem);
  color: var(--cream);
  transition: background .35s ease, box-shadow .35s ease, padding .35s ease;
}
.topbar.solid {
  background: rgba(46, 59, 45, .96);
  box-shadow: 0 1px 0 rgba(240, 237, 227, .12);
  padding-top: .6rem;
  padding-bottom: .6rem;
}

.brand {
  display: flex;
  align-items: center;
  gap: .7rem;
  text-decoration: none;
  color: inherit;
  margin-right: auto;
}
.brand-mark {
  font-family: var(--serif-display);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: .08em;
  width: 2.4rem; height: 2.4rem;
  display: grid; place-items: center;
  border: 1px solid rgba(240, 237, 227, .55);
  border-radius: 50%;
  transition: border-color .3s ease, color .3s ease;
}
.brand:hover .brand-mark { border-color: var(--gold); color: #e4d9bb; }
.brand-name {
  font-family: var(--serif-display);
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.nav { display: flex; gap: 1.6rem; }
.nav a {
  color: inherit;
  text-decoration: none;
  font-size: .95rem;
  letter-spacing: .1em;
  text-transform: uppercase;
  font-weight: 500;
  padding-bottom: .2rem;
  border-bottom: 1px solid transparent;
  transition: border-color .25s;
}
.nav a:hover { border-bottom-color: var(--gold); }

.lang-switch { display: flex; border: 1px solid rgba(240, 237, 227, .45); border-radius: 2rem; overflow: hidden; }
.lang-switch button {
  appearance: none;
  background: transparent;
  border: 0;
  color: inherit;
  font-family: var(--serif-body);
  font-size: .8rem;
  font-weight: 600;
  letter-spacing: .08em;
  padding: .35rem .75rem;
  cursor: pointer;
  transition: background .25s, color .25s;
}
.lang-switch button:hover { background: rgba(240, 237, 227, .15); }
.lang-switch button.active { background: var(--cream); color: var(--green-ink); }

/* ============ HERO ============ */

.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  text-align: center;
  color: var(--cream);
  overflow: hidden;
}
.hero-photo {
  position: absolute; inset: 0;
  background: url("img/hero-mikulov.jpg") center 30% / cover no-repeat;
  transform: scale(1.06);
  animation: heroDrift 18s ease-out forwards;
}
@keyframes heroDrift { to { transform: scale(1.0); } }
.hero-veil {
  position: absolute; inset: 0;
  background:
    linear-gradient(to bottom, rgba(46,59,45,.55) 0%, rgba(46,59,45,.35) 35%, rgba(46,59,45,.72) 100%);
}
.hero-inner { position: relative; z-index: 1; padding: 6rem 1.5rem 4rem; max-width: 60rem; }

.hero-eyebrow {
  font-size: .9rem;
  letter-spacing: .38em;
  text-transform: uppercase;
  color: #e4d9bb;
}
.hero-title {
  font-size: clamp(3rem, 9vw, 6.8rem);
  font-weight: 600;
  letter-spacing: .06em;
  line-height: 1.04;
  color: var(--cream);
  margin: 1rem 0 1.2rem;
  text-shadow: 0 2px 30px rgba(0,0,0,.35);
}
.hero-rule { display: flex; align-items: center; justify-content: center; gap: 1rem; margin-bottom: 1.4rem; }
.rule-line { display: block; width: clamp(3rem, 10vw, 7rem); height: 1px; background: rgba(240,237,227,.6); }
.rule-orn { font-size: 1.3rem; color: var(--gold); }

.hero-motto {
  font-family: var(--serif-display);
  font-style: italic;
  font-size: clamp(1.5rem, 3.2vw, 2.2rem);
  font-weight: 500;
  color: #ecdfc0;
}
.hero-scroll {
  position: absolute;
  bottom: 2.2rem; left: 50%;
  transform: translateX(-50%);
  z-index: 1;
  width: 1.6rem; height: 2.6rem;
  border: 1px solid rgba(240,237,227,.6);
  border-radius: 1rem;
}
.hero-scroll span {
  position: absolute;
  top: .5rem; left: 50%;
  width: 3px; height: 7px;
  margin-left: -1.5px;
  border-radius: 2px;
  background: var(--cream);
  animation: scrollHint 2s infinite;
}
@keyframes scrollHint { 0%{opacity:1; transform:translateY(0)} 70%{opacity:0; transform:translateY(.8rem)} 100%{opacity:0} }

/* ============ INTRO ============ */

.intro { padding: clamp(4.5rem, 9vw, 7.5rem) 1.5rem; }
.intro-inner { max-width: 46rem; margin-inline: auto; text-align: center; }

/* notová osnova z tištěné předlohy — při odhalení se „dopisuje" zleva */
.orn-staff {
  width: clamp(200px, 36vw, 260px);
  height: auto;
  margin: 0 auto 2.2rem;
  opacity: .9;
  clip-path: inset(0 100% 0 0);
  transition: clip-path 1.5s ease .25s;
}
.reveal.visible .orn-staff { clip-path: inset(0 0 0 0); }

.intro-lead {
  font-family: var(--serif-display);
  font-size: clamp(1.35rem, 2.6vw, 1.7rem);
  line-height: 1.55;
  font-weight: 500;
  color: var(--green-ink);
}

.intro-dates {
  margin-top: 2.4rem;
  display: inline-flex;
  align-items: baseline;
  gap: .8rem;
  color: var(--gold);
}
.intro-dates span { font-size: .8rem; letter-spacing: .3em; text-transform: uppercase; }
.intro-dates em {
  font-family: var(--serif-display);
  font-style: normal;
  font-size: 1.6rem;
  font-weight: 600;
  color: var(--wine);
}

/* ============ O NÁS ============ */

.about { background: var(--paper); padding: clamp(4rem, 8vw, 7rem) clamp(1.5rem, 5vw, 4rem); }
.about-grid {
  max-width: 70rem;
  margin-inline: auto;
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 6fr);
  gap: clamp(2rem, 6vw, 5rem);
  align-items: center;
}
.about-photo { position: relative; }
.about-photo img {
  width: 100%;
  border: 1px solid var(--line);
  padding: .55rem;
  background: var(--cream);
  box-shadow: 14px 14px 0 0 var(--sage);
  transition: box-shadow .4s ease, transform .4s ease;
}
.about-photo:hover img { transform: translate(-2px, -2px); box-shadow: 16px 16px 0 0 var(--sage); }
.about-photo figcaption {
  margin-top: 1.4rem;
  font-style: italic;
  font-size: .95rem;
  color: var(--sage-deep);
}
.about-text p + p { margin-top: 1rem; }

/* tiché české dělení slov v delších odstavcích */
.about-text p, .alouisi-card p, .mission-body { hyphens: auto; }

/* ============ ALOUISI ============ */

.alouisi {
  background: var(--sage);
  padding: clamp(4rem, 8vw, 7rem) 1.5rem;
}
.alouisi-card {
  max-width: 46rem;
  margin-inline: auto;
  background: var(--cream);
  text-align: center;
  padding: clamp(2.5rem, 6vw, 4.5rem) clamp(1.8rem, 5vw, 4rem);
  border: 1px solid var(--green-ink);
  outline: 1px solid var(--green-ink);
  outline-offset: 6px;
  box-shadow: 0 24px 50px -28px rgba(46, 59, 45, .55);
}
.alouisi-dates {
  font-family: var(--serif-display);
  font-style: italic;
  color: var(--wine);
  margin-bottom: 1.6rem;
}
.alouisi-card p { text-align: left; }
.alouisi-card p + p { margin-top: 1rem; }

.has-dropcap::first-letter {
  font-family: var(--serif-display);
  float: left;
  font-size: 3.6em;
  line-height: .82;
  padding: .04em .12em 0 0;
  color: var(--wine);
  font-weight: 600;
}

/* ============ POSELSTVÍ ============ */

.mission { position: relative; padding: clamp(5rem, 11vw, 9rem) 1.5rem; overflow: hidden; }
.mission-photo {
  position: absolute; inset: 0;
  background: url("img/koncert-kostel.jpg") center 25% / cover no-repeat;
}
.mission-veil { position: absolute; inset: 0; background: rgba(36, 46, 35, .82); }
.mission-inner {
  position: relative; z-index: 1;
  max-width: 48rem;
  margin-inline: auto;
  text-align: center;
  color: var(--cream);
}
/* vlaštovka z tištěné předlohy — nese poselství */
.mission-orn {
  width: 3.4rem;
  height: auto;
  margin: 0 auto 1.2rem;
  opacity: .8;
}

.mission-quote {
  font-family: var(--serif-display);
  font-style: italic;
  font-weight: 500;
  font-size: clamp(1.6rem, 3.6vw, 2.5rem);
  line-height: 1.35;
  margin-bottom: 1.6rem;
  color: #f0e8d2;
  hanging-punctuation: first; /* uvozovka visí před sazebním obrazcem (Safari) */
}
.mission-body { font-weight: 300; color: rgba(240, 237, 227, .88); }

/* ============ KONCERTY ============ */

.concerts { padding: clamp(4.5rem, 9vw, 7.5rem) clamp(1.5rem, 5vw, 4rem); overflow: hidden; }
.concerts-inner { position: relative; max-width: 56rem; margin-inline: auto; }

/* houslový klíč z tištěné předlohy jako jemný vodoznak vedle programu */
.concerts-clef {
  position: absolute;
  left: -9.5rem;
  top: 50%;
  transform: translateY(-50%) rotate(-4deg);
  width: 7.5rem;
  height: auto;
  opacity: .14;
  pointer-events: none;
}
@media (max-width: 76rem) { .concerts-clef { display: none; } }

.concert-list { list-style: none; border-top: 1px solid var(--line); }
.concert {
  display: grid;
  grid-template-columns: 8.5rem 1fr auto;
  align-items: center;
  gap: 1.5rem;
  padding: 1.6rem .4rem;
  border-bottom: 1px solid var(--line);
}
/* vyšší specificita, aby přechod nepřepsalo obecné .reveal
   (opacity/transform musí zůstat kvůli odhalování při skrolu) */
.concert-list .concert {
  transition:
    opacity .9s ease, transform .9s ease,
    background .3s, padding-left .3s ease, box-shadow .3s ease;
}
.concert:hover {
  background: rgba(169, 184, 161, .18);
  padding-left: .9rem;
  box-shadow: inset 3px 0 0 var(--gold);
}

/* data a časy s verzálkovými číslicemi, ať drží linku */
.c-date, .c-time { font-variant-numeric: lining-nums; }

.c-date { display: flex; align-items: baseline; gap: .55rem; color: var(--wine); }
.c-day {
  font-family: var(--serif-display);
  font-size: 2.6rem;
  font-weight: 600;
  line-height: 1;
}
.c-rest { font-size: .95rem; letter-spacing: .06em; color: var(--sage-deep); }

.c-info h3 { font-size: 1.45rem; font-weight: 600; }
.c-info p { font-style: italic; color: var(--sage-deep); font-size: 1rem; }

.c-time {
  font-family: var(--serif-display);
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--green-ink);
  border: 1px solid var(--line);
  border-radius: 2rem;
  padding: .25rem .9rem;
  white-space: nowrap;
}

.concerts-fb {
  margin-top: 2.6rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 1.2rem;
  font-style: italic;
  color: var(--sage-deep);
}
.btn-fb {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  font-style: normal;
  font-weight: 600;
  font-size: 1rem;
  letter-spacing: .04em;
  text-decoration: none;
  color: var(--cream);
  background: var(--green-ink);
  padding: .65rem 1.3rem;
  border-radius: 2rem;
  transition: background .3s, transform .2s;
}
.btn-fb:hover { background: var(--wine); transform: translateY(-2px); }
.btn-fb svg { width: 1.15rem; height: 1.15rem; }

/* ============ GALERIE ============ */

.gallery { background: var(--paper); padding: clamp(4rem, 8vw, 7rem) clamp(1.5rem, 5vw, 4rem); }
.gallery-head, .gallery-grid { max-width: 70rem; margin-inline: auto; }
.gallery-head { margin-bottom: 2.5rem; }

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  grid-auto-rows: 11rem;
  gap: 1rem;
}
.g-item { overflow: hidden; }
.g-item img {
  width: 100%; height: 100%;
  object-fit: cover;
  transition: transform .8s ease, filter .8s ease;
  filter: saturate(.92);
}
.g-item:hover img { transform: scale(1.045); filter: saturate(1.05); }
.g-wide { grid-column: span 4; grid-row: span 2; }
.g-tall { grid-column: span 2; grid-row: span 2; }
.g-item:not(.g-wide):not(.g-tall) { grid-column: span 2; grid-row: span 2; }

/* ============ PATIČKA ============ */

.footer { background: var(--green-dark); color: rgba(240, 237, 227, .85); padding: clamp(3.5rem, 7vw, 5.5rem) clamp(1.5rem, 5vw, 4rem) 2rem; }
.footer-inner {
  max-width: 70rem;
  margin-inline: auto;
  display: grid;
  grid-template-columns: 2fr 1fr 1.4fr 1fr;
  gap: 2.5rem;
  padding-bottom: 2.5rem;
  border-bottom: 1px solid rgba(240, 237, 227, .18);
}
.f-title {
  font-family: var(--serif-display);
  font-size: 1.6rem;
  font-weight: 600;
  letter-spacing: .08em;
  color: var(--cream);
}
.f-motto { font-style: italic; color: #cfc3a2; margin-top: .4rem; }
.f-label {
  font-size: .78rem;
  letter-spacing: .28em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: .7rem;
}
.footer a { color: inherit; text-decoration-color: rgba(240,237,227,.3); }
.footer a:hover { color: var(--cream); }
.f-fb { display: inline-flex; align-items: center; gap: .5rem; text-decoration: none; }
.f-fb svg { width: 1.2rem; height: 1.2rem; }

/* kontaktní ikonky z tištěné předlohy */
.f-ico {
  display: inline-block;
  height: .95em;
  width: auto;
  margin-right: .55rem;
  vertical-align: -.08em;
  opacity: .85;
}
.f-bottom {
  max-width: 70rem;
  margin: 1.6rem auto 0;
  font-size: .92rem;
  color: rgba(240, 237, 227, .55);
}
.f-bottom::before {
  content: "❧";
  display: block;
  text-align: center;
  color: var(--gold);
  opacity: .7;
  font-size: 1.05rem;
  margin-bottom: 1.1rem;
}

/* ============ ANIMACE ============ */

.reveal { opacity: 0; transform: translateY(26px); transition: opacity .9s ease, transform .9s ease; }
.reveal.visible { opacity: 1; transform: none; }

.reveal-load { opacity: 0; transform: translateY(18px); animation: rise .9s ease forwards; }
.d1 { animation-delay: .15s; }
.d2 { animation-delay: .35s; }
.d3 { animation-delay: .5s; }
.d4 { animation-delay: .65s; }
.d5 { animation-delay: 1.1s; }
@keyframes rise { to { opacity: 1; transform: none; } }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal, .reveal-load { opacity: 1; transform: none; animation: none; transition: none; }
  .hero-photo { animation: none; transform: none; }
  .hero-scroll span { animation: none; }
  .orn-staff { clip-path: none; transition: none; }
}

/* ============ RESPONSIVITA ============ */

@media (max-width: 56rem) {
  .nav { display: none; }
  .about-grid { grid-template-columns: 1fr; }
  .about-photo img { box-shadow: 10px 10px 0 0 var(--sage); }
  .footer-inner { grid-template-columns: 1fr 1fr; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); grid-auto-rows: 12rem; }
  .g-wide, .g-tall, .g-item:not(.g-wide):not(.g-tall) { grid-column: span 2; grid-row: span 2; }
  .g-tall { grid-row: span 2; }
}

@media (max-width: 38rem) {
  .brand-name { display: none; }
  .concert { grid-template-columns: 1fr; gap: .4rem; }
  .c-time { justify-self: start; }
  .footer-inner { grid-template-columns: 1fr; gap: 1.8rem; }
}
