* { box-sizing: border-box; }

:root {
  --bg: #f8fbff;
  --white: #ffffff;
  --text: #123047;
  --muted: #6b8296;
  --line: #dbe8f2;
  --green: #16a34a;
  --green-soft: #dcfce7;
  --blue: #2563eb;
  --blue-soft: #dbeafe;
  --shadow: 0 18px 40px rgba(15, 23, 42, 0.08);
  --footer-height: 110px;
}

html { scroll-behavior: smooth; }
html, body { min-height: 100%; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  background: linear-gradient(180deg, #ffffff 0%, var(--bg) 100%);
  color: var(--text);
  padding-bottom: var(--footer-height);
}
a { color: inherit; text-decoration: none; }
.container { width: min(1180px, calc(100% - 32px)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 2000;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(219, 232, 242, 0.9);
}

.nav-wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
}

.brand { font-size: 1.1rem; font-weight: 700; display: inline-flex; align-items: center; gap: 10px; }
.brand-mark {
  width: 38px; height: 38px; border-radius: 12px; display: inline-flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--green-soft), var(--blue-soft)); border: 1px solid var(--line); box-shadow: var(--shadow); font-size: 1.15rem;
}
.mobile-menu-btn {
  display: none; border: 1px solid var(--line); background: white; color: var(--text);
  border-radius: 12px; width: 46px; height: 46px; font-size: 1.2rem;
}

.main-nav { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.main-nav > a, .nav-dropdown-btn {
  padding: 10px 14px; border-radius: 999px; color: var(--text);
  border: 1px solid transparent; background: transparent; cursor: pointer; display: inline-flex; align-items: center;
}
.main-nav > a:hover, .nav-dropdown:hover .nav-dropdown-btn, .nav-dropdown-btn:hover {
  background: var(--blue-soft); color: var(--blue);
}

.nav-dropdown { position: relative; padding-bottom: 12px; margin-bottom: -12px; }
.nav-dropdown-menu {
  position: absolute; top: calc(100% - 2px); left: 0; min-width: 190px; background: var(--white);
  border: 1px solid var(--line); border-radius: 18px; box-shadow: var(--shadow); padding: 8px; display: none;
}
.nav-dropdown:hover .nav-dropdown-menu,
.nav-dropdown:focus-within .nav-dropdown-menu { display: grid; }
.nav-dropdown-menu a { padding: 10px 12px; border-radius: 12px; }
.nav-dropdown-menu a:hover { background: var(--green-soft); color: var(--green); }

.page-hero, .hero {
  padding: 62px 0 32px;
}

.hero-grid, .split-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(280px, 0.9fr);
  gap: 22px;
  align-items: center;
}

.badge, .section-kicker {
  display: inline-flex; align-items: center; padding: 8px 12px; border-radius: 999px;
  background: linear-gradient(135deg, var(--green-soft), var(--blue-soft)); color: #25526e; font-size: 0.82rem; font-weight: 700;
}

h1 { margin: 16px 0 14px; font-size: clamp(2.2rem, 4vw, 4rem); line-height: 1.06; }
p, li { color: var(--muted); line-height: 1.7; }

.hero-panel, .info-card, .product-card, .content-card {
  background: var(--white); border: 1px solid var(--line); border-radius: 24px; box-shadow: var(--shadow);
}

.hero-panel, .info-card, .content-card { padding: 24px; }
.hero-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 22px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; padding: 13px 18px;
  border-radius: 14px; font-weight: 700; border: 1px solid var(--line);
}
.btn-primary { background: linear-gradient(135deg, var(--green), #22c55e); color: white; border: none; }
.btn-secondary { background: var(--white); color: var(--blue); }

.section-heading {
  display: flex; justify-content: space-between; gap: 20px; align-items: end; margin-bottom: 22px;
}
.section-subtitle { margin: 6px 0 0; max-width: 640px; font-size: 1rem; }
.catalog-hero { padding: 18px 20px; border: 1px solid var(--line); border-radius: 24px; background: linear-gradient(135deg, rgba(220,252,231,.8), rgba(219,234,254,.9)); box-shadow: var(--shadow); }
.hero-panel-modern { background: linear-gradient(135deg, #dbeafe, #e0f2fe); padding: 40px; border-radius: 20px; margin-bottom: 20px; border: none; box-shadow: none; }
.catalog-badge { background: #bfdbfe; color: var(--primary, #0f172a); padding: 6px 12px; border-radius: 999px; font-size: 14px; font-weight: 700; }

.catalog-section, .content-section, .info-section { padding: 24px 0 56px; }

.filters-bar {
  display: grid; grid-template-columns: minmax(220px, 1.3fr) minmax(150px, 0.8fr) minmax(150px, 0.8fr) minmax(120px, 0.6fr);
  gap: 12px; margin-bottom: 24px;
}
.filters-modern { display: flex; gap: 12px; margin-bottom: 25px; }
.filters-bar input, .filters-bar select {
  width: 100%; border-radius: 16px; border: 1px solid var(--line); background: white; color: var(--text); padding: 14px 16px; font-size: 0.95rem;
}

.product-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
.product-card { overflow: hidden; transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease; }
.product-card:hover { transform: translateY(-3px); border-color: #c7dbeb; box-shadow: 0 22px 44px rgba(15, 23, 42, 0.11); }
.product-card-compact { border-radius: 20px; }
.product-card-modern { background: var(--white); border-radius: 16px; overflow: hidden; border: 1px solid #e2e8f0; box-shadow: none; }
.product-card-modern:hover { transform: translateY(-6px); box-shadow: 0 10px 25px rgba(0,0,0,0.08); border-color: #e2e8f0; }
.product-media { position: relative; padding: 10px; background: linear-gradient(180deg, #ffffff 0%, #f3f9ff 100%); }
.product-media-modern { padding: 4px; background: #ffffff; }
.product-name-tooltip {
  position: absolute;
  bottom: 10px;
  left: 10px;
  right: 10px;
  z-index: 3;
  background: rgba(15, 23, 42, 0.84);
  color: #fff;
  font-size: 11px;
  line-height: 1.3;
  padding: 6px 8px;
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  transform: translateY(4px);
  transition: opacity .18s ease, transform .18s ease;
}
.product-card-modern:hover .product-name-tooltip {
  opacity: 1;
  transform: translateY(0);
}
.product-image {
  width: 100%; aspect-ratio: 1 / 0.9; object-fit: contain; border-radius: 16px; background: white; border: 1px solid #e6eef5; cursor: zoom-in;
}
.product-image-modern { width: 100%; aspect-ratio: 1 / 1; height: auto; object-fit: contain; border-radius: 0; border: none; background: #ffffff; }
.product-image-placeholder { background: #ffffff; }
.carousel-btn {
  position: absolute; top: 50%; transform: translateY(-50%); width: 24px; height: 24px; border-radius: 999px;
  border: 1px solid rgba(219, 232, 242, 0.75); background: rgba(255, 255, 255, 0.72); color: #64748b; font-size: .9rem; cursor: pointer; box-shadow: none; opacity: .72;
}
.carousel-btn:hover { opacity: .95; background: rgba(255, 255, 255, 0.9); color: #334155; }
.carousel-btn.prev { left: 10px; }
.carousel-btn.next { right: 10px; }
.product-body { padding: 11px 12px 13px; display: grid; gap: 10px; }
.product-body-modern { padding: 12px; gap: 8px; }
.product-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 12px; align-items: start; }
.product-brand { color: var(--blue); font-size: 0.82rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; }
.product-brand-modern { font-size: 12px; color: #64748b; text-transform: uppercase; letter-spacing: .08em; }
.product-title { margin: 3px 0 0; font-size: .98rem; line-height: 1.25; overflow-wrap: anywhere; }
.product-title-modern {
  font-size: 15px;
  margin: 4px 0;
  color: #0f172a;
  line-height: 1.2;
  min-height: 36px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.price-tag { background: var(--green-soft); color: var(--green); border-radius: 999px; padding: 8px 10px; font-weight: 700; white-space: nowrap; font-size: .88rem; justify-self: end; align-self: start; }
.price-tag-modern { background: transparent; color: #22c55e; padding: 0; font-size: 18px; font-weight: 800; justify-self: start; }
.price-tag.sold-out { background: #fee2e2; color: #b91c1c; }
.product-description { margin: 0; min-height: 0; font-size: .86rem; line-height: 1.35; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.product-meta { display: flex; flex-wrap: wrap; gap: 8px; }
.product-tags { gap: 5px; margin-bottom: 6px; }
.meta-pill { padding: 6px 9px; border-radius: 999px; background: #f8fafc; border: 1px solid var(--line); color: var(--muted); font-size: 0.78rem; }
.product-tag { background: #f1f5f9; border: none; padding: 3px 7px; font-size: 11px; color: #475569; }
.pill-out { background: #fff1f2; color: #b91c1c; border-color: #fecdd3; }
.is-sold-out .product-image { opacity: .84; }
.product-action-btn { width: 100%; padding: 8px; border: none; border-radius: 10px; background: #0f172a; color: white; cursor: pointer; transition: .2s; font-size: .88rem; }
.product-action-btn:hover { background: #1e293b; }
.product-action-btn:disabled { background: #cbd5e1; cursor: not-allowed; }
.pagination { display: flex; justify-content: center; align-items: center; flex-wrap: wrap; gap: 6px; margin-top: 22px; }
.page-btn {
  min-width: 38px; height: 38px; border-radius: 10px; border: 1px solid var(--line); background: white; color: var(--text); cursor: pointer; font-weight: 700; padding: 0 10px;
}
.page-btn.active { background: linear-gradient(135deg, var(--green), #22c55e); color: white; border-color: transparent; }
.page-btn.nav-btn { min-width: 38px; padding: 0; font-size: 1rem; }
.page-btn:disabled { opacity: .45; cursor: not-allowed; }
.page-ellipsis { color: var(--muted); font-weight: 700; padding: 0 2px; }
.empty-state { padding: 32px; border: 1px dashed #c9dbe8; border-radius: 22px; background: white; color: var(--muted); text-align: center; }

.map-frame { overflow: hidden; border-radius: 20px; border: 1px solid var(--line); margin-top: 16px; }
.map-frame iframe { width: 100%; height: 320px; border: 0; }
.custom-map-frame { background: linear-gradient(180deg, #f8fbff 0%, #eef6ff 100%); padding: 12px; }
.large-card { background: linear-gradient(180deg, #ffffff 0%, #f8fbff 100%); }
.info-map-layout { display: grid; grid-template-columns: minmax(0, 1.9fr) minmax(250px, .95fr); gap: 18px; align-items: start; }
.course-panel { padding: 10px 4px; }
.leaflet-course-map { width: 100%; aspect-ratio: 1 / 1; min-height: 0; max-height: 420px; height: auto; border-radius: 18px; overflow: hidden; background: #dbeafe; position: relative; z-index: 1; box-shadow: inset 0 0 0 1px rgba(255,255,255,.35); }
.leaflet-pane, .leaflet-top, .leaflet-bottom { z-index: 1 !important; }
.leaflet-control { z-index: 2 !important; }
.leaflet-popup-content-wrapper, .leaflet-popup-tip { box-shadow: var(--shadow); }
.dg-marker {
  width: 32px; height: 32px; border-radius: 999px; background: linear-gradient(135deg, #16a34a, #22c55e); color: #fff; display: flex; align-items: center; justify-content: center;
  border: 2px solid rgba(255,255,255,.92); box-shadow: 0 10px 20px rgba(22, 163, 74, .22); font-size: .85rem;
}
.dg-popup { min-width: 170px; }
.dg-popup strong { display: block; color: var(--text); margin-bottom: 4px; }
.dg-popup span { color: var(--muted); font-size: .86rem; }
.course-links, .social-links { display: grid; gap: 10px; }
.course-links-panel a { display: grid; grid-template-columns: 40px 1fr; align-items: center; gap: 10px; background: linear-gradient(135deg, var(--green-soft), var(--blue-soft)); border: none; box-shadow: none; }
.course-links-panel a > div { display: grid; gap: 2px; align-content: center; }
.course-links-panel a strong { display: block; color: var(--text); line-height: 1.15; }
.course-links-panel a span { display: block; color: var(--muted); font-size: .72rem; line-height: 1.1; }
.udisc-logo { width: 40px; height: 40px; display: inline-flex; align-items: center; justify-content: center; }
.udisc-logo svg { width: 100%; height: 100%; display: block; }
.udisc-dark { fill: rgb(18, 48, 71); }
.udisc-orange { fill: rgb(249, 115, 22); }
.social-links.row { display: flex; flex-wrap: wrap; }
.course-links a, .social-links a {
  padding: 11px 14px; border-radius: 16px; background: linear-gradient(135deg, var(--green-soft), var(--blue-soft)); color: #25526e; font-weight: 700;
}

.site-footer {
  position: fixed; bottom: 0; left: 0; width: 100%; background: rgba(255, 255, 255, 0.98);
  border-top: 1px solid var(--line); backdrop-filter: blur(12px); z-index: 25;
}
.footer-wrap {
  min-height: var(--footer-height); display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 18px 0;
}

.image-modal {
  position: fixed; inset: 0; display: none; align-items: center; justify-content: center; background: rgba(7, 16, 30, 0.82); z-index: 60; padding: 24px;
}
.image-modal.is-open { display: flex; }
.image-modal img { max-width: min(92vw, 960px); max-height: 82vh; width: auto; border-radius: 22px; background: white; }
.modal-close {
  position: absolute; top: 20px; right: 20px; width: 46px; height: 46px; border-radius: 999px; border: none; background: white; color: var(--text); font-size: 1.6rem; cursor: pointer;
}

.maintenance-page { height: 100svh; min-height: 100vh; display: grid; place-items: stretch; padding: 0; overflow: hidden; background: radial-gradient(circle at top, #dce6ec 0%, #bccfd8 46%, #eef4f7 100%); }
.maintenance-body { overflow: hidden; }
.maintenance-shell { width: 100%; background: transparent; border: none; border-radius: 0; box-shadow: none; padding: 0; display: grid; gap: 0; text-align: center; }
.maintenance-visual { position: relative; overflow: hidden; height: 100%; min-height: 100vh; background: linear-gradient(180deg, #c5d3db 0%, #d8e4ea 100%); display: grid; place-items: center; align-items: center; justify-items: center; }
.maintenance-image { width: 100%; height: 100%; object-fit: cover; object-position: center; display: block; }
.preview-access-form { display: grid; gap: 14px; margin-top: 0; }
.preview-access-form.is-overlay { position: absolute; right: clamp(10px, 2.2vw, 22px); top: clamp(10px, 2.2vw, 22px); width: clamp(220px, 24vw, 280px); max-width: calc(100% - 24px); padding: clamp(8px, 1vw, 10px); border-radius: 18px; background: rgba(255,255,255,.08); backdrop-filter: blur(6px); box-shadow: 0 10px 28px rgba(15,23,42,.10); border: 1px solid rgba(255,255,255,.20); }
.preview-access-input { width: 100%; border-radius: 14px; border: 1px solid rgba(255,255,255,.26); background: rgba(255,255,255,.12); color: #f8fbff; padding: 10px 12px; font-size: .92rem; text-align: center; }
.preview-access-input::placeholder { color: rgba(248, 251, 255, 0.88); }
.preview-access-actions { display: grid; grid-template-columns:1fr; gap: 8px; justify-content: center; }
.preview-access-actions .btn { min-height: 40px; font-size: .84rem; padding: 9px 12px; }
.preview-access-error { min-height: 16px; color: #fff5f5; font-size: .78rem; font-weight: 700; text-shadow: 0 1px 10px rgba(0,0,0,.3); }

@media (max-width: 920px) {
  .mobile-menu-btn { display: inline-flex; align-items: center; justify-content: center; }
  .nav-wrap { flex-wrap: wrap; }
  .main-nav {
    width: 100%; display: none; flex-direction: column; align-items: stretch; gap: 6px; padding-top: 8px;
  }
  .main-nav.is-open { display: flex; }
  .main-nav > a, .nav-dropdown-btn {
    width: 100%; border: 1px solid var(--line); border-radius: 14px; justify-content: flex-start; background: white;
  }
  .nav-dropdown { padding-bottom: 0; margin-bottom: 0; }
  .nav-dropdown-menu { position: static; display: grid; margin-top: 8px; box-shadow: none; }
  .hero-grid, .split-grid, .section-heading, .filters-bar, .footer-wrap {
    grid-template-columns: 1fr; display: grid;
  }
  .maintenance-page, .maintenance-visual { height: 100dvh; min-height: 100dvh; }
  .preview-access-form.is-overlay { right: 12px; top: 12px; width: min(240px, calc(100% - 24px)); padding: 8px; }
  .preview-access-actions { grid-template-columns: 1fr; }
  .preview-access-actions .btn { width: 100%; }
  .hero, .page-hero { padding-top: 44px; }
  h1 { font-size: 2.2rem; }
  .product-grid { grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 12px; }
  .product-media { padding: 8px; }
  .product-image { aspect-ratio: 1 / 0.92; border-radius: 14px; }
  .product-body { padding: 10px 10px 12px; }
  .product-title { font-size: .92rem; }
  .price-tag { padding: 6px 8px; font-size: .78rem; }
  .product-description { min-height: 30px; font-size: .8rem; }
  .meta-pill { padding: 5px 7px; font-size: .7rem; }
  .map-frame iframe { height: 240px; }
  .info-map-layout { grid-template-columns: 1fr; }
  .leaflet-course-map { max-height: none; min-height: 260px; }
}

@media (max-width: 640px), (max-height: 760px) {
  .preview-access-form.is-overlay { width: min(220px, calc(100% - 20px)); top: 10px; right: 10px; padding: 8px; }
  .preview-access-input { padding: 8px 10px; font-size: .84rem; }
  .preview-access-actions .btn { min-height: 36px; font-size: .78rem; padding: 8px 10px; }
  .preview-access-error { min-height: 14px; font-size: .72rem; }
}