/* Custom CSS — Kittel Consult */

/* Smooth scroll for anchor links */
html { scroll-behavior: smooth; }

/* Better text rendering */
body {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

/* Selection color */
::selection {
  background: #C9A961;
  color: #1F3A2E;
}

/* Prose styling for blog articles */
.prose {
  max-width: 65ch;
  margin-left: auto;
  margin-right: auto;
  color: #1A1A1A;
  font-size: 1.125rem;
  line-height: 1.75;
}

.prose > * + * { margin-top: 1.25em; }

.prose h2 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 2rem;
  line-height: 1.25;
  color: #1F3A2E;
  margin-top: 2.5em;
  margin-bottom: 0.6em;
  font-weight: 700;
}

.prose h3 {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.5rem;
  line-height: 1.3;
  color: #1F3A2E;
  margin-top: 2em;
  margin-bottom: 0.5em;
  font-weight: 700;
}

/* Globální zesílení serif headlines */
.font-serif {
  font-weight: 600;
}
h1.font-serif, .font-serif h1 { font-weight: 700; }
h2.font-serif, .font-serif h2 { font-weight: 700; }

.prose strong { color: #1F3A2E; font-weight: 600; }

.prose blockquote {
  border-left: 3px solid #C9A961;
  padding-left: 1.5em;
  margin: 2em 0;
  font-style: italic;
  color: #1F3A2E;
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.375rem;
  line-height: 1.5;
}

.prose ul, .prose ol {
  padding-left: 1.5em;
  margin: 1.25em 0;
}

.prose ul { list-style-type: disc; }
.prose ol { list-style-type: decimal; }
.prose li { margin: 0.5em 0; }
.prose li::marker { color: #C9A961; }

.prose a {
  color: #1F3A2E;
  text-decoration: underline;
  text-decoration-color: #C9A961;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  transition: text-decoration-color 0.2s;
}
.prose a:hover { text-decoration-color: #1F3A2E; }

.prose hr {
  border: none;
  border-top: 1px solid rgba(31, 58, 46, 0.15);
  margin: 3em auto;
  width: 60%;
}

.prose table {
  width: 100%;
  margin: 2em 0;
  border-collapse: collapse;
  font-size: 0.95rem;
}

.prose table th,
.prose table td {
  padding: 0.75em 1em;
  text-align: left;
  border-bottom: 1px solid rgba(31, 58, 46, 0.1);
}

.prose table th {
  font-family: 'Inter', sans-serif;
  font-weight: 600;
  color: #1F3A2E;
  background: rgba(201, 169, 97, 0.08);
  text-transform: uppercase;
  font-size: 0.8rem;
  letter-spacing: 0.05em;
}

/* Cite styling */
.prose cite {
  display: block;
  margin-top: 0.5em;
  font-size: 0.875rem;
  font-style: normal;
  color: #6B6B6B;
}

/* Code (rare in our content) */
.prose code {
  font-family: 'SF Mono', Menlo, monospace;
  font-size: 0.9em;
  background: rgba(31, 58, 46, 0.05);
  padding: 0.15em 0.4em;
  border-radius: 2px;
  color: #1F3A2E;
}

/* Calculator components */
.calc-input {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 1px solid rgba(31, 58, 46, 0.2);
  background: white;
  font-size: 1.125rem;
  font-family: 'Inter', sans-serif;
  color: #1A1A1A;
  transition: border-color 0.2s;
}
.calc-input:focus { outline: none; border-color: #1F3A2E; }

.calc-label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: #1F3A2E;
  margin-bottom: 0.5rem;
}

.calc-result-box {
  background: white;
  border-left: 4px solid #C9A961;
  padding: 2rem;
  margin-top: 2rem;
}

.calc-result-big {
  font-family: 'Cormorant Garamond', serif;
  font-size: 3rem;
  line-height: 1;
  color: #1F3A2E;
  font-weight: 600;
  margin: 0.5rem 0;
}

/* FAQ accordion */
details.faq summary {
  cursor: pointer;
  padding: 1.5rem 0;
  font-family: 'Cormorant Garamond', serif;
  font-size: 1.375rem;
  color: #1F3A2E;
  border-bottom: 1px solid rgba(31, 58, 46, 0.1);
  list-style: none;
  position: relative;
  padding-right: 2rem;
  font-weight: 500;
}
details.faq summary::-webkit-details-marker { display: none; }
details.faq summary::after {
  content: '+';
  position: absolute;
  right: 0;
  top: 1.5rem;
  font-size: 1.5rem;
  color: #C9A961;
  transition: transform 0.2s;
}
details.faq[open] summary::after { content: '−'; }
details.faq[open] summary { border-bottom-color: transparent; }
details.faq .faq-body {
  padding: 0 0 1.5rem;
  color: #1A1A1A;
  line-height: 1.7;
  border-bottom: 1px solid rgba(31, 58, 46, 0.1);
}

/* Print: hide nav and CTAs */
@media print {
  header, footer, .no-print { display: none !important; }
  body { color: black; background: white; }
}

/* Reduce motion for accessibility */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
}

/* Animations — subtle, premium */
@keyframes fade-up {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}
@keyframes fade-in {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes subtle-pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.02); }
}

/* Initial state — hidden until visible */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94), transform 0.7s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  will-change: opacity, transform;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Stagger children */
.reveal-stagger > * {
  opacity: 0;
  transform: translateY(15px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.reveal-stagger.visible > *:nth-child(1) { transition-delay: 0.0s; }
.reveal-stagger.visible > *:nth-child(2) { transition-delay: 0.1s; }
.reveal-stagger.visible > *:nth-child(3) { transition-delay: 0.2s; }
.reveal-stagger.visible > *:nth-child(4) { transition-delay: 0.3s; }
.reveal-stagger.visible > *:nth-child(5) { transition-delay: 0.4s; }
.reveal-stagger.visible > *:nth-child(6) { transition-delay: 0.5s; }
.reveal-stagger.visible > * {
  opacity: 1;
  transform: translateY(0);
}

/* Hero fade-in on load */
@media (prefers-reduced-motion: no-preference) {
  section:first-of-type h1 { animation: fade-up 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94) both; }
  section:first-of-type p { animation: fade-up 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.15s both; }
  section:first-of-type .flex { animation: fade-up 0.9s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.3s both; }
}

/* Hover lift on cards and articles */
article, .card-hover {
  transition: transform 0.3s ease-out, box-shadow 0.3s ease-out, border-color 0.2s;
}
@media (hover: hover) {
  article:hover, .card-hover:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 32px -8px rgba(31, 58, 46, 0.12);
  }
}

/* Subtle logo bob on hover */
header a img {
  transition: transform 0.3s ease-out;
}
header a:hover img { transform: scale(1.05); }

/* Buttons subtle scale on hover */
a.bg-forest, a.bg-champagne, button {
  transition: transform 0.2s ease-out, background-color 0.2s, color 0.2s;
}
@media (hover: hover) {
  a.bg-forest:hover, a.bg-champagne:hover {
    transform: translateY(-1px);
  }
}

/* Image kenburns on hero */
@media (prefers-reduced-motion: no-preference) {
  section:first-of-type img {
    animation: ken-burns 18s ease-out infinite alternate;
  }
}
@keyframes ken-burns {
  from { transform: scale(1); }
  to { transform: scale(1.05); }
}

/* Cookie banner */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: #1F3A2E;
  color: #F8F5F0;
  border-top: 1px solid rgba(201, 169, 97, 0.3);
  padding: 1.25rem 1.5rem;
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.15);
  transform: translateY(0);
  transition: transform 0.3s ease-out;
  font-family: 'Inter', sans-serif;
}
.cookie-banner-hidden { transform: translateY(100%); }
.cookie-banner-inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 1rem;
  align-items: flex-start;
}
@media (min-width: 768px) {
  .cookie-banner-inner {
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
  }
}
.cookie-text {
  font-size: 0.875rem;
  line-height: 1.5;
  flex: 1;
}
.cookie-text strong {
  display: block;
  color: #DDC489;
  font-weight: 600;
  margin-bottom: 0.25rem;
}
.cookie-text span { color: rgba(248, 245, 240, 0.8); }
.cookie-text a {
  color: #C9A961;
  text-decoration: underline;
  text-underline-offset: 2px;
}
.cookie-text a:hover { color: #DDC489; }
.cookie-actions { flex-shrink: 0; }
.cookie-accept {
  background: #C9A961;
  color: #1F3A2E;
  padding: 0.625rem 1.5rem;
  font-weight: 600;
  font-size: 0.875rem;
  border: none;
  cursor: pointer;
  transition: background 0.2s;
  font-family: inherit;
}
.cookie-accept:hover { background: #DDC489; }
