/* Pohřební služba Záře – jednostránkový web */

@font-face { font-family: "Cormorant Garamond"; src: url(fonts/cormorant.woff2) format("woff2"); font-weight: 500 600; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Cormorant Garamond"; src: url(fonts/cormorant-ext.woff2) format("woff2"); font-weight: 500 600; font-display: swap; unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Arsenal"; src: url(fonts/arsenal-400.woff2) format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Arsenal"; src: url(fonts/arsenal-400-ext.woff2) format("woff2"); font-weight: 400; font-display: swap; unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Arsenal"; src: url(fonts/arsenal-700.woff2) format("woff2"); font-weight: 700; font-display: swap; unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Arsenal"; src: url(fonts/arsenal-700-ext.woff2) format("woff2"); font-weight: 700; font-display: swap; unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  --bg: #fbf7f0;
  --tint: #f5eee2;
  --surface: #fffdf9;
  --ink: #2a251f;
  --muted: #6b6155;
  --line: #e7dccb;
  --gold: #8a6a22;          /* text a odkazy – kontrast 5:1 na pozadí */
  --gold-soft: #c9a55a;
  --glow: rgba(236, 196, 120, .5);
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Arsenal", "Segoe UI", Arial, sans-serif;
  --wrap: 1120px;
  --radius: 14px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  --shadow: 0 24px 60px -36px rgba(90, 66, 20, .35);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.125rem/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
}
/* jemná papírová textura, aby plochy nepůsobily prázdně */
body::before {
  content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; 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='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .55 0 0 0 0 .45 0 0 0 0 .3 0 0 0 .08 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}
img { display: block; max-width: 100%; height: auto; }
figure { margin: 0; }
a { color: var(--gold); text-underline-offset: .2em; transition: color .3s var(--ease); }
a:focus-visible, summary:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.1; margin: 0; text-wrap: balance; }
h1, h2, h3, .hero__tel, .facts strong, .steps li::before, .pay dt, .closing__tel { font-variant-numeric: lining-nums; }
h2 { font-size: clamp(2.1rem, 4.2vw, 3rem); margin-bottom: .5rem; }
h3 { font-size: 1.5rem; }
p { margin: 0 0 .75rem; }

.wrap { width: min(100% - 32px, var(--wrap)); margin-inline: auto; }

/* Odkazy s jemně „vyrůstajícím“ podtržením */
.branch__links a, .hero__alt a, .help a, .footer a, .nav a {
  text-decoration: none;
  background: linear-gradient(currentColor, currentColor) 0 100% / 100% 1px no-repeat;
  transition: background-size .4s var(--ease), color .3s var(--ease);
}
.branch__links a:hover, .hero__alt a:hover, .help a:hover, .footer a:hover { background-size: 0 1px; background-position: 100% 100%; }

/* Horní lišta */
.topbar {
  position: sticky; top: 0; z-index: 10;
  background: rgba(251, 247, 240, .82);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid transparent;
  transition: border-color .4s var(--ease), box-shadow .4s var(--ease), background .4s var(--ease);
}
.topbar.is-scrolled { border-color: var(--line); background: rgba(251, 247, 240, .94); box-shadow: 0 10px 30px -24px rgba(60, 40, 10, .4); }
.topbar__in { display: flex; align-items: center; gap: 24px; min-height: 76px; transition: min-height .4s var(--ease); }
.topbar.is-scrolled .topbar__in { min-height: 64px; }
.brand { display: flex; align-items: center; gap: 12px; color: var(--ink); text-decoration: none; font-family: var(--serif); font-weight: 600; font-size: 1.35rem; }
.brand img { width: 44px; height: 44px; border-radius: 8px; transition: transform .5s var(--ease); }
.brand:hover img { transform: rotate(-4deg) scale(1.04); }
.nav { display: flex; gap: 28px; margin-left: auto; }
.nav a { color: var(--muted); font-size: 1rem; background-size: 0 1px; background-position: 100% 100%; }
.nav a:hover, .nav a.is-active { color: var(--ink); background-size: 100% 1px; background-position: 0 100%; }
.topbar__tel { display: flex; flex-direction: column; align-items: flex-end; text-decoration: none; font-weight: 700; font-size: 1.25rem; line-height: 1.15; color: var(--ink); }
.topbar__tel:hover { color: var(--gold); }
.topbar__tel small { font-weight: 400; font-size: .8rem; color: var(--muted); }

/* Úvod – teplá „záře“ za kontaktem */
.hero { position: relative; overflow: hidden; padding: clamp(48px, 7vw, 96px) 0 clamp(40px, 5vw, 64px); }
.hero__glow {
  position: absolute; z-index: -1; pointer-events: none;
  width: min(900px, 120vw); aspect-ratio: 1; right: -12%; top: -18%;
  background: radial-gradient(circle, var(--glow) 0%, rgba(236, 196, 120, .18) 38%, transparent 68%);
  transform: translate3d(0, calc(var(--sy, 0) * .25px), 0);
  animation: breathe 9s ease-in-out infinite;
}
@keyframes breathe { 50% { opacity: .7; scale: 1.06; } }
.hero__in { display: grid; grid-template-columns: 1.1fr 1fr; gap: clamp(32px, 6vw, 80px); align-items: center; }
.eyebrow { text-transform: uppercase; letter-spacing: .14em; font-size: .85rem; color: var(--gold); font-weight: 700; margin-bottom: 1rem; }
.hero h1 { font-size: clamp(2.6rem, 6vw, 4.6rem); margin-bottom: 1.25rem; }
.lead { font-size: 1.3rem; color: var(--ink); max-width: 34ch; }
.note { margin-top: 1.5rem; padding-left: 16px; border-left: 2px solid var(--gold-soft); color: var(--muted); font-size: 1.05rem; max-width: 42ch; }

.hero__contact {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(28px, 4vw, 44px);
  box-shadow: 0 30px 80px -40px rgba(138, 106, 34, .5);
  transition: translate .6s var(--ease), box-shadow .6s var(--ease);
}
.hero__contact::before {   /* zlatá linka nahoře karty */
  content: ""; position: absolute; left: 28px; right: 28px; top: -1px; height: 2px;
  background: linear-gradient(90deg, transparent, var(--gold-soft), transparent);
}
.hero__contact:hover { translate: 0 -3px; box-shadow: 0 40px 90px -40px rgba(138, 106, 34, .6); }
.hero__label { display: flex; align-items: center; gap: 10px; color: var(--muted); margin-bottom: .25rem; }
.pulse { width: 8px; height: 8px; border-radius: 50%; background: #5f9a5a; box-shadow: 0 0 0 0 rgba(95, 154, 90, .5); animation: pulse 2.6s ease-out infinite; }
@keyframes pulse { 70%, 100% { box-shadow: 0 0 0 9px rgba(95, 154, 90, 0); } }
.hero__tel {
  display: block;
  font-family: var(--serif); font-weight: 600;
  font-size: clamp(2.9rem, 7vw, 4.6rem);
  line-height: 1; letter-spacing: -.01em;
  color: var(--ink); text-decoration: none;
  margin-bottom: .5rem; white-space: nowrap;
}
.hero__tel:hover { color: var(--gold); }
.hero__alt { color: var(--muted); margin-bottom: .35rem; }
.hero__alt a { font-weight: 700; }
.hero__office { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin: 24px 0 0; padding-top: 24px; border-top: 1px solid var(--line); }
.hero__office dt, .footer__title { font-size: .85rem; text-transform: uppercase; letter-spacing: .1em; color: var(--gold); font-weight: 700; margin-bottom: 4px; }
.hero__office dd { margin: 0; line-height: 1.45; }

/* Fakta pod úvodem */
.facts { list-style: none; padding: 0; margin: clamp(48px, 6vw, 80px) 0 0; display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line); }
.facts li { padding: 24px 24px 0 0; display: flex; flex-direction: column; gap: 2px; }
.facts li + li { padding-left: 24px; border-left: 1px solid var(--line); }
.facts strong { font-family: var(--serif); font-size: 1.75rem; font-weight: 600; line-height: 1.1; }
.facts span { color: var(--muted); font-size: 1rem; }

/* Sekce */
.section { position: relative; padding: clamp(64px, 9vw, 112px) 0; }
.section--tint { background: var(--tint); }
.section__head { margin-bottom: 2.5rem; }
.section__head--split { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; align-items: end; }
.section__head--split .section__lead { margin: 0; }
.kicker { display: flex; align-items: center; gap: 12px; text-transform: uppercase; letter-spacing: .14em; font-size: .8rem; font-weight: 700; color: var(--gold); margin-bottom: .9rem; }
.kicker span { font-family: var(--serif); font-size: 1.05rem; letter-spacing: 0; font-variant-numeric: lining-nums; }
.kicker span::after { content: ""; display: inline-block; vertical-align: middle; width: 28px; height: 1px; margin-left: 12px; background: var(--gold-soft); }
.section__lead { color: var(--muted); font-size: 1.2rem; max-width: 52ch; margin-bottom: 2rem; }
.two-col { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(24px, 6vw, 80px); align-items: start; }
.sticky { position: sticky; top: 112px; }

/* Kroky */
.steps { list-style: none; counter-reset: krok; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 32px; }
.steps li { counter-increment: krok; position: relative; padding-top: 24px; }
.steps li::after {   /* linka, která se při scrollu „dokreslí“ */
  content: ""; position: absolute; left: 0; right: 0; top: 0; height: 1px; background: var(--gold-soft);
  transform: scaleX(var(--line-x, 1)); transform-origin: left; transition: transform 1.1s var(--ease) var(--d, 0ms);
}
.steps li::before { content: counter(krok, decimal-leading-zero); display: block; font-family: var(--serif); font-weight: 600; font-size: 3.5rem; line-height: 1; color: var(--gold-soft); margin-bottom: 14px; }
.steps h3 { margin-bottom: .5rem; }
.steps p { color: var(--muted); }

/* Karty – společný jemný hover */
.branch, .pay div, .group {
  transition: translate .5s var(--ease), box-shadow .5s var(--ease), border-color .5s var(--ease);
}
.branch:hover, .pay div:hover { translate: 0 -4px; box-shadow: var(--shadow); border-color: #dccaa8; }

/* Pobočky */
.branches { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.branch { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 28px; display: flex; flex-direction: column; }
.branch h3 { margin-bottom: .15rem; }
.branch__type { color: var(--gold); font-weight: 700; font-size: .95rem; margin-bottom: 1rem; }
.branch__links { margin-top: auto; padding-top: 12px; display: flex; flex-wrap: wrap; gap: 8px 20px; }
.branch__links a { font-weight: 700; }
.branch--wide { grid-column: 1 / -1; display: grid; grid-template-columns: 1fr 1.4fr; gap: 32px; align-items: center; }
.branch--wide:hover { translate: none; }
.branch__text { display: flex; flex-direction: column; }
.branch__photos { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.ticks { list-style: none; padding: 0; margin: 0 0 .5rem; }
.ticks li { padding-left: 20px; position: relative; margin-bottom: 4px; }
.ticks li::before { content: ""; position: absolute; left: 0; top: .75em; width: 8px; height: 1px; background: var(--gold); }

/* Fotky – pomalé přiblížení při najetí */
.photo { overflow: hidden; border-radius: 10px; background: var(--line); }
.photo img { width: 100%; height: 100%; object-fit: cover; transition: transform 1.2s var(--ease), filter 1.2s var(--ease); }
.photo:hover img { transform: scale(1.05); }
.branch__photos .photo { aspect-ratio: 4 / 3; }

/* Seznam rozloučení */
.list { list-style: none; padding: 0; margin: 0; border-top: 1px solid var(--line); }
.list li { position: relative; padding: 16px 0 16px 0; border-bottom: 1px solid var(--line); transition: padding .5s var(--ease), color .3s var(--ease); }
.list li::before { content: ""; position: absolute; left: 0; top: 50%; width: 0; height: 1px; background: var(--gold); transition: width .5s var(--ease); }
.list li:hover { padding-left: 28px; color: var(--gold); }
.list li:hover::before { width: 16px; }
.help { margin-top: 1rem; padding: 22px 24px; border-radius: var(--radius); background: var(--tint); border: 1px solid var(--line); }
.help p { color: var(--muted); margin-bottom: .4rem; }
.help a { font-family: var(--serif); font-size: 1.75rem; font-weight: 600; color: var(--ink); font-variant-numeric: lining-nums; }

/* Služby */
.groups { display: grid; grid-template-columns: repeat(4, 1fr); gap: 32px; }
.group h3 { position: relative; padding-bottom: 12px; margin-bottom: 14px; }
.group h3::after { content: ""; position: absolute; left: 0; bottom: 0; width: 100%; height: 1px; background: var(--line); }
.group h3::before { content: ""; position: absolute; left: 0; bottom: 0; width: 32px; height: 1px; background: var(--gold); z-index: 1; transition: width .7s var(--ease); }
.group:hover h3::before { width: 100%; }
.group ul { list-style: none; padding: 0; margin: 0; }
.group li { margin-bottom: 10px; color: var(--muted); line-height: 1.45; }

.florist { margin-top: clamp(56px, 7vw, 88px); display: grid; grid-template-columns: 1fr 2.6fr; gap: 40px; align-items: end; }
.florist__text p { color: var(--muted); }
.flowers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.flowers .photo { aspect-ratio: 3 / 4; }
.flowers .photo:nth-child(even) { translate: 0 24px; }

/* Platba */
.pay { margin: 0; display: grid; gap: 16px; }
.pay div { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px 26px; }
.pay dt { font-family: var(--serif); font-weight: 600; font-size: 1.55rem; }
.pay dd { margin: 0; color: var(--muted); }
.button {
  position: relative; overflow: hidden; display: inline-block; margin-top: .5rem; padding: 15px 28px; border-radius: 999px;
  background: var(--ink); color: var(--bg); text-decoration: none; font-weight: 700;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease);
}
.button::after {   /* odlesk přejede po tlačítku */
  content: ""; position: absolute; inset: 0; translate: -120% 0;
  background: linear-gradient(100deg, transparent 30%, rgba(233, 201, 131, .45), transparent 70%);
  transition: translate .9s var(--ease);
}
.button:hover { transform: translateY(-2px); box-shadow: 0 14px 30px -14px rgba(42, 37, 31, .6); }
.button:hover::after { translate: 120% 0; }

/* Závěrečná výzva */
.closing { position: relative; overflow: hidden; background: var(--tint); padding: clamp(64px, 9vw, 112px) 0; text-align: center; }
.closing::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: min(760px, 120vw); aspect-ratio: 1; translate: -50% -50%;
  background: radial-gradient(circle, var(--glow), transparent 65%); pointer-events: none;
  animation: breathe 9s ease-in-out infinite;
}
.closing__in { position: relative; }
.closing__title { font-family: var(--serif); font-size: clamp(1.8rem, 3.6vw, 2.6rem); font-weight: 500; margin-bottom: .5rem; }
.closing__tel { font-family: var(--serif); font-weight: 600; font-size: clamp(3rem, 8vw, 5.6rem); line-height: 1; color: var(--ink); text-decoration: none; white-space: nowrap; }
.closing__tel:hover { color: var(--gold); }

/* Patička */
.footer { background: var(--ink); color: #d9cfc0; padding: 64px 0 40px; font-size: 1rem; }
.footer a { color: #e8c983; }
.footer__cols { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 32px; padding-bottom: 32px; }
.footer__cols p { line-height: 1.7; }
.footer__name { font-family: var(--serif); font-size: 1.6rem; font-weight: 600; color: #fff; margin-bottom: .5rem; }
.footer__title { color: #c9a55a; }
.footer details { border-top: 1px solid rgba(255,255,255,.12); padding: 14px 0; }
.footer summary { cursor: pointer; color: #fff; }
.footer details p { margin-top: 10px; max-width: 80ch; color: #bfb4a4; }
.footer__copy { color: #9d927f; font-size: .9rem; margin-top: 16px; }

/* Objevování při scrollu (jen se zapnutým JS) */
.js [data-reveal], .js [data-reveal-group] > * {
  opacity: 0; transform: translateY(22px);
  transition: opacity 1s var(--ease) var(--d, 0ms), transform 1s var(--ease) var(--d, 0ms),
    translate .5s var(--ease), box-shadow .5s var(--ease), border-color .5s var(--ease), padding .5s var(--ease), color .3s var(--ease);
}
.js .is-in[data-reveal], .js [data-reveal-group] > .is-in { opacity: 1; transform: none; }
.js .steps li { --line-x: 0; }
.js .steps li.is-in { --line-x: 1; }
.js .photo img { transform: scale(1.08); }
.js .is-in .photo img, .js .photo.is-in img { transform: scale(1); }
.js .photo:hover img { transform: scale(1.05); }

/* Mobilní tlačítko Zavolat */
.callbar { display: none; }

@media (max-width: 960px) {
  .nav { display: none; }
  .topbar__tel { margin-left: auto; }
  .hero__in, .two-col, .section__head--split, .florist { grid-template-columns: 1fr; }
  .facts { grid-template-columns: 1fr 1fr; }
  .facts li:nth-child(3) { padding-left: 0; border-left: 0; }
  .branches { grid-template-columns: 1fr 1fr; }
  .branch--wide { grid-template-columns: 1fr; }
  .groups { grid-template-columns: 1fr 1fr; }
  .steps { grid-template-columns: 1fr; gap: 28px; }
  .sticky { position: static; }
  .footer__cols { grid-template-columns: 1fr 1fr; }
}

@media (max-width: 640px) {
  body { font-size: 1.0625rem; padding-bottom: 76px; }
  .topbar__in, .topbar.is-scrolled .topbar__in { min-height: 60px; gap: 12px; }
  .brand span { font-size: 1.15rem; }
  .brand img { width: 36px; height: 36px; }
  .topbar__tel { display: none; }
  .lead { font-size: 1.15rem; }
  .hero__office { grid-template-columns: 1fr; gap: 14px; }
  .facts li { padding: 18px 12px 0 0; }
  .facts li + li { padding-left: 12px; }
  .facts strong { font-size: 1.4rem; }
  .branches, .groups { grid-template-columns: 1fr; }
  .flowers { grid-template-columns: 1fr 1fr; }
  .flowers .photo:nth-child(even) { translate: 0 16px; }
  .footer__cols { grid-template-columns: 1fr; gap: 20px; }
  .callbar {
    display: block; position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 20;
    padding: 16px; border-radius: 999px; text-align: center;
    background: var(--ink); color: var(--bg); font-weight: 700; font-size: 1.1rem; text-decoration: none;
    box-shadow: 0 10px 30px -10px rgba(0,0,0,.45);
    transition: transform .5s var(--ease), opacity .5s var(--ease);
  }
  .callbar.is-hidden { transform: translateY(140%); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .js [data-reveal], .js [data-reveal-group] > * { opacity: 1; transform: none; }
  .js .steps li { --line-x: 1; }
  .js .photo img { transform: none; }
}
