﻿:root {
  --bg: #f3f7fc;
  --panel: #ffffff;
  --line: #d9e4f2;
  --text: #0f1f38;
  --muted: #52627b;
  --primary: #0066cc;
  --primary-2: #004a99;
  --accent: #0a8f4e;
}
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
  color: var(--text);
  background: radial-gradient(circle at 8% 8%, #fbfdff 0%, #eef4fb 52%, #e7eff9 100%);
}
a { color: inherit; text-decoration: none; }
img { max-width: 100%; display: block; }
.container { width: min(1120px, 92vw); margin: 0 auto; }
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  backdrop-filter: blur(10px);
  background: rgba(243, 247, 252, 0.92);
  border-bottom: 1px solid var(--line);
}
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 76px;
}
.brand { display: inline-flex; align-items: center; gap: 10px; }
.brand img { width: 150px; height: auto; }
.brand span { font-size: 13px; text-transform: uppercase; letter-spacing: 1.2px; color: var(--muted); }
.nav { display: flex; gap: 14px; align-items: center; }
.nav a {
  padding: 10px 12px;
  border-radius: 10px;
  color: #17355c;
  font-weight: 600;
}
.nav a.active,
.nav a:hover { background: #e8f1ff; }
.cta-btn {
  border: 0;
  border-radius: 12px;
  padding: 10px 15px;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
}
.hero {
  margin-top: 24px;
  background: linear-gradient(130deg, #0a3b78, #0066cc 55%, #0b83cf);
  border-radius: 22px;
  color: #fff;
  padding: clamp(22px, 5vw, 42px);
}
.hero h1 { margin: 0; font-size: clamp(30px, 4vw, 52px); line-height: 1.06; }
.hero p { margin: 12px 0 0; color: #d8e9ff; max-width: 780px; }
.section-title { margin: 30px 0 14px; font-size: 28px; }
.home-layout {
  margin-top: 24px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 16px;
  align-items: start;
}
.home-main .hero { margin-top: 0; }
.grid { display: grid; gap: 14px; }
.grid.posts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.home-main .grid.posts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
.thumb {
  height: 152px;
  padding: 14px;
  color: #fff;
  font-weight: 800;
  display: flex;
  align-items: end;
  line-height: 1.15;
}
.thumb-1 { background: linear-gradient(135deg, #05417f, #0d78cb); }
.thumb-2 { background: linear-gradient(135deg, #0f5d48, #0bb16f); }
.thumb-3 { background: linear-gradient(135deg, #5b3d0c, #d78f14); }
.thumb-4 { background: linear-gradient(135deg, #5f1152, #be3d9f); }
.card-body { padding: 14px; display: flex; flex-direction: column; gap: 9px; }
.meta { color: var(--muted); font-size: 13px; }
.chips { display: flex; gap: 7px; flex-wrap: wrap; }
.card-actions {
  margin-top: auto;
  display: flex;
  gap: 8px;
  justify-content: flex-end;
}
.icon-btn {
  border: 1px solid #bfd0e8;
  background: #f5f9ff;
  color: #244973;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.icon-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}
.icon-btn:hover { background: #eaf3ff; }
.save-btn.is-saved {
  color: #fff;
  border-color: #0b6ec7;
  background: linear-gradient(135deg, #0066cc, #0b83cf);
}
.chip {
  border: 1px solid #bfd0e8;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  color: #31527f;
  background: #f4f8ff;
}
.card h3 { margin: 0; font-size: 22px; line-height: 1.15; }
.card p { margin: 0; color: #2b4467; }
.filters {
  margin-top: 20px;
  display: grid;
  grid-template-columns: 1fr 220px 220px;
  gap: 10px;
}
.input,
.select {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  padding: 12px 13px;
}
.layout { display: grid; gap: 16px; grid-template-columns: 1fr 320px; align-items: start; }
.post {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: clamp(18px, 3vw, 32px);
}
.post h1 { margin: 0 0 8px; font-size: clamp(28px, 4vw, 46px); }
.post-content { color: #17355c; line-height: 1.7; }
.post-content h2 { margin-top: 26px; margin-bottom: 8px; color: #102f58; }
.post-content ul { padding-left: 18px; }
.sidebar-card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px;
  margin-bottom: 14px;
}
.sidebar-card h3 { margin: 0 0 10px; }
.list-links { display: grid; gap: 10px; }
.list-links a {
  border: 1px solid #d2deef;
  border-radius: 12px;
  padding: 8px;
  display: grid;
  grid-template-columns: 78px 1fr;
  gap: 10px;
  align-items: center;
}
.list-links a .thumb { height: 64px; border-radius: 8px; font-size: 11px; }
.list-links a .meta { margin: 0; font-size: 12px; }
.list-links a strong {
  color: #10325d;
  line-height: 1.2;
  font-size: 14px;
}
.home-carousel {
  margin-top: 14px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 12px;
  overflow: hidden;
}
.carousel-track {
  display: flex;
  transition: transform 0.4s ease;
}
.carousel-slide {
  min-width: 100%;
}
.carousel-slide article {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 1.1fr;
  gap: 12px;
  align-items: stretch;
}
.carousel-slide .thumb {
  min-height: 170px;
  border-radius: 14px;
  padding: 18px;
}
.carousel-content {
  border: 1px solid #d7e4f6;
  border-radius: 14px;
  padding: 14px;
  display: grid;
  gap: 8px;
}
.carousel-content h3 {
  margin: 0;
  font-size: 22px;
  line-height: 1.2;
}
.carousel-content p {
  margin: 0;
  color: #2b4467;
}
.carousel-actions {
  margin-top: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
}
.carousel-btns {
  display: flex;
  gap: 8px;
}
.carousel-btn {
  border: 1px solid #bfd0e8;
  background: #f4f8ff;
  color: #163d6c;
  width: 36px;
  height: 36px;
  border-radius: 10px;
  font-size: 18px;
  line-height: 1;
  cursor: pointer;
}
.carousel-dots {
  display: flex;
  gap: 6px;
}
.carousel-dot {
  width: 9px;
  height: 9px;
  border: 0;
  border-radius: 999px;
  background: #c5d7ef;
  cursor: pointer;
  padding: 0;
}
.carousel-dot.active { background: #0a5eb5; }
.social-links {
  display: grid;
  gap: 8px;
}
.social-links a {
  border: 1px solid #d2deef;
  border-radius: 12px;
  padding: 10px 12px;
  font-weight: 600;
  color: #153b6a;
  background: #f8fbff;
}
.sidebar-text {
  margin: 0 0 12px;
  color: #2b4467;
  line-height: 1.55;
}
.sidebar-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  padding: 10px 14px;
  color: #fff;
  font-weight: 700;
  background: linear-gradient(135deg, var(--primary), var(--primary-2));
}
.share-modal {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: none;
}
.share-modal.is-open { display: block; }
.share-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(9, 23, 44, 0.55);
}
.share-modal__panel {
  position: relative;
  width: min(420px, calc(100vw - 24px));
  margin: 12vh auto 0;
  background: #fff;
  border: 1px solid #c8daef;
  border-radius: 16px;
  padding: 16px;
  display: grid;
  gap: 10px;
  z-index: 1;
}
.share-modal__panel h3 {
  margin: 0;
  font-size: 22px;
  color: #0f2f56;
}
.share-modal__links {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 8px;
}
.share-modal__links a {
  border: 1px solid #d2deef;
  border-radius: 10px;
  padding: 8px 6px;
  color: #173b68;
  background: #f8fbff;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
}
.share-link-icon {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  border: 1px solid #bfd0e8;
  background: #fff;
  color: #163d6c;
  font-size: 11px;
  font-weight: 800;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-transform: lowercase;
}
.share-link-label {
  font-size: 11px;
  line-height: 1.1;
  text-align: center;
  font-weight: 600;
}
.share-modal__url-row {
  display: grid;
  grid-template-columns: 1fr 44px;
  gap: 8px;
}
.share-url-input {
  width: 100%;
  border: 1px solid #bfd0e8;
  border-radius: 10px;
  padding: 10px 12px;
  color: #163d6c;
  background: #f8fbff;
}
.copy-icon-btn,
.close-share-btn {
  border: 1px solid #bfd0e8;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 700;
}
.copy-icon-btn {
  color: #fff;
  border: 0;
  background: linear-gradient(135deg, #0066cc, #0b83cf);
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.copy-icon-btn svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}
.copy-icon-btn.is-copied {
  background: linear-gradient(135deg, #0a8f4e, #0bb16f);
}
.close-share-btn {
  color: #204470;
  background: #f8fbff;
  padding: 10px 12px;
}
@media (max-width: 520px) {
  .share-modal__links {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}
.share {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 18px;
  justify-content: flex-end;
}
.share button {
  border: 1px solid #bfd0e8;
  border-radius: 999px;
  width: 42px;
  height: 42px;
  padding: 0;
  background: #f8fbff;
  color: #244973;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.share button svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.cta-final {
  margin-top: 24px;
  border: 1px solid #b7d4ff;
  background: linear-gradient(130deg, #eaf3ff, #f7fbff);
  border-radius: 16px;
  padding: 16px;
}
.cta-final h3 { margin: 0 0 8px; color: #0a3268; }
.footer {
  margin-top: 36px;
  border-top: 1px solid var(--line);
  padding: 18px 0 30px;
  color: var(--muted);
}
@media (max-width: 1020px) {
  .home-layout { grid-template-columns: 1fr; }
  .grid.posts,
  .home-main .grid.posts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .layout { grid-template-columns: 1fr; }
  .home-sidebar .list-links a {
    grid-template-columns: 64px 1fr;
  }
}
@media (max-width: 760px) {
  .grid.posts,
  .home-main .grid.posts { grid-template-columns: 1fr; }
  .filters { grid-template-columns: 1fr; }
  .carousel-slide article { grid-template-columns: 1fr; }
  .carousel-slide .thumb { min-height: 130px; }
  .carousel-content h3 { font-size: 20px; }
}
