:root {
  --primary-color: #006699;
  --primary-hover: #0088cc;
  --text-light: #ffffff;
  --text-muted: rgba(255, 255, 255, 0.8);
  --glass-bg: rgba(7, 51, 78, 0.74);
  --glass-bg-strong: rgba(5, 34, 54, 0.82);
  --glass-border: rgba(255, 255, 255, 0.22);
  --glass-border-hover: rgba(255, 255, 255, 0.55);
  --deep-blue: #07334e;
  --accent-yellow: #ffcc00;
  --focus-ring: #7cd4ff;
  --shadow-soft: 0 12px 32px rgba(0, 0, 0, 0.36);
  --shadow-hover: 0 18px 42px rgba(0, 0, 0, 0.52);
  --radius-lg: 20px;
  --radius-full: 9999px;
  --content-max: 1360px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  color: var(--text-light);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
  position: relative;
  background-color: #041521;
}

html[lang^="zh"] body {
  font-family: "PingFang SC", "PingFang TC", "Hiragino Sans GB", "Microsoft YaHei", "Microsoft JhengHei", "Source Han Sans SC", "Source Han Sans TC", "Noto Sans CJK SC", "Noto Sans CJK TC", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
}

html[dir="rtl"] body {
  font-family: "Vazirmatn", "Segoe UI", "Tahoma", "Noto Sans Arabic", "Geeza Pro", system-ui, -apple-system, BlinkMacSystemFont, "Arial", sans-serif;
  line-height: 1.7;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    linear-gradient(to bottom, rgba(4, 21, 33, 0.68) 0%, rgba(4, 21, 33, 0.38) 40%, rgba(4, 21, 33, 0.72) 100%),
    url('../GorskiSvet/Slika_Ozadje2.jpg') no-repeat center center / cover;
  z-index: -1;
  pointer-events: none;
}

:focus-visible {
  outline: 2px solid var(--focus-ring);
  outline-offset: 3px;
}

/* ===============================
   JEZIKOVNI PREKLOPNIK IN PREKLOPNIK PISAVE
=============================== */
.top-controls {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 10002;
  display: flex;
  align-items: center;
  gap: 8px;
  direction: ltr;
}

.lang-switcher {
  position: fixed;
  top: 20px;
  left: 20px;
  z-index: 10002;
  direction: ltr;
}

.top-controls .lang-switcher {
  position: relative;
  top: auto;
  left: auto;
  z-index: auto;
}

.lang-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 44px;
  padding: 0 14px;
  border-radius: var(--radius-full);
  background: rgba(7, 51, 78, 0.86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  color: var(--text-light);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.32);
  transition: background 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease;
}

.lang-trigger:hover,
.lang-switcher.open .lang-trigger {
  background: rgba(0, 102, 153, 0.94);
  border-color: rgba(255, 255, 255, 0.58);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.42);
}

.lang-trigger svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.lang-trigger .lang-chevron {
  width: 13px;
  height: 13px;
  opacity: 0.85;
  transition: transform 0.25s ease;
}

.lang-switcher.open .lang-chevron {
  transform: rotate(180deg);
}

.script-switcher {
  display: inline-flex;
  align-items: center;
  height: 44px;
  padding: 4px;
  gap: 3px;
  border-radius: var(--radius-full);
  background: rgba(7, 51, 78, 0.86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.28);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.32);
}

.script-btn {
  height: 100%;
  padding: 0 11px;
  border: none;
  border-radius: var(--radius-full);
  background: transparent;
  color: rgba(255, 255, 255, 0.88);
  font-family: inherit;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}

.script-btn:hover {
  background: rgba(255, 255, 255, 0.14);
  color: var(--text-light);
}

.script-btn.active {
  background: var(--accent-yellow);
  color: #052033;
  font-weight: 800;
}

.lang-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: min(600px, calc(100vw - 30px));
  max-height: calc(100vh - 95px);
  overflow-y: auto;
  padding: 10px;
  border-radius: 18px;
  background: rgba(5, 31, 49, 0.96);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.22);
  box-shadow: 0 18px 44px rgba(0, 0, 0, 0.55);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(-8px) scale(0.98);
  transform-origin: top left;
  transition: opacity 0.22s ease, transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.22s ease;
  pointer-events: none;
  direction: ltr;
}

.lang-switcher.open .lang-menu {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
  pointer-events: auto;
}

.lang-option {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: 11px;
  text-decoration: none;
  color: rgba(255, 255, 255, 0.9);
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  font-size: 0.82rem;
  font-weight: 500;
  border: 1px solid transparent;
  background: rgba(255, 255, 255, 0.03);
  transition: background 0.18s ease, border-color 0.18s ease, transform 0.18s ease;
  white-space: nowrap;
  overflow: hidden;
}

.lang-option:hover,
.lang-option:focus-visible {
  background: rgba(255, 255, 255, 0.14);
  border-color: rgba(255, 255, 255, 0.28);
  color: var(--text-light);
  transform: translateX(2px);
}

.lang-option.active {
  background: rgba(255, 204, 0, 0.14);
  border-color: rgba(255, 204, 0, 0.55);
  color: var(--text-light);
  font-weight: 700;
}

.lang-code {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 40px;
  padding: 2px 5px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.12);
  color: var(--focus-ring);
  font-size: 0.67rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.lang-option.active .lang-code {
  background: var(--accent-yellow);
  color: #052033;
}

.lang-name {
  overflow: hidden;
  text-overflow: ellipsis;
}

.main-wrapper {
  flex: 1;
  padding-bottom: 2.5rem;
  width: 100%;
}

/* ===============================
   GLAVA
=============================== */
.responsive-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: clamp(2.2rem, 4.5vw, 3.6rem) 1rem 1.2rem;
  gap: 1rem;
}

.header-content {
  text-align: center;
  max-width: 840px;
  width: 100%;
  padding: 0 0.5rem;
}

.header-content h1 {
  font-size: clamp(2.1rem, 5vw, 3.35rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-light);
  text-shadow: 0 4px 18px rgba(0, 0, 0, 0.55);
  margin-bottom: 0.25rem;
  line-height: 1.15;
}

.header-subtitle {
  font-size: clamp(0.95rem, 2.2vw, 1.25rem);
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.88);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.55);
  margin-bottom: 0.85rem;
}

.header-lead {
  font-size: clamp(0.98rem, 1.9vw, 1.14rem);
  color: rgba(255, 255, 255, 0.94);
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.65);
}

.archive-stats {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.45rem 1.1rem;
  margin-top: 0.65rem;
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(220, 238, 252, 0.88);
  letter-spacing: 0.02em;
}

html[dir="rtl"] .archive-stats {
  font-size: 0.85rem;
  letter-spacing: 0;
}

.archive-stats span {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
}

.archive-stats span::before {
  content: "";
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--accent-yellow);
  opacity: 0.9;
}

/* Logo kranjske čebele */
.tooltip-container {
  position: relative;
  display: inline-block;
  cursor: pointer;
  touch-action: manipulation;
  background: none;
  border: none;
  padding: 4px;
  border-radius: 18px;
}

.header-logo {
  width: clamp(115px, 16vw, 155px);
  max-width: 100%;
  height: auto;
  display: block;
  filter: drop-shadow(0 10px 20px rgba(0, 0, 0, 0.55))
          drop-shadow(0 0 18px rgba(255, 204, 0, 0.18));
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), filter 0.35s ease;
}

.tooltip-container:hover .header-logo,
.tooltip-container:focus-visible .header-logo {
  transform: translateY(-4px) rotate(-2deg) scale(1.05);
  filter: drop-shadow(0 14px 26px rgba(0, 0, 0, 0.6))
          drop-shadow(0 0 26px rgba(255, 204, 0, 0.36));
}

.tooltip-text {
  position: absolute;
  top: calc(100% + 12px);
  left: 50%;
  transform: translateX(-50%);
  background: rgba(5, 29, 46, 0.97);
  color: var(--text-light);
  padding: 0.85rem;
  border-radius: 16px;
  width: min(265px, 84vw);
  font-size: 0.82rem;
  line-height: 1.5;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.22s ease, transform 0.22s cubic-bezier(0.16, 1, 0.3, 1), visibility 0.22s ease;
  z-index: 1000;
  box-shadow: 0 18px 42px rgba(0, 0, 0, 0.6);
  border: 1px solid var(--glass-border);
  text-align: start;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  pointer-events: none;
}

html[dir="rtl"] .tooltip-text {
  font-size: 0.85rem;
  line-height: 1.65;
}

.tooltip-art {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 10px;
  margin-bottom: 0.65rem;
  border: 1px solid rgba(255, 255, 255, 0.16);
}

.tooltip-credit {
  display: block;
  margin-top: 0.45rem;
  font-size: 0.76rem;
  color: var(--accent-yellow);
  font-weight: 600;
}

.tooltip-container:hover .tooltip-text {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(4px);
  transition-delay: 0.15s;
}

.tooltip-container:focus-visible .tooltip-text,
.tooltip-container.active .tooltip-text {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(4px);
  transition-delay: 0s;
}

/* ===============================
   ISKALNIK
=============================== */
.local-search-container {
  margin: 1.35rem auto 0;
  position: relative;
  max-width: 560px;
  width: 100%;
  z-index: 100;
}

.search-box {
  display: flex;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.6);
  border-radius: var(--radius-full);
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.34);
  transition: background 0.25s ease, box-shadow 0.25s ease;
}

.search-box:focus-within {
  background: #ffffff;
  box-shadow: 0 0 0 3px rgba(102, 199, 255, 0.45), 0 14px 36px rgba(0, 0, 0, 0.45);
}

#localSearchInput {
  padding: 13px 20px;
  border: none;
  flex-grow: 1;
  background: transparent;
  color: #0e1e2b;
  outline: none;
  font-family: inherit;
  font-size: 0.95rem;
  width: 100%;
  text-align: start;
}

#localSearchInput::placeholder {
  color: #556575;
}

.search-btn-icon {
  padding: 0 20px;
  border: none;
  background: var(--primary-color);
  color: var(--text-light);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
  transition: background 0.2s ease;
}

.search-btn-icon:hover,
.search-btn-icon:focus-visible {
  background: var(--primary-hover);
}

.search-btn-icon svg {
  width: 19px;
  height: 19px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.suggestions-box {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  right: 0;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  color: #222222;
  border-radius: 16px;
  box-shadow: 0 20px 44px rgba(0, 0, 0, 0.48);
  max-height: 360px;
  overflow-y: auto;
  display: none;
  z-index: 1000;
  border: 1px solid rgba(255, 255, 255, 0.65);
  text-align: start;
}

.suggestion-item {
  padding: 12px 16px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.07);
  transition: background 0.18s ease;
}

.suggestion-item:last-child {
  border-bottom: none;
}

.suggestion-item:hover,
.suggestion-item.is-active {
  background: rgba(0, 102, 153, 0.12);
}

.suggestion-item a {
  text-decoration: none;
  color: inherit;
  display: block;
}

.suggestion-title {
  display: block;
  margin: 0;
  font-size: 0.95rem;
  color: var(--primary-color);
  font-weight: 700;
}

.suggestion-item p {
  margin: 4px 0 0;
  font-size: 0.83rem;
  color: #3a4a58;
  line-height: 1.4;
}

.suggestion-status,
.suggestion-meta {
  padding: 12px 16px;
  font-size: 0.84rem;
  color: #4a5b6a;
}

.suggestion-meta {
  background: rgba(7, 51, 78, 0.05);
  border-top: 1px solid rgba(0, 0, 0, 0.07);
  font-size: 0.78rem;
  font-weight: 600;
  text-align: center;
}

/* ===============================
   HITRE POVEZAVE
=============================== */
.link-container {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.65rem;
  margin: 1rem auto 2.2rem;
  padding: 0 1rem;
  max-width: 960px;
}

.btn {
  background: var(--glass-bg-strong);
  color: var(--text-light);
  padding: 0.66rem 1.3rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  text-decoration: none;
  transition: background 0.25s ease, color 0.25s ease, border-color 0.25s ease, transform 0.25s ease, box-shadow 0.25s ease;
  border: 1px solid rgba(255, 255, 255, 0.28);
  font-size: 0.82rem;
  text-transform: uppercase;
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  letter-spacing: 0.05em;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 7px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.24);
}

html[lang^="zh"] .btn,
html[lang^="ko"] body {
  font-family: "Apple SD Gothic Neo", "Malgun Gothic", "Noto Sans KR", "Nanum Gothic", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
  word-break: keep-all;
}
html[lang^="ja"] body {
  font-family: "Hiragino Sans", "Hiragino Kaku Gothic ProN", "Yu Gothic UI", "Yu Gothic", "Meiryo", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  line-height: 1.6;
}
html[dir="rtl"] .btn {
  font-size: 0.86rem;
  text-transform: none;
  letter-spacing: 0;
}

.btn svg {
  width: 15px;
  height: 15px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}

.btn:hover,
.btn:focus-visible {
  background: #ffffff;
  color: var(--deep-blue);
  border-color: #ffffff;
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.35);
}

.btn-highlight {
  background: var(--accent-yellow);
  border-color: var(--accent-yellow);
  color: #062538;
  font-weight: 800;
}

.btn-highlight:hover,
.btn-highlight:focus-visible {
  background: #ffe052;
  color: #041521;
  border-color: #ffe052;
  box-shadow: 0 10px 26px rgba(255, 204, 0, 0.35);
}

/* ===============================
   GLAVNA VSEBINA IN KUPOLA
=============================== */
.catalog-main {
  width: 100%;
  max-width: var(--content-max);
  margin: 0 auto;
  padding: 0 clamp(1rem, 3vw, 2.25rem);
  display: flex;
  flex-direction: column;
  gap: 2.8rem;
}

.dome-card {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  border-radius: 50% 50% var(--radius-lg) var(--radius-lg) / 72% 72% var(--radius-lg) var(--radius-lg);
  overflow: hidden;
  border: 1px solid var(--glass-border);
  box-shadow: var(--shadow-soft);
  background: var(--deep-blue);
  transition: transform 0.32s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.32s ease, border-color 0.32s ease;
}

.dome-card:hover,
.dome-card:focus-within {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--glass-border-hover);
}

.dome-viewport {
  position: relative;
  height: 340px;
  width: 100%;
  overflow: hidden;
  background-color: #072235;
  direction: ltr;
}

.dome-track {
  display: flex;
  height: 100%;
  width: max-content;
  will-change: transform;
  animation: panoramaScroll 75s linear infinite;
}

.dome-card:hover .dome-track,
.dome-card:focus-within .dome-track {
  animation-play-state: paused;
}

.dome-track-img {
  height: 100%;
  width: auto;
  max-width: none;
  flex-shrink: 0;
  display: block;
  user-select: none;
  pointer-events: none;
}

@keyframes panoramaScroll {
  0% { transform: translate3d(0, 0, 0); }
  100% { transform: translate3d(-33.333333%, 0, 0); }
}

@media (prefers-reduced-motion: reduce) {
  .dome-track {
    animation: none;
  }

  .header-logo,
  .tooltip-container:hover .header-logo,
  .tooltip-container:focus-visible .header-logo {
    transition: none;
    transform: none;
  }
}

.dome-overlay {
  background: linear-gradient(to right, rgba(5, 34, 54, 0.94), rgba(7, 51, 78, 0.88));
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-top: 1px solid rgba(255, 255, 255, 0.16);
  padding: 1.05rem 1.5rem;
  transition: background 0.3s ease;
}

.dome-card:hover .dome-overlay {
  background: linear-gradient(to right, rgba(0, 82, 125, 0.95), rgba(0, 102, 153, 0.9));
}

html[dir="rtl"] .dome-overlay {
  background: linear-gradient(to left, rgba(5, 34, 54, 0.94), rgba(7, 51, 78, 0.88));
}

html[dir="rtl"] .dome-card:hover .dome-overlay {
  background: linear-gradient(to left, rgba(0, 82, 125, 0.95), rgba(0, 102, 153, 0.9));
}

/* ===============================
   TEMATSKE SEKCIJE IN KARTICE
=============================== */
.catalog-section {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
}

.section-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 0.4rem 1rem;
  padding: 0 0.2rem 0.6rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.18);
}

.section-header h2 {
  font-size: clamp(1.12rem, 2.1vw, 1.38rem);
  font-weight: 700;
  color: var(--text-light);
  letter-spacing: 0.01em;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
}

html[dir="rtl"] .section-header h2 {
  letter-spacing: 0;
}

.chapters-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.35rem;
  width: 100%;
}

.chapters-grid.grid-2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.chapter {
  position: relative;
  border-radius: var(--radius-lg);
  height: 280px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.3s ease, border-color 0.3s ease;
  border: 1px solid var(--glass-border);
  overflow: hidden;
  box-shadow: var(--shadow-soft);
  text-align: start;
  background-color: #072235;
}

.chapters-grid.grid-2 .chapter {
  height: 300px;
}

.chapter:not(.chapter-multi):hover,
.chapter:not(.chapter-multi):focus-within {
  transform: translateY(-4px);
  box-shadow: var(--shadow-hover);
  border-color: var(--glass-border-hover);
}

.chapter.chapter-multi:hover,
.chapter.chapter-multi:focus-within {
  border-color: rgba(255, 255, 255, 0.42);
}

.chapter.card-featured {
  border: 1.5px solid rgba(255, 204, 0, 0.65);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.4), 0 0 22px rgba(255, 204, 0, 0.16);
}

.chapter.card-featured:hover,
.chapter.card-featured:focus-within {
  border-color: var(--accent-yellow);
  box-shadow: 0 16px 38px rgba(0, 0, 0, 0.5), 0 0 28px rgba(255, 204, 0, 0.28);
}

.badge-corner {
  position: absolute;
  top: 14px;
  inset-inline-end: 14px;
  z-index: 5;
  background: var(--accent-yellow);
  color: #052033;
  font-weight: 800;
  font-size: 0.72rem;
  padding: 4px 11px;
  border-radius: var(--radius-full);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.35);
  pointer-events: none;
}

html[dir="rtl"] .badge-corner {
  font-size: 0.76rem;
  text-transform: none;
  letter-spacing: 0;
  padding: 4px 12px;
}

.chapter-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.65s cubic-bezier(0.16, 1, 0.3, 1);
  z-index: 1;
  display: block;
}

.chapter:not(.chapter-multi):hover .chapter-bg,
.chapter:not(.chapter-multi):focus-within .chapter-bg {
  transform: scale(1.06);
}

.chapter-overlay {
  position: relative;
  z-index: 2;
  background: linear-gradient(
    to top,
    rgba(4, 22, 36, 0.95) 0%,
    rgba(6, 39, 61, 0.78) 58%,
    rgba(7, 51, 78, 0) 100%
  );
  padding: 2.5rem 1.25rem 1.1rem;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  transition: background 0.3s ease;
}

.chapter:not(.chapter-multi):hover .chapter-overlay {
  background: linear-gradient(
    to top,
    rgba(0, 62, 96, 0.96) 0%,
    rgba(0, 88, 134, 0.8) 62%,
    rgba(0, 102, 153, 0) 100%
  );
}

.chapter-link,
.dome-link {
  color: var(--text-light);
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  gap: 0.85rem;
}

.chapter-link::after,
.dome-link::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
}

.dome-title,
.chapter-title,
.water-header {
  color: var(--text-light);
  font-size: clamp(1.02rem, 1.9vw, 1.15rem);
  font-weight: 700;
  line-height: 1.3;
  margin: 0;
}

.card-desc {
  display: block;
  font-size: 0.8rem;
  font-weight: 400;
  color: rgba(226, 241, 255, 0.84);
  margin-top: 3px;
}

html[dir="rtl"] .card-desc {
  font-size: 0.82rem;
}

.arrow-icon {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.25);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text-light);
  transition: transform 0.28s ease, background 0.28s ease, border-color 0.28s ease, color 0.28s ease;
}

.arrow-icon svg {
  width: 16px;
  height: 16px;
  stroke: currentColor;
  fill: none;
  stroke-width: 2.3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chapter:not(.chapter-multi):hover .arrow-icon,
.chapter:not(.chapter-multi):focus-within .arrow-icon,
.dome-card:hover .arrow-icon,
.dome-card:focus-within .arrow-icon {
  transform: translateX(4px);
  background: #ffffff;
  border-color: #ffffff;
  color: var(--deep-blue);
}

html[dir="rtl"] .chapter:not(.chapter-multi):hover .arrow-icon,
html[dir="rtl"] .chapter:not(.chapter-multi):focus-within .arrow-icon,
html[dir="rtl"] .dome-card:hover .arrow-icon,
html[dir="rtl"] .dome-card:focus-within .arrow-icon {
  transform: translateX(-4px);
}

/* Kartica Vode Slovenije */
.water-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.25rem;
  position: relative;
  z-index: 4;
}

.water-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 0.45rem 0.95rem;
  border-radius: var(--radius-full);
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.38);
  color: var(--text-light);
  text-decoration: none;
  font-size: 0.84rem;
  font-weight: 600;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  transition: background 0.22s ease, color 0.22s ease, border-color 0.22s ease, transform 0.22s ease;
}

.water-pill:hover,
.water-pill:focus-visible {
  background: #ffffff;
  color: var(--deep-blue);
  border-color: #ffffff;
  transform: translateY(-1px);
}

/* ===============================
   NOGA
=============================== */
.legal-footer {
  background: rgba(4, 21, 33, 0.94);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  padding: clamp(2rem, 4vw, 3rem) 1rem 2.2rem;
  margin-top: 3.5rem;
  border-top: 1px solid var(--glass-border);
  color: var(--text-light);
}

.social-links-footer {
  display: flex;
  justify-content: center;
  gap: 0.9rem;
  margin-bottom: 1.6rem;
  flex-wrap: wrap;
}

.social-links-footer a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid var(--glass-border);
  transition: transform 0.25s ease, background 0.25s ease, border-color 0.25s ease;
}

.social-links-footer a:hover,
.social-links-footer a:focus-visible {
  transform: translateY(-3px);
  background: rgba(255, 255, 255, 0.2);
  border-color: rgba(255, 255, 255, 0.5);
}

.social-links-footer a svg {
  width: 20px;
  height: 20px;
}

.legal-details {
  max-width: 1020px;
  margin: 0 auto 1.8rem;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  overflow: hidden;
}

.legal-details summary {
  cursor: pointer;
  padding: 0.85rem 1.25rem;
  font-size: 0.84rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  transition: background 0.2s ease;
}

.legal-details summary::-webkit-details-marker {
  display: none;
}

.legal-details summary:hover {
  background: rgba(255, 255, 255, 0.06);
}

.legal-details summary .toggle-hint {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 0.78rem;
  font-weight: 500;
  color: #66c7ff;
  white-space: nowrap;
}

.legal-details summary .toggle-arrow {
  display: inline-block;
  transition: transform 0.22s ease;
}

.legal-details[open] summary .toggle-arrow {
  transform: rotate(180deg);
}

.disclaimer-container {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1.5rem;
  padding: 1.15rem 1.25rem 1.35rem;
  border-top: 1px solid rgba(255, 255, 255, 0.12);
  font-size: 0.82rem;
  line-height: 1.65;
}

.disclaimer-box {
  color: rgba(255, 255, 255, 0.82);
  text-align: start;
}

.disclaimer-box[dir="ltr"] {
  text-align: left;
  font-size: 0.82rem;
  line-height: 1.6;
}

.disclaimer-box a {
  color: #66c7ff;
  text-decoration: none;
}

.disclaimer-box a:hover {
  text-decoration: underline;
  color: #99dbff;
}

.footer-links {
  text-align: center;
  font-size: 0.9rem;
  direction: ltr;
}

.footer-links a {
  color: var(--text-light);
  text-decoration: none;
  font-weight: 600;
}

.footer-links a:hover {
  text-decoration: underline;
}

.footer-links p {
  color: rgba(255, 255, 255, 0.82);
}

/* ===============================
   ODZIVNOST
=============================== */
@media (max-width: 1080px) {
  .chapters-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 768px) {
  .top-controls {
    top: 14px;
    left: 14px;
    gap: 6px;
  }

  .lang-switcher {
    top: 14px;
    left: 14px;
  }

  .top-controls .lang-switcher {
    top: auto;
    left: auto;
  }

  .lang-trigger {
    height: 40px;
    padding: 0 12px;
    font-size: 0.78rem;
  }

  .script-switcher {
    height: 40px;
    padding: 3px;
  }

  .script-btn {
    padding: 0 9px;
    font-size: 0.76rem;
  }

  .lang-menu {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    width: min(410px, calc(100vw - 28px));
  }

  .chapters-grid,
  .chapters-grid.grid-2 {
    grid-template-columns: 1fr;
    gap: 1.1rem;
  }

  .catalog-main {
    padding: 0 0.85rem;
    gap: 2.1rem;
  }

  .dome-card {
    border-radius: 50% 50% var(--radius-lg) var(--radius-lg) / 50% 50% var(--radius-lg) var(--radius-lg);
  }

  .dome-viewport {
    height: 240px;
  }

  .dome-overlay {
    padding: 0.9rem 1.1rem;
  }

  .chapter,
  .chapters-grid.grid-2 .chapter {
    height: 255px;
  }

  .disclaimer-container {
    grid-template-columns: 1fr;
    gap: 1.1rem;
  }

  .link-container {
    gap: 0.5rem;
  }

  .btn {
    flex: 1 1 calc(50% - 0.5rem);
    min-width: 140px;
    font-size: 0.78rem;
    padding: 0.62rem 0.85rem;
  }
}

@media (max-width: 480px) {
  .responsive-header {
    padding-top: 2.8rem;
  }

  body:has(.top-controls) .responsive-header {
    padding-top: 3.4rem;
  }

  .lang-menu {
    grid-template-columns: 1fr;
    width: min(260px, calc(100vw - 28px));
  }

  .btn {
    flex: 1 1 100%;
  }

  #localSearchInput {
    font-size: 0.9rem;
    padding: 11px 14px;
  }

  .legal-details summary {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.3rem;
  }
}