/* ==========================================================================
   Iron Bank Кыргызстан — base.css
   Переменные, сброс, типографика, кнопки, таблицы, утилиты
   ========================================================================== */

:root {
  --bg: #0D1B1E;
  --bg-alt: #142B2E;
  --surface: #1B3938;
  --surface-2: #214541;
  --accent: #36B58F;
  --accent-2: #74D5BD;
  --gold: #E8B85B;
  --gold-2: #FFDA83;
  --text: #F5F0E6;
  --muted: #BCCBC7;
  --terra: #B66F4B;
  --dark: #0A1416;
  --line: rgba(232, 184, 91, .16);
  --line-strong: rgba(232, 184, 91, .38);
  --shadow-lg: 0 24px 60px rgba(0, 0, 0, .45);
  --shadow-md: 0 12px 32px rgba(0, 0, 0, .35);
  --radius: 18px;
  --radius-sm: 12px;
  --header-h: 76px;
  --container: 1180px;
  --font-body: 'Manrope', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --font-display: 'Playfair Display', Georgia, 'Times New Roman', serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  font-weight: 400;
  min-width: 320px;
  overflow-x: hidden;
}

@media (min-width: 1024px) {
  body {
    font-size: 1.125rem;
  }
}

img,
svg,
video,
iframe {
  max-width: 100%;
  height: auto;
  display: block;
}

button,
input,
textarea,
select {
  font: inherit;
  color: inherit;
}

h1,
h2,
h3,
h4 {
  margin: 0 0 .6em;
  line-height: 1.25;
  font-weight: 800;
}

p {
  margin: 0 0 1.1em;
}

ul,
ol {
  margin: 0 0 1.2em;
  padding-left: 1.4em;
}

a {
  color: var(--accent-2);
  text-decoration: none;
  transition: color .2s ease;
}

a:hover {
  color: var(--gold-2);
}

::selection {
  background: rgba(232, 184, 91, .35);
  color: #fff;
}

:focus-visible {
  outline: 2px solid var(--accent-2);
  outline-offset: 3px;
  border-radius: 4px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

/* ---------- Утилиты ---------- */

.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: 20px;
}

.skip-link {
  position: absolute;
  left: 16px;
  top: -64px;
  z-index: 200;
  padding: 10px 18px;
  background: var(--gold);
  color: #231a08;
  font-weight: 700;
  border-radius: 8px;
  transition: top .2s ease;
}

.skip-link:focus {
  top: 12px;
  color: #231a08;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Кнопки ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px 30px;
  border-radius: var(--radius-sm);
  border: 1px solid transparent;
  font-family: var(--font-body);
  font-size: .98rem;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
  line-height: 1.2;
  cursor: pointer;
  text-align: center;
  transition: transform .18s ease, box-shadow .18s ease, background-color .18s ease, border-color .18s ease, color .18s ease;
}

.btn svg {
  width: 18px;
  height: 18px;
  flex: none;
}

.btn--gold {
  background: linear-gradient(180deg, var(--gold-2) 0%, var(--gold) 60%, #d9a744 100%);
  color: #241a06;
  border-color: rgba(0, 0, 0, .18);
  box-shadow: 0 10px 26px rgba(232, 184, 91, .28), inset 0 1px 0 rgba(255, 255, 255, .45);
}

.btn--gold:hover {
  color: #241a06;
  transform: translateY(-2px);
  box-shadow: 0 14px 32px rgba(232, 184, 91, .38), inset 0 1px 0 rgba(255, 255, 255, .5);
}

.btn--outline {
  background: rgba(13, 27, 30, .55);
  color: var(--accent-2);
  border-color: var(--accent);
  box-shadow: inset 0 0 0 1px rgba(54, 181, 143, .15);
}

.btn--outline:hover {
  color: #eafff7;
  background: rgba(54, 181, 143, .16);
  border-color: var(--accent-2);
  transform: translateY(-2px);
}

.btn--sm {
  padding: 11px 20px;
  font-size: .85rem;
}

.btn--wide {
  width: 100%;
}

/* ---------- Секции и ритм ---------- */

.section {
  padding-block: 44px;
  scroll-margin-top: calc(var(--header-h) + 24px);
}

@media (min-width: 1024px) {
  .section {
    padding-block: 64px;
  }
}

.section--alt {
  background:
    radial-gradient(1200px 500px at 85% -10%, rgba(54, 181, 143, .07), transparent 60%),
    var(--bg-alt);
}

.section--gold-line {
  border-top: 1px solid var(--line);
}

.prose {
  max-width: 46rem;
}

.prose p:last-child {
  margin-bottom: 0;
}

.section-title {
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 1.2rem + 1.6vw, 2.15rem);
  font-weight: 800;
  color: var(--text);
  letter-spacing: .01em;
  margin-bottom: 1.1em;
}

.section-title::after {
  content: "";
  display: block;
  width: 64px;
  height: 3px;
  margin-top: 14px;
  border-radius: 2px;
  background: linear-gradient(90deg, var(--gold), rgba(232, 184, 91, 0));
}

.lead {
  font-size: 1.12em;
  color: var(--muted);
}

.text-muted {
  color: var(--muted);
}

/* ---------- Таблицы ---------- */

.table-responsive {
  width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 1.4em 0 1.6em;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.table-responsive table {
  width: 100%;
  min-width: 520px;
  border-collapse: collapse;
  font-size: .95rem;
  line-height: 1.5;
}

.table-responsive caption {
  caption-side: top;
  text-align: left;
  padding: 14px 18px 0;
  color: var(--muted);
  font-size: .85rem;
  letter-spacing: .06em;
  text-transform: uppercase;
}

.table-responsive th,
.table-responsive td {
  padding: 13px 18px;
  text-align: left;
  vertical-align: top;
  border-bottom: 1px solid rgba(188, 203, 199, .1);
}

.table-responsive thead th {
  background: rgba(232, 184, 91, .1);
  color: var(--gold-2);
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: .09em;
  text-transform: uppercase;
  border-bottom: 1px solid var(--line-strong);
  white-space: nowrap;
}

.table-responsive tbody tr:last-child th,
.table-responsive tbody tr:last-child td {
  border-bottom: 0;
}

.table-responsive tbody tr:hover {
  background: rgba(54, 181, 143, .06);
}

.table-responsive td.num,
.table-responsive th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.table-responsive .cell-key {
  color: var(--muted);
}

.table-responsive .cell-strong {
  color: var(--gold-2);
  font-weight: 700;
  white-space: nowrap;
}

/* ---------- Врезки и заметки ---------- */

.note {
  margin: 1.4em 0;
  padding: 18px 22px;
  background: rgba(232, 184, 91, .07);
  border: 1px solid var(--line);
  border-left: 3px solid var(--gold);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  max-width: 46rem;
}

.note p {
  margin: 0;
}

.note strong {
  color: var(--gold-2);
}

/* ---------- Медиа-рамки ---------- */

.media-frame {
  position: relative;
  margin: 0;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--line-strong);
  background: var(--dark);
  box-shadow: var(--shadow-lg);
}

.media-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 2;
  border-radius: inherit;
  box-shadow: inset 0 0 0 1px rgba(255, 218, 131, .12), inset 0 0 60px rgba(0, 0, 0, .35);
  pointer-events: none;
}

.media-frame img {
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.media-frame--contain img {
  object-fit: contain;
}

/* ---------- Орнаментальный разделитель ---------- */

.ornament {
  display: flex;
  align-items: center;
  gap: 14px;
  max-width: 420px;
  margin: 0 auto;
  color: var(--gold);
}

.ornament::before,
.ornament::after {
  content: "";
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--line-strong));
}

.ornament::after {
  background: linear-gradient(90deg, var(--line-strong), transparent);
}

.ornament span {
  width: 9px;
  height: 9px;
  transform: rotate(45deg);
  border: 1.5px solid var(--gold);
  border-radius: 2px;
}
