:root {
  --background: #f8fafc;
  --surface: #ffffff;
  --surface-muted: #f1f5f9;

  --text-main: #0f172a;
  --text-secondary: #334155;
  --text-muted: #64748b;

  --accent: #0f766e;
  --accent-dark: #115e59;
  --accent-soft: rgba(15, 118, 110, 0.08);

  --border: rgba(15, 23, 42, 0.08);
  --border-strong: rgba(15, 23, 42, 0.12);

  --dark: #111827;
  --dark-soft: #1f2937;

  --shadow-sm: 0 10px 30px rgba(15, 23, 42, 0.04);
  --shadow-md: 0 18px 50px rgba(15, 23, 42, 0.08);

  --radius-lg: 28px;
  --radius-md: 22px;
  --radius-sm: 16px;

  --container: 1240px;
  --header-height: 82px;

  --transition: 0.3s ease;
}

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

html {
  overflow-x: hidden;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--background);
  color: var(--text-main);
  font-family: "Inter", sans-serif;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

.container {
  width: min(calc(100% - 40px), var(--container));
  margin: 0 auto;
}

.section {
  padding: 110px 0;
}

section[id] {
  scroll-margin-top: calc(var(--header-height) + 18px);
}

.section-tight {
  padding-top: 30px;
  padding-bottom: 30px;
}

.section-muted {
  background: linear-gradient(180deg, rgba(15, 118, 110, 0.03), rgba(15, 118, 110, 0.01));
}

.eyebrow,
.section-kicker,
.section-kicker-light {
  margin: 0 0 14px;
  font-size: 0.92rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.eyebrow,
.section-kicker {
  color: var(--accent);
}

.section-kicker-light {
  color: rgba(255, 255, 255, 0.75);
}

h1,
h2,
h3 {
  margin: 0;
  font-family: "Manrope", sans-serif;
  letter-spacing: 0;
  line-height: 1.08;
}

h1 {
  font-size: clamp(2.5rem, 5vw, 4.35rem);
  font-weight: 800;
}

h2 {
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 800;
}

h3 {
  font-size: 1.3rem;
  font-weight: 700;
}

p {
  margin: 0 0 1rem;
  color: var(--text-secondary);
  font-size: 1.05rem;
}

.clean-list {
  margin: 0;
  padding-left: 1.1rem;
  color: var(--text-secondary);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(16px);
  background: rgba(248, 250, 252, 0.75);
  border-bottom: 1px solid transparent;
  transition: background var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.site-header.scrolled {
  background: rgba(248, 250, 252, 0.94);
  border-color: var(--border);
  box-shadow: 0 8px 30px rgba(15, 23, 42, 0.05);
}

.header-inner {
  min-height: var(--header-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
}

.brand-name {
  font-family: "Manrope", sans-serif;
  font-weight: 800;
  font-size: 1.05rem;
  color: var(--text-main);
  letter-spacing: 0;
}

.nav {
  display: flex;
  align-items: center;
  gap: 28px;
  margin-left: auto;
}

.nav-compact {
  gap: 24px;
}

.nav a {
  color: var(--text-secondary);
  font-size: 0.98rem;
  font-weight: 500;
  transition: color var(--transition);
}

.nav a:hover,
.mobile-nav a:hover {
  color: var(--accent);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 18px;
  transition: transform var(--transition), background var(--transition), color var(--transition), border-color var(--transition), box-shadow var(--transition);
}

.burger {
  display: none;
  width: 46px;
  height: 46px;
  border: 1px solid var(--border);
  border-radius: 14px;
  background: var(--surface);
  padding: 0;
  cursor: pointer;
}

.burger span {
  display: block;
  width: 20px;
  height: 2px;
  margin: 4px auto;
  background: var(--text-main);
  border-radius: 999px;
  transition: transform var(--transition), opacity var(--transition);
}

.mobile-menu {
  display: none;
  border-top: 1px solid var(--border);
  background: rgba(248, 250, 252, 0.98);
}

.mobile-menu.open {
  display: block;
}

.mobile-nav {
  width: min(calc(100% - 40px), var(--container));
  margin: 0 auto;
  padding: 18px 0 22px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.mobile-nav a {
  color: var(--text-secondary);
  font-weight: 500;
}

.hero {
  padding-top: 50px;
  overflow: hidden;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(340px, 0.95fr);
  gap: 48px;
  align-items: center;
}

.hero-content {
  position: relative;
  z-index: 1;
}

.hero-subtitle {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 14px;
  margin: 22px 0 26px;
}

.hero-subtitle span {
  position: relative;
  color: var(--text-secondary);
  font-weight: 600;
}

.hero-subtitle span:not(:last-child)::after {
  content: "•";
  margin-left: 14px;
  color: var(--text-muted);
}

.hero-text {
  max-width: 700px;
  font-size: 1.12rem;
  color: var(--text-secondary);
  margin-bottom: 32px;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 28px;
}

.btn {
  min-height: 54px;
  padding: 0 22px;
  font-weight: 700;
  font-size: 1rem;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 18px 40px rgba(15, 118, 110, 0.18);
}

.btn-primary:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
}

.btn-secondary {
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text-main);
}

.btn-secondary:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.badge {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 0 14px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  font-size: 0.95rem;
  font-weight: 500;
}

.hero-media {
  position: relative;
}

.hero-image-wrap {
  position: relative;
  border-radius: 32px;
  overflow: hidden;
  background:
    radial-gradient(circle at top right, rgba(15, 118, 110, 0.12), transparent 40%),
    linear-gradient(180deg, #eef6f5 0%, #ffffff 100%);
  box-shadow: var(--shadow-md);
}

.hero-image-wrap::before {
  content: "";
  position: absolute;
  inset: auto auto -60px -60px;
  width: 220px;
  height: 220px;
  background: rgba(15, 118, 110, 0.08);
  filter: blur(40px);
  border-radius: 50%;
  z-index: 1;
}

.hero-image {
  width: 100%;
  height: clamp(520px, 62vw, 860px);
  object-fit: contain;
  object-position: center center;
  position: relative;
  z-index: 2;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
}

.stat-card,
.info-card,
.adv-card,
.side-note-card,
.metric-card,
.publication-card,
.contact-card,
.mini-info-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: var(--shadow-sm);
}

.stat-card {
  padding: 26px 24px;
}

.stat-label {
  margin-bottom: 10px;
  color: var(--text-muted);
  font-size: 0.92rem;
  font-weight: 600;
}

.stat-card h3 {
  font-size: 1.15rem;
  margin-bottom: 10px;
}

.stat-card p:last-child {
  margin-bottom: 0;
  font-size: 0.98rem;
}

.section-grid {
  display: grid;
  grid-template-columns: minmax(260px, 0.9fr) minmax(0, 1.1fr);
  gap: 54px;
  align-items: start;
}

.section-aside h2 {
  max-width: 420px;
}

.section-head {
  max-width: 760px;
  margin-bottom: 42px;
}

.section-description {
  margin-top: 16px;
  max-width: 700px;
}

.mini-info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 16px;
  margin-top: 28px;
}

.mini-info-card {
  padding: 22px 20px;
}

.mini-info-title {
  display: block;
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.mini-info-text {
  display: block;
  color: var(--text-main);
  font-weight: 600;
}

.cards-grid {
  display: grid;
  gap: 22px;
}

.cards-grid-3 {
  grid-template-columns: repeat(3, 1fr);
}

.cards-grid-2 {
  grid-template-columns: repeat(2, 1fr);
}

.info-card,
.adv-card {
  padding: 28px 26px;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.info-card:hover,
.adv-card:hover,
.metric-card:hover,
.publication-card:hover,
.contact-card:hover,
.stat-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-md);
  border-color: var(--border-strong);
}

.info-card h3,
.adv-card h3 {
  margin-bottom: 12px;
  font-size: 1.18rem;
}

.info-card p,
.adv-card p {
  margin-bottom: 0;
}

.education-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(280px, 0.8fr);
  gap: 34px;
  align-items: start;
}

.timeline {
  position: relative;
  padding-left: 26px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 9px;
  top: 6px;
  bottom: 6px;
  width: 2px;
  background: linear-gradient(180deg, var(--accent-soft), rgba(15, 118, 110, 0.22));
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: 24px;
  padding: 0 0 28px;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -26px;
  top: 5px;
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: var(--surface);
  border: 5px solid var(--accent);
  box-shadow: 0 0 0 6px rgba(15, 118, 110, 0.08);
}

.timeline-year {
  color: var(--accent);
  font-weight: 800;
  font-size: 0.98rem;
}

.timeline-content h3 {
  font-size: 1.14rem;
  margin-bottom: 8px;
}

.side-note {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.side-note-card {
  padding: 26px 24px;
}

.side-note-label {
  color: var(--text-muted);
  font-size: 0.92rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.side-note-card h3 {
  margin-bottom: 10px;
}

.science-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.95fr);
  gap: 30px;
  align-items: start;
}

.metrics-grid {
  display: grid;
  gap: 18px;
}

.metric-card {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 22px;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.metric-icon-placeholder,
.publication-icon-placeholder {
  flex: 0 0 auto;
  border-radius: 18px;
  border: 1px dashed rgba(15, 118, 110, 0.28);
  background: var(--accent-soft);
  display: flex;
  align-items: center;
  justify-content: center;
}

.metric-icon-placeholder {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(15,118,110,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}

.publication-icon-placeholder {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: rgba(15,118,110,0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}

.metric-icon-placeholder::after,
.publication-icon-placeholder::after {
  content: "✓";
  font-size: 22px;
  font-weight: 700;
  color: var(--accent);
  color: var(--accent);
  font-size: 0.9rem;
  font-weight: 700;
}

.metric-value {
  margin: 0 0 4px;
  color: var(--text-main);
  font-family: "Manrope", sans-serif;
  font-size: 1.45rem;
  font-weight: 800;
  line-height: 1.1;
}

.metric-label {
  margin: 0;
  color: var(--text-secondary);
  font-size: 1rem;
}

.tags-wrap {
  margin-top: 42px;
}

.tags-title {
  margin-bottom: 16px;
  color: var(--text-main);
  font-weight: 700;
}

.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 16px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-secondary);
  font-weight: 500;
}

.publication-card {
  padding: 28px;
  display: flex;
  align-items: flex-start;
  gap: 22px;
  transition: transform var(--transition), box-shadow var(--transition), border-color var(--transition);
}

.publication-body h3 {
  margin-bottom: 12px;
}

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

.tool-hero {
  padding-top: 62px;
  background:
    linear-gradient(180deg, rgba(15, 118, 110, 0.07), rgba(248, 250, 252, 0)),
    var(--background);
}

.tool-hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(320px, 0.75fr);
  gap: 36px;
  align-items: center;
}

.tool-hero-content h1 {
  max-width: 900px;
}

.tool-hero-note {
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.tool-hero-note h2 {
  margin-bottom: 14px;
  font-size: clamp(1.55rem, 2.6vw, 2.2rem);
}

.tool-note-label,
.calc-kicker {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 0.84rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.tool-toc {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.tool-toc a {
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 14px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-secondary);
  font-weight: 700;
  transition: border-color var(--transition), color var(--transition), transform var(--transition);
}

.tool-toc a:hover {
  border-color: var(--border-strong);
  color: var(--accent);
  transform: translateY(-2px);
}

.tool-page-section {
  border-top: 1px solid var(--border);
}

.tool-calculators-grid {
  align-items: start;
}

.calculators-section {
  background: var(--surface);
}

.calculators-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
}

.calculator-card {
  min-width: 0;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--background);
  box-shadow: var(--shadow-sm);
  overflow-wrap: anywhere;
}

.calculator-card h3 {
  margin-bottom: 12px;
}

.calculator-card p {
  margin-bottom: 20px;
}

.calc-copy p {
  max-width: 920px;
}

.calculator-card-wide {
  grid-column: span 2;
}

.calc-fields {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
  margin-bottom: 16px;
}

.calc-fields-3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.calc-fields label {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.calc-fields span {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.calc-fields input,
.calc-fields select {
  width: 100%;
  min-width: 0;
  min-height: 52px;
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text-main);
  font: inherit;
  font-weight: 600;
  padding: 0 14px;
  outline: none;
}

.calc-fields input:focus,
.calc-fields select:focus {
  border-color: rgba(15, 118, 110, 0.55);
  box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.09);
}

.calc-button {
  min-height: 50px;
  padding: 0 18px;
  border: 0;
  border-radius: 16px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}

.calc-button:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
}

.calc-result {
  width: 100%;
  min-width: 0;
  margin-top: 16px;
  min-height: 72px;
  padding: 16px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
  color: var(--text-secondary);
  font-size: 1rem;
}

.calc-result strong {
  display: block;
  margin-bottom: 4px;
  color: var(--text-main);
  font-family: "Manrope", sans-serif;
  font-size: 1.35rem;
  line-height: 1.15;
}

.calc-result small {
  display: block;
  margin-top: 8px;
  color: var(--text-muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.formula-line {
  width: 100%;
  min-width: 0;
  margin: 14px 0 0;
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(15, 118, 110, 0.06);
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.formula-line strong {
  color: var(--text-main);
}

.target-lines {
  display: grid;
  gap: 10px;
}

.target-line {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
}

.target-line:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.target-line span {
  color: var(--text-muted);
  font-weight: 700;
}

.target-line b {
  color: var(--text-main);
  text-align: right;
}

.ckd-table-wrap {
  margin-top: 18px;
  overflow-x: auto;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}

.calc-table-title {
  margin-bottom: 10px;
  color: var(--text-main);
  font-weight: 800;
}

.calc-table {
  width: 100%;
  min-width: 620px;
  border-collapse: collapse;
  overflow: hidden;
  border-radius: 16px;
  background: var(--surface);
  box-shadow: inset 0 0 0 1px var(--border);
}

.calc-table th,
.calc-table td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
  text-align: left;
  vertical-align: top;
  overflow-wrap: anywhere;
}

.calc-table th {
  background: var(--surface-muted);
  color: var(--text-main);
  font-size: 0.9rem;
  font-weight: 800;
}

.calc-table td:first-child {
  color: var(--accent);
  font-weight: 800;
  white-space: nowrap;
}

.calc-table td:last-child,
.calc-table th:last-child {
  white-space: nowrap;
}

.calc-table tr:last-child td {
  border-bottom: 0;
}

.renal-meds-section {
  background:
    linear-gradient(180deg, rgba(15, 118, 110, 0.04), rgba(14, 165, 233, 0.04)),
    var(--background);
}

.renal-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 24px;
}

.renal-legend span {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 38px;
  padding: 0 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-secondary);
  font-weight: 700;
  font-size: 0.92rem;
}

.status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.status-green {
  background: #059669;
}

.status-yellow {
  background: #d97706;
}

.status-red {
  background: #dc2626;
}

.status-gray {
  background: #64748b;
}

.renal-meds-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 22px;
  align-items: start;
}

.renal-card {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.renal-card-wide {
  grid-column: span 2;
}

.renal-card-head h3 {
  margin-bottom: 12px;
}

.renal-inn {
  margin-bottom: 18px;
  color: var(--text-secondary);
  font-size: 0.98rem;
}

.renal-scale {
  display: grid;
  gap: 10px;
}

.renal-band {
  display: grid;
  grid-template-columns: minmax(92px, 0.34fr) minmax(0, 1fr);
  gap: 12px;
  align-items: center;
  min-height: 54px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid transparent;
}

.renal-band b {
  color: var(--text-main);
  font-family: "Manrope", sans-serif;
  font-size: 1.02rem;
}

.renal-band span {
  color: var(--text-secondary);
  font-weight: 700;
}

.renal-green,
.pill-green {
  background: rgba(5, 150, 105, 0.1);
  border-color: rgba(5, 150, 105, 0.22);
}

.renal-yellow,
.pill-yellow {
  background: rgba(217, 119, 6, 0.12);
  border-color: rgba(217, 119, 6, 0.24);
}

.renal-red,
.pill-red {
  background: rgba(220, 38, 38, 0.1);
  border-color: rgba(220, 38, 38, 0.22);
}

.renal-gray {
  background: rgba(100, 116, 139, 0.1);
  border-color: rgba(100, 116, 139, 0.22);
}

.renal-note,
.renal-disclaimer {
  margin: 16px 0 0;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.renal-drug-list {
  display: grid;
  gap: 12px;
}

.renal-drug {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--background);
}

.renal-drug b {
  min-width: 150px;
  color: var(--text-main);
  font-family: "Manrope", sans-serif;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid transparent;
  border-radius: 999px;
  color: var(--text-main);
  font-size: 0.88rem;
  font-weight: 800;
}

.renal-disclaimer {
  max-width: 980px;
  padding: 18px 20px;
  border: 1px solid var(--border);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.72);
}

.downloads-section {
  background: var(--background);
}

.downloads-grid,
.faq-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.download-card,
.faq-card {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.download-card h3,
.faq-card h3 {
  margin-bottom: 12px;
  font-size: 1.16rem;
}

.download-card p,
.faq-card p {
  margin-bottom: 18px;
}

.download-card a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 16px;
  border-radius: 14px;
  background: var(--accent);
  color: #fff;
  font-weight: 800;
  transition: background var(--transition), transform var(--transition);
}

.download-card a:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
}

.insulin-hero {
  background:
    radial-gradient(circle at 82% 18%, rgba(14, 165, 233, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(15, 118, 110, 0.08), rgba(248, 250, 252, 0)),
    var(--background);
}

.danger-note {
  border-color: rgba(220, 38, 38, 0.18);
  background:
    linear-gradient(180deg, rgba(254, 242, 242, 0.92), rgba(255, 255, 255, 0.96)),
    var(--surface);
}

.danger-note .tool-note-label {
  color: #b91c1c;
}

.emergency-section,
.hypo-section {
  background: var(--dark);
  color: #fff;
}

.emergency-card {
  padding: 34px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  border-radius: var(--radius-md);
  background:
    linear-gradient(135deg, rgba(220, 38, 38, 0.26), rgba(15, 118, 110, 0.18)),
    rgba(255, 255, 255, 0.04);
  box-shadow: 0 24px 70px rgba(0, 0, 0, 0.18);
}

.emergency-card h2,
.hypo-section h2 {
  color: #fff;
}

.emergency-grid,
.principle-grid,
.site-grid,
.helper-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.emergency-grid ul {
  margin: 0;
  padding-left: 1.2rem;
  color: rgba(255, 255, 255, 0.88);
}

.emergency-grid li + li {
  margin-top: 10px;
}

.insulin-type-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 22px;
}

.insulin-type-card,
.site-card,
.principle-grid article {
  padding: 26px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
}

.insulin-type-card p:last-child,
.site-card p:last-child,
.principle-grid p:last-child {
  margin-bottom: 0;
}

.principle-grid,
.site-grid {
  margin-top: 24px;
}

.rotation-note {
  margin-top: 22px;
  padding: 24px 26px;
  border: 1px solid rgba(15, 118, 110, 0.18);
  border-radius: var(--radius-md);
  background: rgba(15, 118, 110, 0.06);
}

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

.injection-checklist {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.injection-checklist label,
.helper-checks label {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  min-height: 52px;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface);
  color: var(--text-secondary);
  font-weight: 700;
}

.injection-checklist input,
.helper-checks input {
  width: 18px;
  height: 18px;
  margin-top: 3px;
  accent-color: var(--accent);
  flex: 0 0 auto;
}

.checklist-result {
  max-width: 760px;
}

.hypo-section p {
  color: rgba(255, 255, 255, 0.82);
}

.insulin-helper-section {
  background:
    linear-gradient(180deg, rgba(14, 165, 233, 0.05), rgba(15, 118, 110, 0.04)),
    var(--surface);
}

.helper-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 18px;
}

.helper-tab {
  min-height: 46px;
  padding: 0 16px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text-secondary);
  font-weight: 800;
  cursor: pointer;
  transition: color var(--transition), border-color var(--transition), background var(--transition), transform var(--transition);
}

.helper-tab:hover {
  transform: translateY(-2px);
}

.helper-tab.active {
  border-color: rgba(15, 118, 110, 0.28);
  background: var(--accent);
  color: #fff;
}

.helper-panel {
  display: none;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--background);
  box-shadow: var(--shadow-sm);
}

.helper-panel.active {
  display: block;
}

.helper-grid label {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.helper-grid span {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.helper-grid input,
.balance-topline select {
  width: 100%;
  min-height: 52px;
  border: 1px solid var(--border-strong);
  border-radius: 14px;
  background: var(--surface);
  color: var(--text-main);
  font: inherit;
  font-weight: 700;
  padding: 0 14px;
  outline: none;
}

.helper-grid input:focus,
.balance-topline select:focus {
  border-color: rgba(15, 118, 110, 0.55);
  box-shadow: 0 0 0 4px rgba(15, 118, 110, 0.09);
}

.helper-checks {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin: 18px 0;
}

.helper-warning-check {
  grid-template-columns: 1fr;
  margin-top: 0;
}

.helper-warning-check label {
  border-color: rgba(217, 119, 6, 0.24);
  background: rgba(217, 119, 6, 0.08);
}

.insulin-game-section {
  background:
    linear-gradient(180deg, rgba(15, 118, 110, 0.05), rgba(14, 165, 233, 0.05)),
    var(--background);
}

.balance-topline {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(88px, 0.4fr) auto;
  gap: 12px;
  align-items: end;
  margin-bottom: 14px;
}

.balance-topline label {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.balance-topline > div {
  min-height: 52px;
  padding: 8px 12px;
  border-radius: 16px;
  background: var(--surface-muted);
}

.balance-topline strong {
  display: block;
  color: var(--text-main);
  font-family: "Manrope", sans-serif;
  font-size: 1.4rem;
  line-height: 1;
}

.calc-result.is-warning {
  border-color: rgba(217, 119, 6, 0.32);
  background: rgba(255, 251, 235, 0.9);
}

.calc-result.is-danger {
  border-color: rgba(220, 38, 38, 0.28);
  background: rgba(254, 242, 242, 0.92);
}

.markdown-section {
  background: var(--surface);
}

.game-section {
  background:
    linear-gradient(180deg, rgba(14, 165, 233, 0.06), rgba(15, 118, 110, 0.04)),
    var(--background);
}

.game-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(360px, 1.1fr);
  gap: 34px;
  align-items: center;
}

.game-copy h2 {
  margin-bottom: 18px;
}

.game-panel {
  padding: 22px;
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: var(--shadow-md);
}

.game-topline {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 12px;
  align-items: center;
  margin-bottom: 16px;
}

.game-topline > div,
.game-start,
.game-controls button {
  border: 1px solid var(--border);
  border-radius: 16px;
  background: var(--surface-muted);
}

.game-topline > div {
  min-height: 58px;
  padding: 10px 14px;
}

.game-label {
  display: block;
  color: var(--text-muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.game-topline strong {
  display: block;
  color: var(--text-main);
  font-family: "Manrope", sans-serif;
  font-size: 1.35rem;
  line-height: 1.1;
}

.game-start {
  min-height: 58px;
  padding: 0 18px;
  color: #fff;
  background: var(--accent);
  border-color: var(--accent);
  font-weight: 800;
  cursor: pointer;
  transition: background var(--transition), transform var(--transition);
}

.game-start:hover {
  background: var(--accent-dark);
  transform: translateY(-2px);
}

.game-canvas {
  display: block;
  width: 100%;
  aspect-ratio: 720 / 460;
  height: auto;
  border-radius: 18px;
  background: #eef8f5;
  border: 1px solid var(--border);
  touch-action: none;
}

.game-controls {
  display: none;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 14px;
}

.game-controls button {
  min-height: 54px;
  color: var(--text-main);
  font-size: 1.35rem;
  font-weight: 800;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.contact-section {
  background: linear-gradient(180deg, var(--dark) 0%, #0b1220 100%);
  color: #fff;
}

.contact-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(320px, 0.95fr);
  gap: 34px;
  align-items: start;
}

.contact-section h2,
.contact-section p,
.contact-value {
  color: #fff;
}

.contact-text p:not(.section-kicker-light) {
  color: rgba(255, 255, 255, 0.78);
}

.contact-cards {
  display: grid;
  gap: 18px;
}

.contact-card {
  padding: 28px 26px;
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: none;
}

.contact-label {
  margin-bottom: 10px;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.95rem;
  font-weight: 600;
}

.contact-value {
  display: inline-block;
  font-family: "Manrope", sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  line-height: 1.25;
}

.contact-address {
  font-size: 1.18rem;
  font-weight: 700;
  font-family: "Inter", sans-serif;
}

.not-found-section {
  min-height: calc(100vh - var(--header-height));
  display: flex;
  align-items: center;
  background:
    radial-gradient(circle at 82% 18%, rgba(14, 165, 233, 0.12), transparent 34%),
    linear-gradient(180deg, rgba(15, 118, 110, 0.08), rgba(248, 250, 252, 0)),
    var(--background);
}

.not-found-wrap {
  max-width: 760px;
}

.not-found-wrap h1 {
  margin-bottom: 18px;
}

.site-footer {
  padding: 28px 0 36px;
  background: #0b1220;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-end;
}

.footer-main {
  max-width: 420px;
}

.footer-side {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 14px;
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 12px 18px;
}

.footer-nav a {
  color: rgba(255, 255, 255, 0.72);
  font-size: 0.95rem;
  font-weight: 700;
  transition: color var(--transition);
}

.footer-nav a:hover {
  color: #fff;
}

.footer-widgets {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.footer-stat-slot,
.footer-badge-slot {
  display: contents;
}

.footer-external-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 88px;
  height: 31px;
  border-radius: 4px;
  overflow: hidden;
  background: #fff;
  opacity: 0.82;
  transition: opacity var(--transition), transform var(--transition);
}

.footer-external-badge:hover {
  opacity: 1;
  transform: translateY(-2px);
}

.footer-external-badge img {
  width: 88px;
  height: 31px;
}

.footer-name {
  margin: 0 0 6px;
  color: #fff;
  font-weight: 700;
}

.footer-meta,
.footer-copy {
  margin: 0;
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.95rem;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
  will-change: opacity, transform;
}

.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

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

  .reveal,
  .reveal.visible,
  .site-header,
  .btn,
  .info-card,
  .adv-card,
  .metric-card,
  .publication-card,
  .contact-card,
  .stat-card {
    transition: none !important;
    transform: none !important;
    opacity: 1 !important;
  }
}

@media (max-width: 1180px) {
  .stats-grid,
  .calculators-grid,
  .cards-grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }

  .hero-grid,
  .section-grid,
  .science-grid,
  .tool-hero-grid,
  .game-grid,
  .contact-grid,
  .education-layout {
    grid-template-columns: 1fr;
  }

  .section-aside h2 {
    max-width: none;
  }

  .downloads-grid,
  .insulin-type-grid,
  .renal-meds-grid,
  .faq-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .nav {
    display: none;
  }

  .burger {
    display: inline-block;
  }

  .hero {
    padding-top: 32px;
  }

  .hero-grid {
    gap: 28px;
  }

  .hero-image {
    height: clamp(360px, 70vw, 520px);
    object-position: center top;
  }

  .timeline-item {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .timeline-year {
    padding-top: 2px;
  }
}

@media (max-width: 767px) {
  :root {
    --header-height: 74px;
  }

  .container {
    width: min(calc(100% - 28px), var(--container));
  }

  .section {
    padding: 82px 0;
  }

  .section-tight {
    padding-top: 20px;
    padding-bottom: 20px;
  }

  p {
    font-size: 1rem;
  }

  .hero-subtitle {
    flex-direction: column;
    gap: 8px;
  }

  .hero-subtitle span:not(:last-child)::after {
    display: none;
  }

  .hero-actions,
  .hero-badges,
  .tags {
    gap: 10px;
  }

  .stats-grid,
  .calculators-grid,
  .downloads-grid,
  .insulin-type-grid,
  .emergency-grid,
  .principle-grid,
  .site-grid,
  .helper-grid,
  .helper-checks,
  .injection-checklist,
  .renal-meds-grid,
  .faq-grid,
  .cards-grid-3,
  .cards-grid-2,
  .mini-info-grid {
    grid-template-columns: 1fr;
  }

  .info-card,
  .adv-card,
  .publication-card,
  .calculator-card,
  .download-card,
  .faq-card,
  .renal-card,
  .insulin-type-card,
  .site-card,
  .stat-card,
  .side-note-card,
  .game-panel,
  .contact-card {
    padding: 24px 20px;
  }

  .game-topline {
    grid-template-columns: 1fr 1fr;
  }

  .balance-topline {
    grid-template-columns: 1fr 1fr;
  }

  .calc-fields,
  .calc-fields-3 {
    grid-template-columns: 1fr;
  }

  .ckd-table-wrap {
    overflow-x: visible;
  }

  .calc-table {
    min-width: 0;
    table-layout: fixed;
  }

  .calc-table th,
  .calc-table td {
    padding: 10px 8px;
    font-size: 0.82rem;
    line-height: 1.35;
  }

  .calc-table th:first-child,
  .calc-table td:first-child {
    width: 48px;
  }

  .calc-table th:last-child,
  .calc-table td:last-child {
    width: 96px;
    white-space: normal;
  }

  .tool-toc a {
    flex: 1 1 auto;
    justify-content: center;
  }

  .calculator-card-wide {
    grid-column: auto;
  }

  .renal-card-wide {
    grid-column: auto;
  }

  .renal-band {
    grid-template-columns: 1fr;
    gap: 4px;
  }

  .renal-drug b {
    min-width: 100%;
  }

  .game-start {
    grid-column: 1 / -1;
  }

  .helper-panel,
  .emergency-card {
    padding: 22px 18px;
  }

  .game-controls {
    display: grid;
  }

  .publication-card {
    flex-direction: column;
    gap: 16px;
  }

  .metric-card {
    padding: 20px;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-side {
    align-items: flex-start;
  }

  .footer-nav,
  .footer-widgets {
    justify-content: flex-start;
  }

  .contact-value {
    font-size: 1.28rem;
  }

  .contact-address {
    font-size: 1.08rem;
  }
}

@media (max-width: 480px) {
  .brand-name {
    font-size: 0.98rem;
  }

  .btn {
    width: 100%;
  }

  .hero-image {
    height: 380px;
  }

  .metric-card {
    flex-direction: row;
    align-items: center;
  }

  .game-panel {
    padding: 18px 14px;
  }

  .game-topline {
    gap: 10px;
  }

  .game-topline > div,
  .game-start {
    min-height: 52px;
  }
}
