/*
Theme Name:     Divi Child — posty.sk
Theme URI:      https://posty.sk
Description:    Bootstrap-based design pre posty.sk. Slovenský úradný info-portal vibe.
Author:         posty.sk
Template:       Divi
Version:        2.1.0
*/

/* ===== BRAND TOKENS — editorial news vibe (postal red + slate) ===== */
:root {
  /* "Navy" — teraz vlastne dark slate */
  --posty-navy: #1f2937;
  --posty-navy-dark: #0f1419;
  --posty-navy-light: #374151;

  /* "Amber" → silnejšia postal red ako primary accent */
  --posty-amber: #dc2626;
  --posty-amber-dark: #991b1b;

  /* Bg — biela namiesto béžovej */
  --posty-paper: #ffffff;
  --posty-paper-dark: #f9fafb;
  --posty-text: #1a1a1a;
  --posty-text-muted: #6b7280;
  --posty-border: #e5e7eb;

  --posty-open: #16a34a;
  --posty-open-bg: #f0fdf4;
  --posty-closed: #dc2626;
  --posty-closed-bg: #fef2f2;
}

/* ===== TYPOGRAFIE ===== */
body {
  font-family: 'Source Sans 3', 'Source Sans Pro', -apple-system, system-ui, sans-serif !important;
  font-size: 17px;
  line-height: 1.65;
  color: var(--posty-text);
  background: var(--posty-paper);
}
h1, h2, h3, h4, h5, h6, .posty-serif {
  font-family: 'Source Serif 4', 'Source Serif Pro', Georgia, serif !important;
  font-weight: 700;
  letter-spacing: -0.01em;
  color: var(--posty-navy);
}
.posty-serif-italic {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
}

/* Tabulárne čísla pre časy a vzdialenosti */
.posty-tabular { font-variant-numeric: tabular-nums; }

/* ===== HEADER ===== */
body.posty-page #page-container,
body.posty-page #main-header,
body.posty-page #top-header,
body.posty-page #main-footer,
body.posty-page #footer-bottom,
body.posty-page #footer-widgets,
body.posty-page #et-main-area,
body.posty-page .et_pb_section { display: none !important; }

.posty-navbar {
  background: white;
  border-bottom: 1px solid var(--posty-border);
  border-top: 4px solid var(--posty-amber);  /* postal red top */
  padding: 0;
  position: sticky; top: 0; z-index: 1030;
}
.posty-navbar .navbar-brand {
  font-family: 'Source Serif 4', Georgia, serif;
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--posty-navy);
  letter-spacing: -0.02em;
  display: flex; align-items: center; gap: 8px;
}
.posty-navbar .navbar-brand:hover { color: var(--posty-navy-dark); }
.posty-navbar .navbar-brand-mark {
  width: 32px; height: 32px;
  background: var(--posty-amber);  /* postal red */
  color: white;
  border-radius: 4px;
  display: inline-flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 16px;
  letter-spacing: 0;
  font-family: 'Source Sans 3', sans-serif;
}
.posty-navbar .navbar-brand small {
  color: var(--posty-text-muted);
  font-weight: 400;
  font-size: 1rem;
  font-family: 'Source Sans 3', sans-serif;
}
.posty-navbar .nav-link {
  color: var(--posty-text) !important;
  font-weight: 500;
  font-size: 15px;
  padding: 0.6rem 0.9rem !important;
  border-bottom: 2px solid transparent;
}
.posty-navbar .nav-link:hover {
  color: var(--posty-navy) !important;
  border-bottom-color: var(--posty-amber);
}
.posty-navbar .nav-link.active {
  color: var(--posty-navy) !important;
  border-bottom-color: var(--posty-navy);
}

/* ===== BREADCRUMBS ===== */
.posty-breadcrumb-bar {
  background: var(--posty-paper-dark);
  border-bottom: 1px solid var(--posty-border);
  padding: 0.65rem 0;
  font-size: 14px;
}
.posty-breadcrumb-bar a { color: var(--posty-text-muted); text-decoration: none; }
.posty-breadcrumb-bar a:hover { color: var(--posty-navy); text-decoration: underline; }
.posty-breadcrumb-bar .sep { color: var(--posty-border); margin: 0 0.5rem; }

/* ===== HERO ===== */
.posty-hero {
  background: white;
  border: 1px solid var(--posty-border);
  border-left: 4px solid var(--posty-amber);  /* postal red left bar */
  padding: 2rem 2.25rem;
  margin: 1.5rem 0;
  position: relative;
}
.posty-hero h1 {
  font-size: 2.25rem;
  margin-bottom: 0.75rem;
  line-height: 1.15;
}
@media (min-width: 768px) {
  .posty-hero h1 { font-size: 2.75rem; }
}
.posty-hero .posty-meta {
  font-family: 'Source Sans 3', sans-serif;
  font-size: 13px;
  color: var(--posty-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 600;
  margin-bottom: 0.5rem;
}
.posty-hero .posty-h1-prefix {
  font-weight: 400;
  color: var(--posty-text-muted);
}
.posty-hero .posty-lead {
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
  font-size: 1.05rem;
  color: var(--posty-text-muted);
  margin: 1rem 0 0;
  max-width: 60ch;
  line-height: 1.7;
}
.posty-hero .posty-lead a { color: var(--posty-navy); font-style: normal; }

/* Razítko — drobné, do rohu, retro */
.posty-stamp {
  position: absolute;
  top: 1.5rem; right: 1.75rem;
  color: var(--posty-amber-dark);
  opacity: 0.45;
  transform: rotate(-9deg);
  pointer-events: none;
}
/* Na mobilu razítko schované — zbytočne tlačí meta řádek */
@media (max-width: 575.98px) {
  .posty-stamp { display: none; }
}

/* ===== STATUS BADGES ===== */
.posty-status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.4rem 0.85rem;
  font-size: 0.9rem;
  font-weight: 500;
  border: 1px solid;
  border-radius: 3px;
  font-variant-numeric: tabular-nums;
  font-family: 'Source Sans 3', sans-serif;
}
.posty-status--open {
  background: var(--posty-open-bg);
  color: var(--posty-open);
  border-color: rgba(90, 140, 90, 0.3);
}
.posty-status--closed {
  background: var(--posty-closed-bg);
  color: var(--posty-closed);
  border-color: rgba(168, 56, 56, 0.3);
}

/* ===== KARTY ===== */
.posty-card {
  background: white;
  border: 1px solid var(--posty-border);
  margin-bottom: 1.25rem;
  padding: 1.5rem 1.75rem;
  border-radius: 4px;
}
.posty-card h2 {
  font-size: 1.4rem;
  margin: 0 0 1rem;
  padding-bottom: 0.65rem;
  border-bottom: 1px solid var(--posty-border);
  display: flex; align-items: center; gap: 0.5rem;
}
.posty-card h2 svg.posty-icon {
  color: var(--posty-amber-dark);
  flex-shrink: 0;
}

/* ===== ADRESA ===== */
.posty-contact {
  margin: 0;
  font-size: 1rem;
}
.posty-contact dt {
  color: var(--posty-text-muted);
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.15rem;
}
.posty-contact dd {
  color: var(--posty-text);
  margin: 0 0 0.85rem;
  font-size: 1.05rem;
}
.posty-contact dd a { color: var(--posty-navy); }
.posty-contact dd a:hover { color: var(--posty-navy-dark); }

/* ===== HODINY ===== */
.posty-hours {
  width: 100%;
  border-collapse: collapse;
  font-size: 1rem;
  margin-bottom: 1rem;
  font-variant-numeric: tabular-nums;
}
.posty-hours th, .posty-hours td {
  padding: 0.6rem 0.85rem;
  text-align: left;
  border-bottom: 1px solid var(--posty-paper-dark);
}
.posty-hours thead th {
  font-family: 'Source Sans 3', sans-serif;
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--posty-text-muted);
  background: var(--posty-paper-dark);
  border-bottom: 2px solid var(--posty-navy);
  padding: 0.5rem 0.85rem;
}
.posty-hours tr:last-child td { border-bottom: none; }
.posty-hours .posty-day {
  font-weight: 600;
  color: var(--posty-navy);
  font-family: 'Source Serif 4', Georgia, serif;
}
.posty-hours .posty-today {
  background: var(--posty-open-bg);
}
.posty-hours .posty-today td:first-child {
  border-left: 3px solid var(--posty-open);
  padding-left: 0.65rem;
}
.posty-hours .posty-today .posty-day { color: var(--posty-navy-dark); }
.posty-closed-text {
  color: var(--posty-text-muted);
  font-style: italic;
  font-size: 0.95rem;
}
.posty-hours-note {
  font-size: 0.85rem;
  color: var(--posty-text-muted);
  margin: 0;
  font-family: 'Source Serif 4', Georgia, serif;
  font-style: italic;
}
.posty-map-note {
  font-size: 0.9rem;
  color: var(--posty-text-muted);
  margin: 0.75rem 0 0;
}
.posty-map-note a { color: var(--posty-navy); }

/* ===== SIDEBAR ===== */
.posty-sidebar { padding-left: 0.5rem; }
.posty-sidebar-card {
  background: white;
  border: 1px solid var(--posty-border);
  padding: 1.25rem 1.4rem;
  margin-bottom: 1.25rem;
  border-radius: 4px;
}
.posty-sidebar-card h3 {
  font-family: 'Source Sans 3', sans-serif;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--posty-navy);
  margin: 0 0 0.85rem;
  padding-bottom: 0.55rem;
  border-bottom: 1px solid var(--posty-border);
}

.posty-nearby { list-style: none; padding: 0; margin: 0; }
.posty-nearby li {
  padding: 0.55rem 0;
  border-bottom: 1px dotted var(--posty-border);
}
.posty-nearby li:last-child { border: none; padding-bottom: 0; }
.posty-nearby li:first-child { padding-top: 0; }
.posty-nearby a {
  color: var(--posty-text);
  font-size: 0.95rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  text-decoration: none;
  font-family: 'Source Serif 4', Georgia, serif;
}
.posty-nearby a:hover { color: var(--posty-navy); text-decoration: underline; }
.posty-distance {
  color: var(--posty-text-muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  font-family: 'Source Sans 3', sans-serif;
  flex-shrink: 0;
  margin-left: 0.5rem;
}
.posty-kraj-note {
  font-size: 0.95rem;
  color: var(--posty-text);
  line-height: 1.6;
  margin: 0;
}
.posty-kraj-note a { color: var(--posty-navy); }

/* ===== AD SLOTS ===== */
.posty-ad-slot {
  background: transparent;
  padding: 0.5rem;
  margin: 1rem 0;
  min-height: 90px;
  text-align: center;
  font-size: 11px;
  color: var(--posty-text-muted);
}
.posty-ad-slot ins { display: block !important; }

/* ===== FOOTER ===== */
.posty-footer {
  background: #0f1419;  /* near-black, no blue tint */
  color: rgba(255,255,255,0.85);
  margin-top: 4rem;
  padding: 2.5rem 0 1.25rem;
  font-size: 0.9rem;
  border-top: 4px solid var(--posty-amber);  /* postal red top */
}
.posty-footer .posty-disclaimer {
  background: rgba(255,255,255,0.04);
  border-left: 3px solid var(--posty-amber);
  padding: 0.85rem 1.15rem;
  margin-bottom: 1.5rem;
  border-radius: 3px;
  line-height: 1.7;
}
.posty-footer .posty-disclaimer strong { color: white; }
.posty-footer .posty-disclaimer a { color: var(--posty-amber); text-decoration: none; }
.posty-footer .posty-disclaimer a:hover { text-decoration: underline; }
.posty-footer .posty-copyright {
  font-size: 0.82rem;
  color: rgba(255,255,255,0.5);
  text-align: center;
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 1.25rem;
}
.posty-footer .posty-copyright a {
  color: rgba(255,255,255,0.7);
  text-decoration: none;
}
.posty-footer .posty-copyright a:hover { color: var(--posty-amber); }

/* ===== BOOTSTRAP OVERRIDES (= naše vibe) ===== */
.btn-posty {
  background: var(--posty-amber);  /* postal red as primary CTA */
  color: white;
  border: none;
  padding: 0.55rem 1.2rem;
  font-weight: 500;
  border-radius: 3px;
}
.btn-posty:hover { background: var(--posty-amber-dark); color: white; }

.posty-section-title {
  font-size: 1.65rem;
  margin: 2rem 0 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 2px solid var(--posty-navy);
  display: inline-block;
}

/* ===== MOBILE OVERRIDES — utáhnout layout, víc obsahu, míň bílého místa ===== */
@media (max-width: 575.98px) {
  /* Container těsnější po stranách */
  .container,
  main.container {
    padding-left: 12px;
    padding-right: 12px;
  }

  /* Breadcrumby — menší, zalomitelné */
  .posty-breadcrumb-bar { font-size: 13px; padding: 0.5rem 0; }
  .posty-breadcrumb-bar .container { line-height: 1.5; word-break: break-word; }
  .posty-breadcrumb-bar .sep { margin: 0 0.35rem; }

  /* HERO — výrazne méně paddingu, vejde se do něj víc */
  .posty-hero {
    padding: 1.1rem 1rem;
    margin: 0.85rem 0;
    border-left-width: 3px;
  }
  .posty-hero h1 {
    font-size: 1.7rem;
    line-height: 1.2;
    margin-bottom: 0.6rem;
    word-break: break-word;
  }
  .posty-hero .posty-h1-prefix { display: inline; }
  .posty-hero .posty-meta {
    font-size: 11px;
    letter-spacing: 0.06em;
    line-height: 1.4;
  }
  .posty-hero .posty-lead {
    font-size: 0.97rem;
    line-height: 1.55;
    margin-top: 0.75rem;
  }

  /* Status badge — ať se vejde do jednoho řádku */
  .posty-status {
    font-size: 0.82rem;
    padding: 0.3rem 0.65rem;
    line-height: 1.3;
  }

  /* Akční tlačítka pod hero — menší, kompaktnější */
  .posty-actions { gap: 0.4rem !important; margin-top: 0.85rem !important; }
  .posty-actions .btn { font-size: 0.82rem; padding: 0.32rem 0.6rem; }

  /* KARTY — výrazne méně paddingu */
  .posty-card {
    padding: 1rem 0.95rem;
    margin-bottom: 0.85rem;
  }
  .posty-card h2 {
    font-size: 1.18rem;
    margin-bottom: 0.75rem;
    padding-bottom: 0.5rem;
    gap: 0.4rem;
  }
  .posty-card h2 svg.posty-icon { width: 18px; height: 18px; }

  /* Adresa — bloky pod sebe */
  .posty-contact dt { font-size: 0.78rem; }
  .posty-contact dd { font-size: 1rem; margin-bottom: 0.7rem; }

  /* Tabulka hodin — mnohem těsnější buňky */
  .posty-hours { font-size: 0.95rem; }
  .posty-hours th, .posty-hours td {
    padding: 0.5rem 0.45rem;
  }
  .posty-hours thead th { font-size: 0.7rem; padding: 0.45rem 0.45rem; }
  .posty-hours .posty-day { font-size: 0.95rem; }
  .posty-hours .posty-today td:first-child { padding-left: 0.35rem; border-left-width: 3px; }
  .posty-closed-text { font-size: 0.88rem; }
  .posty-hours-note { font-size: 0.8rem; line-height: 1.5; }

  /* Mapa — menší výška, ať padne do obrazovky */
  .posty-card iframe { height: 240px !important; }
  .posty-map-note { font-size: 0.85rem; line-height: 1.55; }

  /* Sidebar (pod hlavním obsahem na mobilu) — bez levého odsazení, tenčí padding */
  .posty-sidebar { padding-left: 0; padding-right: 0; }
  .posty-sidebar-card {
    padding: 0.95rem 0.95rem;
    margin-bottom: 0.85rem;
  }
  .posty-sidebar-card h3 { font-size: 0.74rem; margin-bottom: 0.7rem; }

  /* FAQ — menší mezery */
  .posty-faq dt { font-size: 0.98rem; margin-top: 0.7rem !important; }
  .posty-faq dd { font-size: 0.93rem; line-height: 1.55; }

  /* Bottom mobile nav — kompaktnější, ať méně ukrajuje výšku */
  .posty-bottom-nav { padding: 0.3rem 0 !important; }
  .posty-bottom-nav a, .posty-bottom-nav button { font-size: 0.66rem !important; padding: 0.2rem !important; }
  .posty-bottom-nav svg { width: 20px !important; height: 20px !important; }
}

/* Tablet (576-767) — mírnější utažení */
@media (min-width: 576px) and (max-width: 767.98px) {
  .posty-hero { padding: 1.5rem 1.4rem; }
  .posty-card { padding: 1.25rem 1.25rem; }
  .posty-sidebar-card { padding: 1.1rem 1.2rem; }
}
