/* ============================================================
   Aximo — темы и интерфейс
   ============================================================ */

/* ============ темы ============ */
:root,
[data-theme='cyber'] {
  --bg: #08090c;
  color-scheme: dark;
  --bg-soft: #0d0f13;
  --card: #14171c;
  --card-2: #1a1e24;
  --line: rgba(190, 205, 220, 0.14);
  --line-strong: rgba(212, 255, 63, 0.32);
  --text: #f3f6f8;
  --muted: #949ca6;
  --muted-2: #616a74;
  --card-bg-1: rgba(22, 25, 30, 0.94);
  --card-bg-2: rgba(9, 10, 13, 0.97);
  --sheet-1: #14171c;
  --aura-1: rgba(212, 255, 63, 0.1);
  --aura-2: rgba(102, 227, 255, 0.13);
  --aura-3: rgba(151, 166, 255, 0.07);
  --aura-4: rgba(212, 255, 63, 0.05);
  --lime: #d4ff3f;
  --cyan-rgb: 102, 227, 255;
  --lime-rgb: 212, 255, 63;
  --violet-rgb: 151, 166, 255;
  --pink-rgb: 255, 138, 179;
  --line-rgb: 190, 205, 220;
  --team-accent: var(--lime);
  --primary-mid: #a9f5c5;
  --lime-soft: rgba(212, 255, 63, 0.12);
  --cyan: #66e3ff;
  --cyan-soft: rgba(102, 227, 255, 0.12);
  --violet: #97a6ff;
  --violet-soft: rgba(151, 166, 255, 0.14);
  --pink: #ff8ab3;
  --danger: #ff6b7a;
  --radius: 20px;
  --radius-sm: 14px;
  --font-body: 'Manrope', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-display: 'Unbounded', 'Manrope', -apple-system, BlinkMacSystemFont, sans-serif;
  --glow-cyan: 0 0 24px rgba(102, 227, 255, 0.32);
  --glow-lime: 0 0 26px rgba(212, 255, 63, 0.25);
  --safe-bottom: env(safe-area-inset-bottom, 0px);
}

[data-theme='concrete'] {
  --bg: #0b0b0c;
  --bg-soft: #121214;
  --card: #1a1a1d;
  --card-2: #232326;
  --line: rgba(205, 200, 190, 0.15);
  --line-strong: rgba(255, 212, 0, 0.35);
  --text: #f3f1ec;
  --muted: #a7a49c;
  --muted-2: #6e6b64;
  --lime: #ffd400;
  --cyan-rgb: 255, 107, 44;
  --lime-rgb: 255, 212, 0;
  --violet-rgb: 196, 192, 182;
  --pink-rgb: 255, 59, 48;
  --line-rgb: 205, 200, 190;
  --team-accent: var(--lime);
  --primary-mid: #ffe66b;
  --lime-soft: rgba(255, 212, 0, 0.12);
  --cyan: #ff6b2c;
  --cyan-soft: rgba(255, 107, 44, 0.12);
  --violet: #c4c0b6;
  --violet-soft: rgba(196, 192, 182, 0.12);
  --pink: #ff3b30;
  --card-bg-1: rgba(26, 26, 29, 0.95);
  --card-bg-2: rgba(11, 11, 12, 0.97);
  --sheet-1: #1b1b1e;
  --aura-1: rgba(255, 212, 0, 0.1);
  --aura-2: rgba(255, 107, 44, 0.1);
  --aura-3: rgba(196, 192, 182, 0.06);
  --aura-4: rgba(255, 212, 0, 0.04);
  --glow-lime: 0 0 26px rgba(255, 212, 0, 0.28);
  --glow-cyan: 0 0 24px rgba(255, 107, 44, 0.28);
}

[data-theme='hammer'] {
  --bg: #0a0707;
  --bg-soft: #120c0c;
  --card: #1b1212;
  --card-2: #251818;
  --line: rgba(220, 180, 170, 0.15);
  --line-strong: rgba(255, 77, 61, 0.38);
  --text: #f8f1ef;
  --muted: #bca09b;
  --muted-2: #7c5f5a;
  --lime: #ff4d3d;
  --cyan-rgb: 214, 211, 203;
  --lime-rgb: 255, 77, 61;
  --violet-rgb: 154, 163, 172;
  --pink-rgb: 255, 46, 99;
  --line-rgb: 220, 180, 170;
  --team-accent: var(--lime);
  --primary-mid: #ff8577;
  --lime-soft: rgba(255, 77, 61, 0.12);
  --cyan: #d6d3cb;
  --cyan-soft: rgba(214, 211, 203, 0.1);
  --violet: #9aa3ac;
  --violet-soft: rgba(154, 163, 172, 0.12);
  --pink: #ff2e63;
  --card-bg-1: rgba(27, 18, 18, 0.95);
  --card-bg-2: rgba(10, 7, 7, 0.97);
  --sheet-1: #1c1212;
  --aura-1: rgba(255, 77, 61, 0.13);
  --aura-2: rgba(214, 211, 203, 0.08);
  --aura-3: rgba(154, 163, 172, 0.07);
  --aura-4: rgba(255, 77, 61, 0.05);
  --glow-lime: 0 0 26px rgba(255, 77, 61, 0.3);
  --glow-cyan: 0 0 24px rgba(214, 211, 203, 0.16);
}

[data-theme='titan'] {
  --bg: #060a15;
  --bg-soft: #0a1120;
  --card: #0e1627;
  --card-2: #132039;
  --line: rgba(130, 165, 235, 0.17);
  --line-strong: rgba(124, 155, 255, 0.4);
  --text: #eff4ff;
  --muted: #8498bc;
  --muted-2: #53658a;
  --lime: #7c9bff;
  --cyan-rgb: 77, 227, 216;
  --lime-rgb: 124, 155, 255;
  --violet-rgb: 183, 156, 255;
  --pink-rgb: 255, 141, 184;
  --line-rgb: 130, 165, 235;
  --primary-mid: #7debd8;
  --lime-soft: rgba(124, 155, 255, 0.14);
  --cyan: #4de3d8;
  --cyan-soft: rgba(77, 227, 216, 0.12);
  --violet: #b79cff;
  --violet-soft: rgba(183, 156, 255, 0.14);
  --pink: #ff8db8;
  --card-bg-1: rgba(14, 22, 39, 0.94);
  --card-bg-2: rgba(5, 8, 16, 0.97);
  --sheet-1: #0f1a2e;
  --aura-1: rgba(124, 155, 255, 0.18);
  --aura-2: rgba(77, 227, 216, 0.12);
  --aura-3: rgba(183, 156, 255, 0.07);
  --aura-4: rgba(77, 227, 216, 0.06);
  --glow-lime: 0 0 26px rgba(124, 155, 255, 0.3);
  --glow-cyan: 0 0 24px rgba(77, 227, 216, 0.3);
}

[data-theme='rose'] {
  --bg: #120c10;
  --bg-soft: #1a1117;
  --card: #241821;
  --card-2: #2e1f2a;
  --line: rgba(255, 190, 205, 0.16);
  --line-strong: rgba(255, 158, 140, 0.38);
  --text: #fff4f2;
  --muted: #c4a4aa;
  --muted-2: #85686f;
  --lime: #ff9e8c;
  --cyan-rgb: 255, 143, 191;
  --lime-rgb: 255, 158, 140;
  --violet-rgb: 201, 166, 255;
  --pink-rgb: 255, 111, 165;
  --line-rgb: 255, 190, 205;
  --primary-mid: #ffc3b5;
  --lime-soft: rgba(255, 158, 140, 0.12);
  --cyan: #ff8fbf;
  --cyan-soft: rgba(255, 143, 191, 0.12);
  --violet: #c9a6ff;
  --violet-soft: rgba(201, 166, 255, 0.14);
  --pink: #ff6fa5;
  --card-bg-1: rgba(36, 24, 31, 0.94);
  --card-bg-2: rgba(15, 9, 13, 0.97);
  --sheet-1: #251821;
  --aura-1: rgba(255, 158, 140, 0.13);
  --aura-2: rgba(255, 143, 191, 0.12);
  --aura-3: rgba(201, 166, 255, 0.07);
  --aura-4: rgba(255, 158, 140, 0.05);
  --glow-lime: 0 0 26px rgba(255, 158, 140, 0.3);
  --glow-cyan: 0 0 24px rgba(255, 143, 191, 0.28);
}

[data-theme='aurora'] {
  --bg: #0a0916;
  --bg-soft: #100e20;
  --card: #191632;
  --card-2: #211d41;
  --line: rgba(178, 185, 255, 0.16);
  --line-strong: rgba(185, 166, 255, 0.4);
  --text: #f5f3ff;
  --muted: #a5a0c8;
  --muted-2: #6e6893;
  --lime: #b9a6ff;
  --cyan-rgb: 125, 242, 208;
  --lime-rgb: 185, 166, 255;
  --violet-rgb: 216, 166, 255;
  --pink-rgb: 255, 154, 213;
  --line-rgb: 178, 185, 255;
  --primary-mid: #d3c4ff;
  --lime-soft: rgba(185, 166, 255, 0.13);
  --cyan: #7df2d0;
  --cyan-soft: rgba(125, 242, 208, 0.11);
  --violet: #d8a6ff;
  --violet-soft: rgba(216, 166, 255, 0.14);
  --pink: #ff9ad5;
  --card-bg-1: rgba(25, 22, 44, 0.94);
  --card-bg-2: rgba(10, 8, 18, 0.97);
  --sheet-1: #191632;
  --aura-1: rgba(185, 166, 255, 0.16);
  --aura-2: rgba(125, 242, 208, 0.1);
  --aura-3: rgba(216, 166, 255, 0.08);
  --aura-4: rgba(125, 242, 208, 0.05);
  --glow-lime: 0 0 26px rgba(185, 166, 255, 0.3);
  --glow-cyan: 0 0 24px rgba(125, 242, 208, 0.26);
}

[data-theme='neon'] {
  --bg: #05080f;
  --bg-soft: #0a101c;
  --card: #0e1726;
  --card-2: #142138;
  --line: rgba(120,210,255, 0.16);
  --line-strong: rgba(57,255,207, 0.38);
  --text: #eefaff;
  --muted: #8ea9bd;
  --muted-2: #587086;
  --card-bg-1: rgba(14,23,38, 0.94);
  --card-bg-2: rgba(14,23,38, 0.97);
  --sheet-1: #111c2e;
  --aura-1: rgba(57,255,207, 0.14);
  --aura-2: rgba(83,200,255, 0.11);
  --aura-3: rgba(200,107,255, 0.07);
  --aura-4: rgba(57,255,207, 0.05);
  --lime: #39ffcf;
  --cyan-rgb: 83,200,255;
  --lime-rgb: 57,255,207;
  --violet-rgb: 200,107,255;
  --pink-rgb: 255,79,216;
  --line-rgb: 120,210,255;
  --team-accent: var(--lime);
  --primary-mid: #8dffe7;
  --lime-soft: rgba(57,255,207, 0.12);
  --cyan: #53c8ff;
  --cyan-soft: rgba(83,200,255, 0.12);
  --violet: #c86bff;
  --violet-soft: rgba(200,107,255, 0.14);
  --pink: #ff4fd8;
  --glow-lime: 0 0 26px rgba(57,255,207, 0.3);
  --glow-cyan: 0 0 24px rgba(83,200,255, 0.28);
}

[data-theme='emerald'] {
  --bg: #06110d;
  --bg-soft: #091a13;
  --card: #0f241b;
  --card-2: #153125;
  --line: rgba(104,200,160, 0.16);
  --line-strong: rgba(98,245,165, 0.38);
  --text: #effff8;
  --muted: #8db8a5;
  --muted-2: #587b6b;
  --card-bg-1: rgba(15,36,27, 0.94);
  --card-bg-2: rgba(15,36,27, 0.97);
  --sheet-1: #10271d;
  --aura-1: rgba(98,245,165, 0.14);
  --aura-2: rgba(53,214,194, 0.11);
  --aura-3: rgba(201,216,106, 0.07);
  --aura-4: rgba(98,245,165, 0.05);
  --lime: #62f5a5;
  --cyan-rgb: 53,214,194;
  --lime-rgb: 98,245,165;
  --violet-rgb: 201,216,106;
  --pink-rgb: 255,159,122;
  --line-rgb: 104,200,160;
  --team-accent: var(--lime);
  --primary-mid: #a7ffd0;
  --lime-soft: rgba(98,245,165, 0.12);
  --cyan: #35d6c2;
  --cyan-soft: rgba(53,214,194, 0.12);
  --violet: #c9d86a;
  --violet-soft: rgba(201,216,106, 0.14);
  --pink: #ff9f7a;
  --glow-lime: 0 0 26px rgba(98,245,165, 0.3);
  --glow-cyan: 0 0 24px rgba(53,214,194, 0.28);
}

[data-theme='sunset'] {
  --bg: #130b12;
  --bg-soft: #1d1019;
  --card: #2a1623;
  --card-2: #38202d;
  --line: rgba(230,160,180, 0.15);
  --line-strong: rgba(255,138,76, 0.38);
  --text: #fff5ef;
  --muted: #c6a0a8;
  --muted-2: #85626a;
  --card-bg-1: rgba(42,22,35, 0.94);
  --card-bg-2: rgba(42,22,35, 0.97);
  --sheet-1: #2b1724;
  --aura-1: rgba(255,138,76, 0.14);
  --aura-2: rgba(255,195,107, 0.11);
  --aura-3: rgba(216,107,255, 0.07);
  --aura-4: rgba(255,138,76, 0.05);
  --lime: #ff8a4c;
  --cyan-rgb: 255,195,107;
  --lime-rgb: 255,138,76;
  --violet-rgb: 216,107,255;
  --pink-rgb: 255,92,138;
  --line-rgb: 230,160,180;
  --team-accent: var(--lime);
  --primary-mid: #ffb38d;
  --lime-soft: rgba(255,138,76, 0.12);
  --cyan: #ffc36b;
  --cyan-soft: rgba(255,195,107, 0.12);
  --violet: #d86bff;
  --violet-soft: rgba(216,107,255, 0.14);
  --pink: #ff5c8a;
  --glow-lime: 0 0 26px rgba(255,138,76, 0.3);
  --glow-cyan: 0 0 24px rgba(255,195,107, 0.28);
}

[data-theme='ocean'] {
  --bg: #06101a;
  --bg-soft: #0a1724;
  --card: #102436;
  --card-2: #153047;
  --line: rgba(120,190,230, 0.16);
  --line-strong: rgba(56,232,208, 0.38);
  --text: #f0fbff;
  --muted: #8ba8bd;
  --muted-2: #566f84;
  --card-bg-1: rgba(16,36,54, 0.94);
  --card-bg-2: rgba(16,36,54, 0.97);
  --sheet-1: #11283c;
  --aura-1: rgba(56,232,208, 0.14);
  --aura-2: rgba(77,184,255, 0.11);
  --aura-3: rgba(141,141,255, 0.07);
  --aura-4: rgba(56,232,208, 0.05);
  --lime: #38e8d0;
  --cyan-rgb: 77,184,255;
  --lime-rgb: 56,232,208;
  --violet-rgb: 141,141,255;
  --pink-rgb: 255,143,199;
  --line-rgb: 120,190,230;
  --team-accent: var(--lime);
  --primary-mid: #87f7e8;
  --lime-soft: rgba(56,232,208, 0.12);
  --cyan: #4db8ff;
  --cyan-soft: rgba(77,184,255, 0.12);
  --violet: #8d8dff;
  --violet-soft: rgba(141,141,255, 0.14);
  --pink: #ff8fc7;
  --glow-lime: 0 0 26px rgba(56,232,208, 0.3);
  --glow-cyan: 0 0 24px rgba(77,184,255, 0.28);
}

[data-theme='sand'] {
  --bg: #120e09;
  --bg-soft: #1b1510;
  --card: #261d15;
  --card-2: #32261b;
  --line: rgba(220,190,150, 0.16);
  --line-strong: rgba(255,211,107, 0.38);
  --text: #fff9ef;
  --muted: #c2aa8e;
  --muted-2: #806b55;
  --card-bg-1: rgba(38,29,21, 0.94);
  --card-bg-2: rgba(38,29,21, 0.97);
  --sheet-1: #281f16;
  --aura-1: rgba(255,211,107, 0.14);
  --aura-2: rgba(255,180,92, 0.11);
  --aura-3: rgba(214,185,140, 0.07);
  --aura-4: rgba(255,211,107, 0.05);
  --lime: #ffd36b;
  --cyan-rgb: 255,180,92;
  --lime-rgb: 255,211,107;
  --violet-rgb: 214,185,140;
  --pink-rgb: 255,138,107;
  --line-rgb: 220,190,150;
  --team-accent: var(--lime);
  --primary-mid: #ffe2a3;
  --lime-soft: rgba(255,211,107, 0.12);
  --cyan: #ffb45c;
  --cyan-soft: rgba(255,180,92, 0.12);
  --violet: #d6b98c;
  --violet-soft: rgba(214,185,140, 0.14);
  --pink: #ff8a6b;
  --glow-lime: 0 0 26px rgba(255,211,107, 0.3);
  --glow-cyan: 0 0 24px rgba(255,180,92, 0.28);
}

[data-theme='graphite'] {
  --bg: #0b0c0e;
  --bg-soft: #111317;
  --card: #191c21;
  --card-2: #22262d;
  --line: rgba(190,205,220, 0.15);
  --line-strong: rgba(232,237,245, 0.38);
  --text: #f7f9fc;
  --muted: #9aa6b5;
  --muted-2: #65707e;
  --card-bg-1: rgba(25,28,33, 0.94);
  --card-bg-2: rgba(25,28,33, 0.97);
  --sheet-1: #1a1d22;
  --aura-1: rgba(232,237,245, 0.14);
  --aura-2: rgba(143,163,184, 0.11);
  --aura-3: rgba(185,198,214, 0.07);
  --aura-4: rgba(232,237,245, 0.05);
  --lime: #e8edf5;
  --cyan-rgb: 143,163,184;
  --lime-rgb: 232,237,245;
  --violet-rgb: 185,198,214;
  --pink-rgb: 255,107,138;
  --line-rgb: 190,205,220;
  --team-accent: var(--lime);
  --primary-mid: #d7dee8;
  --lime-soft: rgba(232,237,245, 0.12);
  --cyan: #8fa3b8;
  --cyan-soft: rgba(143,163,184, 0.12);
  --violet: #b9c6d6;
  --violet-soft: rgba(185,198,214, 0.14);
  --pink: #ff6b8a;
  --glow-lime: 0 0 26px rgba(232,237,245, 0.3);
  --glow-cyan: 0 0 24px rgba(143,163,184, 0.28);
}

[data-theme='cherry'] {
  --bg: #12070b;
  --bg-soft: #1b0b11;
  --card: #261018;
  --card-2: #341520;
  --line: rgba(220,150,170, 0.16);
  --line-strong: rgba(255,77,109, 0.38);
  --text: #fff0f4;
  --muted: #c795a3;
  --muted-2: #855b68;
  --card-bg-1: rgba(38,16,24, 0.94);
  --card-bg-2: rgba(38,16,24, 0.97);
  --sheet-1: #281018;
  --aura-1: rgba(255,77,109, 0.14);
  --aura-2: rgba(255,143,163, 0.11);
  --aura-3: rgba(211,107,255, 0.07);
  --aura-4: rgba(255,77,109, 0.05);
  --lime: #ff4d6d;
  --cyan-rgb: 255,143,163;
  --lime-rgb: 255,77,109;
  --violet-rgb: 211,107,255;
  --pink-rgb: 255,46,136;
  --line-rgb: 220,150,170;
  --team-accent: var(--lime);
  --primary-mid: #ff8fa6;
  --lime-soft: rgba(255,77,109, 0.12);
  --cyan: #ff8fa3;
  --cyan-soft: rgba(255,143,163, 0.12);
  --violet: #d36bff;
  --violet-soft: rgba(211,107,255, 0.14);
  --pink: #ff2e88;
  --glow-lime: 0 0 26px rgba(255,77,109, 0.3);
  --glow-cyan: 0 0 24px rgba(255,143,163, 0.28);
}

[data-theme='mint'] {
  --bg: #07110f;
  --bg-soft: #0b1916;
  --card: #11241f;
  --card-2: #17302a;
  --line: rgba(130,200,185, 0.16);
  --line-strong: rgba(141,255,203, 0.38);
  --text: #f1fffa;
  --muted: #8eb8aa;
  --muted-2: #587b6c;
  --card-bg-1: rgba(17,36,31, 0.94);
  --card-bg-2: rgba(17,36,31, 0.97);
  --sheet-1: #12281f;
  --aura-1: rgba(141,255,203, 0.14);
  --aura-2: rgba(77,227,216, 0.11);
  --aura-3: rgba(183,166,255, 0.07);
  --aura-4: rgba(141,255,203, 0.05);
  --lime: #8dffcb;
  --cyan-rgb: 77,227,216;
  --lime-rgb: 141,255,203;
  --violet-rgb: 183,166,255;
  --pink-rgb: 255,154,213;
  --line-rgb: 130,200,185;
  --team-accent: var(--lime);
  --primary-mid: #c2ffe4;
  --lime-soft: rgba(141,255,203, 0.12);
  --cyan: #4de3d8;
  --cyan-soft: rgba(77,227,216, 0.12);
  --violet: #b7a6ff;
  --violet-soft: rgba(183,166,255, 0.14);
  --pink: #ff9ad5;
  --glow-lime: 0 0 26px rgba(141,255,203, 0.3);
  --glow-cyan: 0 0 24px rgba(77,227,216, 0.28);
}

[data-theme='ice'] {
  --bg: #080e14;
  --bg-soft: #0d1720;
  --card: #142230;
  --card-2: #1b2d3f;
  --line: rgba(160,210,235, 0.17);
  --line-strong: rgba(167,243,255, 0.38);
  --text: #f6fdff;
  --muted: #91aec1;
  --muted-2: #5b7488;
  --card-bg-1: rgba(20,34,48, 0.94);
  --card-bg-2: rgba(20,34,48, 0.97);
  --sheet-1: #162638;
  --aura-1: rgba(167,243,255, 0.14);
  --aura-2: rgba(102,217,255, 0.11);
  --aura-3: rgba(185,201,255, 0.07);
  --aura-4: rgba(167,243,255, 0.05);
  --lime: #a7f3ff;
  --cyan-rgb: 102,217,255;
  --lime-rgb: 167,243,255;
  --violet-rgb: 185,201,255;
  --pink-rgb: 214,184,255;
  --line-rgb: 160,210,235;
  --team-accent: var(--lime);
  --primary-mid: #d6f8ff;
  --lime-soft: rgba(167,243,255, 0.12);
  --cyan: #66d9ff;
  --cyan-soft: rgba(102,217,255, 0.12);
  --violet: #b9c9ff;
  --violet-soft: rgba(185,201,255, 0.14);
  --pink: #d6b8ff;
  --glow-lime: 0 0 26px rgba(167,243,255, 0.3);
  --glow-cyan: 0 0 24px rgba(102,217,255, 0.28);
}

[data-theme='candy'] {
  --bg: #120c16;
  --bg-soft: #1a101f;
  --card: #26172d;
  --card-2: #33203c;
  --line: rgba(230,180,220, 0.16);
  --line-strong: rgba(255,168,216, 0.38);
  --text: #fff5fc;
  --muted: #c6a4bd;
  --muted-2: #85687d;
  --card-bg-1: rgba(38,23,45, 0.94);
  --card-bg-2: rgba(38,23,45, 0.97);
  --sheet-1: #291833;
  --aura-1: rgba(255,168,216, 0.14);
  --aura-2: rgba(183,166,255, 0.11);
  --aura-3: rgba(255,209,240, 0.07);
  --aura-4: rgba(255,168,216, 0.05);
  --lime: #ffa8d8;
  --cyan-rgb: 183,166,255;
  --lime-rgb: 255,168,216;
  --violet-rgb: 255,209,240;
  --pink-rgb: 255,122,200;
  --line-rgb: 230,180,220;
  --team-accent: var(--lime);
  --primary-mid: #ffd0ea;
  --lime-soft: rgba(255,168,216, 0.12);
  --cyan: #b7a6ff;
  --cyan-soft: rgba(183,166,255, 0.12);
  --violet: #ffd1f0;
  --violet-soft: rgba(255,209,240, 0.14);
  --pink: #ff7ac8;
  --glow-lime: 0 0 26px rgba(255,168,216, 0.3);
  --glow-cyan: 0 0 24px rgba(183,166,255, 0.28);
}

* {
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}

html,
body {
  margin: 0;
  padding: 0;
  min-height: 100%;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  line-height: 1.45;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  overscroll-behavior-y: none;
}

body.lock {
  overflow: hidden;
}

.sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

svg {
  display: block;
}

/* фоновое неоновое свечение */
.bg-aura {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(42% 34% at 18% 8%, var(--aura-1), transparent 70%),
    radial-gradient(45% 38% at 88% 4%, var(--aura-2), transparent 72%),
    radial-gradient(38% 30% at 50% 48%, var(--aura-3), transparent 75%),
    radial-gradient(50% 40% at 20% 100%, var(--aura-4), transparent 70%);
  filter: none;
}

.bg-aura::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(var(--line-rgb), 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(var(--line-rgb), 0.035) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(80% 60% at 50% 0%, #000 20%, transparent 85%);
  -webkit-mask-image: radial-gradient(80% 60% at 50% 0%, #000 20%, transparent 85%);
}

/* ------------------------------ фоны тем ------------------------------ */

/* Обсидиан — неоновый луч и тонкая сетка */
[data-theme='cyber'] .bg-aura {
  background:
    url('/assets/themes/cyber.svg?v=2') center / cover no-repeat,
    radial-gradient(42% 34% at 18% 8%, var(--aura-1), transparent 70%),
    radial-gradient(45% 38% at 88% 4%, var(--aura-2), transparent 72%),
    linear-gradient(118deg, transparent 47%, rgba(var(--lime-rgb), 0.04) 48%, transparent 52%),
    var(--bg);
}

/* Бетон — диагональные швы и зернистость */
[data-theme='concrete'] .bg-aura {
  background:
    url('/assets/themes/concrete.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 12% 0%, rgba(255, 212, 0, 0.07), transparent 70%),
    radial-gradient(50% 40% at 95% 18%, rgba(255, 107, 44, 0.05), transparent 72%),
    var(--bg);
}
[data-theme='concrete'] .bg-aura::after {
  background-image:
    repeating-linear-gradient(135deg, rgba(205, 200, 190, 0.06) 0 1px, transparent 1px 22px),
    radial-gradient(circle, rgba(205, 200, 190, 0.08) 1px, transparent 1.4px);
  background-size: auto, 17px 17px;
  opacity: 0.55;
  mask-image: linear-gradient(180deg, #000, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 90%);
}

/* Молот — шлифованный металл и красный край */
[data-theme='hammer'] .bg-aura {
  background:
    url('/assets/themes/hammer.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 42% at 88% 0%, rgba(255, 77, 61, 0.09), transparent 70%),
    radial-gradient(42% 36% at 8% 95%, rgba(154, 163, 172, 0.05), transparent 72%),
    var(--bg);
}
[data-theme='hammer'] .bg-aura::after {
  background-image:
    repeating-linear-gradient(90deg, rgba(214, 211, 203, 0.045) 0 1px, transparent 1px 5px),
    repeating-linear-gradient(0deg, rgba(255, 77, 61, 0.035) 0 1px, transparent 1px 44px);
  opacity: 0.7;
  mask-image: linear-gradient(120deg, #000, transparent 85%);
  -webkit-mask-image: linear-gradient(120deg, #000, transparent 85%);
}

/* Кобальт — синий чертёж */
[data-theme='titan'] .bg-aura {
  background:
    url('/assets/themes/titan.svg?v=2') center / cover no-repeat,
    radial-gradient(60% 45% at 80% 0%, rgba(124, 155, 255, 0.12), transparent 70%),
    radial-gradient(45% 40% at 0% 55%, rgba(77, 227, 216, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='titan'] .bg-aura::after {
  background-image:
    linear-gradient(rgba(124, 155, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(124, 155, 255, 0.06) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: radial-gradient(85% 65% at 50% 10%, #000, transparent 88%);
  -webkit-mask-image: radial-gradient(85% 65% at 50% 10%, #000, transparent 88%);
}

/* Пудра — шёлковые диагонали */
[data-theme='rose'] .bg-aura {
  background:
    url('/assets/themes/rose.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 15% 5%, rgba(255, 158, 140, 0.11), transparent 70%),
    radial-gradient(50% 45% at 90% 20%, rgba(255, 143, 191, 0.08), transparent 72%),
    radial-gradient(45% 40% at 50% 100%, rgba(201, 166, 255, 0.06), transparent 75%),
    var(--bg);
}
[data-theme='rose'] .bg-aura::after {
  background-image: repeating-linear-gradient(115deg, rgba(255, 158, 140, 0.055) 0 1px, transparent 1px 26px);
  opacity: 0.72;
  mask-image: linear-gradient(180deg, #000, transparent 92%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 92%);
}

/* Лаванда — северное сияние */
[data-theme='aurora'] .bg-aura {
  background:
    url('/assets/themes/aurora.svg?v=2') center / cover no-repeat,
    radial-gradient(60% 45% at 20% 0%, rgba(185, 166, 255, 0.14), transparent 70%),
    radial-gradient(50% 40% at 85% 10%, rgba(125, 242, 208, 0.09), transparent 72%),
    radial-gradient(55% 45% at 50% 100%, rgba(216, 166, 255, 0.07), transparent 75%),
    var(--bg);
}
[data-theme='aurora'] .bg-aura::after {
  background-image: repeating-linear-gradient(100deg, transparent 0 30px, rgba(185, 166, 255, 0.045) 30px 32px);
  opacity: 0.65;
  mask-image: radial-gradient(85% 70% at 50% 20%, #000, transparent 90%);
  -webkit-mask-image: radial-gradient(85% 70% at 50% 20%, #000, transparent 90%);
}

/* Неон — сканлайны */
[data-theme='neon'] .bg-aura {
  background:
    url('/assets/themes/neon.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 40% at 50% 0%, rgba(57, 255, 207, 0.12), transparent 70%),
    radial-gradient(45% 35% at 90% 55%, rgba(83, 200, 255, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='neon'] .bg-aura::after {
  background-image: repeating-linear-gradient(0deg, rgba(57, 255, 207, 0.05) 0 1px, transparent 1px 5px);
  opacity: 0.5;
  mask-image: linear-gradient(180deg, #000, transparent 85%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 85%);
}

/* Изумруд — концентрические круги */
[data-theme='emerald'] .bg-aura {
  background:
    url('/assets/themes/emerald.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 10% 0%, rgba(98, 245, 165, 0.1), transparent 70%),
    radial-gradient(50% 40% at 90% 100%, rgba(53, 214, 194, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='emerald'] .bg-aura::after {
  background-image: repeating-radial-gradient(circle at 85% 12%, rgba(98, 245, 165, 0.05) 0 1px, transparent 1px 52px);
  opacity: 0.7;
  mask-image: linear-gradient(180deg, #000, transparent 85%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 85%);
}

/* Закат — горизонт */
[data-theme='sunset'] .bg-aura {
  background:
    url('/assets/themes/sunset.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 40% at 50% 105%, rgba(255, 138, 76, 0.13), transparent 70%),
    radial-gradient(45% 35% at 10% 0%, rgba(255, 195, 107, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='sunset'] .bg-aura::after {
  background-image: repeating-linear-gradient(0deg, rgba(255, 138, 76, 0.045) 0 1px, transparent 1px 46px);
  opacity: 0.7;
  mask-image: linear-gradient(180deg, transparent, #000 55%, transparent 98%);
  -webkit-mask-image: linear-gradient(180deg, transparent, #000 55%, transparent 98%);
}

/* Океан — волны */
[data-theme='ocean'] .bg-aura {
  background:
    url('/assets/themes/ocean.svg?v=2') center / cover no-repeat,
    radial-gradient(50% 40% at 20% 0%, rgba(56, 232, 208, 0.1), transparent 70%),
    radial-gradient(55% 45% at 85% 25%, rgba(77, 184, 255, 0.08), transparent 72%),
    var(--bg);
}
[data-theme='ocean'] .bg-aura::after {
  background-image: repeating-radial-gradient(ellipse at 50% 120%, rgba(56, 232, 208, 0.055) 0 1px, transparent 1px 36px);
  opacity: 0.8;
  mask-image: linear-gradient(180deg, #000, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 90%);
}

/* Песок — тёплая зернистость */
[data-theme='sand'] .bg-aura {
  background:
    url('/assets/themes/sand.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 15% 0%, rgba(255, 211, 107, 0.1), transparent 70%),
    radial-gradient(50% 40% at 90% 20%, rgba(214, 185, 140, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='sand'] .bg-aura::after {
  background-image:
    radial-gradient(circle, rgba(255, 211, 107, 0.08) 1px, transparent 1.3px),
    radial-gradient(circle, rgba(214, 185, 140, 0.06) 1px, transparent 1.3px);
  background-size: 19px 19px, 31px 31px;
  background-position: 0 0, 7px 11px;
  opacity: 0.6;
  mask-image: linear-gradient(180deg, #000, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 90%);
}

/* Графит — углеволокно */
[data-theme='graphite'] .bg-aura {
  background:
    url('/assets/themes/graphite.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 40% at 15% 0%, rgba(232, 237, 245, 0.07), transparent 70%),
    radial-gradient(50% 45% at 85% 100%, rgba(143, 163, 184, 0.06), transparent 72%),
    var(--bg);
}
[data-theme='graphite'] .bg-aura::after {
  background-image:
    repeating-linear-gradient(45deg, rgba(232, 237, 245, 0.035) 0 1px, transparent 1px 9px),
    repeating-linear-gradient(-45deg, rgba(143, 163, 184, 0.03) 0 1px, transparent 1px 9px);
  opacity: 0.8;
  mask-image: linear-gradient(180deg, #000, transparent 92%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 92%);
}

/* Вишня — лепестки */
[data-theme='cherry'] .bg-aura {
  background:
    url('/assets/themes/cherry.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 15% 0%, rgba(255, 77, 109, 0.12), transparent 70%),
    radial-gradient(45% 40% at 90% 30%, rgba(211, 107, 255, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='cherry'] .bg-aura::after {
  background-image:
    radial-gradient(circle, rgba(255, 143, 163, 0.07) 1.2px, transparent 1.6px),
    repeating-linear-gradient(120deg, rgba(255, 77, 109, 0.035) 0 1px, transparent 1px 32px);
  background-size: 23px 23px, auto;
  opacity: 0.65;
  mask-image: linear-gradient(180deg, #000, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 90%);
}

/* Мята — свежие полосы */
[data-theme='mint'] .bg-aura {
  background:
    url('/assets/themes/mint.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 12% 0%, rgba(141, 255, 203, 0.11), transparent 70%),
    radial-gradient(50% 40% at 88% 20%, rgba(77, 227, 216, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='mint'] .bg-aura::after {
  background-image:
    repeating-linear-gradient(125deg, rgba(141, 255, 203, 0.045) 0 1px, transparent 1px 26px),
    radial-gradient(circle, rgba(183, 166, 255, 0.05) 1px, transparent 1.4px);
  background-size: auto, 27px 27px;
  opacity: 0.65;
  mask-image: linear-gradient(180deg, #000, transparent 92%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 92%);
}

/* Лёд — кристаллы */
[data-theme='ice'] .bg-aura {
  background:
    url('/assets/themes/ice.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 20% 0%, rgba(167, 243, 255, 0.13), transparent 70%),
    radial-gradient(50% 40% at 85% 25%, rgba(185, 201, 255, 0.07), transparent 72%),
    var(--bg);
}
[data-theme='ice'] .bg-aura::after {
  background-image:
    repeating-linear-gradient(120deg, rgba(167, 243, 255, 0.05) 0 1px, transparent 1px 36px),
    repeating-linear-gradient(60deg, rgba(185, 201, 255, 0.03) 0 1px, transparent 1px 56px);
  opacity: 0.7;
  mask-image: linear-gradient(180deg, #000, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 90%);
}

/* Карамель — пастельные полосы */
[data-theme='candy'] .bg-aura {
  background:
    url('/assets/themes/candy.svg?v=2') center / cover no-repeat,
    radial-gradient(55% 45% at 12% 0%, rgba(255, 168, 216, 0.12), transparent 70%),
    radial-gradient(50% 40% at 88% 20%, rgba(183, 166, 255, 0.08), transparent 72%),
    var(--bg);
}
[data-theme='candy'] .bg-aura::after {
  background-image:
    repeating-linear-gradient(115deg, rgba(255, 168, 216, 0.05) 0 1px, transparent 1px 28px),
    radial-gradient(circle, rgba(255, 209, 240, 0.06) 1px, transparent 1.4px);
  background-size: auto, 25px 25px;
  opacity: 0.65;
  mask-image: linear-gradient(180deg, #000, transparent 90%);
  -webkit-mask-image: linear-gradient(180deg, #000, transparent 90%);
}

.app {
  position: relative;
  z-index: 1;
  max-width: 640px;
  margin: 0 auto;
  min-height: 100vh;
}


/* У тем с рисованным фоном убираем лишнюю сетку поверх иллюстрации */
[data-theme]:not([data-theme='cyber']) .bg-aura::after {
  background-image: none;
  opacity: 0;
}

/* ------------------------------ topbar ------------------------------ */

.topbar {
  position: sticky;
  top: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: calc(14px + env(safe-area-inset-top, 0px)) 18px 12px;
  background: linear-gradient(180deg, rgba(5, 6, 12, 0.92) 55%, rgba(5, 6, 12, 0));
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.brand {
  display: flex;
  align-items: center;
  gap: 11px;
}

.logo {
  position: relative;
  width: 40px;
  height: 40px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  background: linear-gradient(140deg, rgba(var(--lime-rgb), 0.16), rgba(var(--cyan-rgb), 0.12) 55%, rgba(var(--violet-rgb), 0.18));
  border: 1px solid rgba(150, 255, 220, 0.35);
  box-shadow: 0 0 22px rgba(var(--cyan-rgb), 0.25), inset 0 0 14px rgba(var(--lime-rgb), 0.12);
}

.logo span {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  background: linear-gradient(140deg, var(--lime), var(--cyan) 60%, var(--violet));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 8px rgba(var(--cyan-rgb), 0.5));
}

.brand-text {
  line-height: 1.05;
}

.brand-name {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -0.02em;
  background: linear-gradient(92deg, #d7c9ff, #7df2d0 55%, #ff9ad5);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  filter: drop-shadow(0 0 10px rgba(125, 242, 208, 0.3));
}

.brand-sub {
  margin-top: 3px;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--muted-2);
}

.avatar {
  position: relative;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  border: 1px solid rgba(var(--cyan-rgb), 0.4);
  background: radial-gradient(120% 120% at 30% 20%, rgba(var(--cyan-rgb), 0.2), rgba(var(--violet-rgb), 0.14));
  color: var(--cyan);
  cursor: pointer;
  box-shadow: 0 0 18px rgba(var(--cyan-rgb), 0.22), inset 0 0 12px rgba(var(--cyan-rgb), 0.1);
  transition: transform 0.15s ease, box-shadow 0.2s ease;
}

.avatar:active {
  transform: scale(0.94);
}

.avatar svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.avatar.has-photo {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: #dffcff;
}

.avatar {
  overflow: hidden;
}

.avatar,
.profile-avatar,
.athlete-avatar {
  position: relative;
}

.avatar-fallback {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font: inherit;
  color: inherit;
  pointer-events: none;
}

.avatar img,
.profile-avatar img,
.athlete-avatar img,
.avatar-photo {
  position: absolute;
  inset: 0;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
}

/* ------------------------------ layout ------------------------------ */

.view-root {
  padding-bottom: calc(108px + var(--safe-bottom));
}

.view {
  padding: 8px 18px 24px;
  animation: fadeUp 0.32s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.hello {
  margin: 6px 0 18px;
}

.hello-date {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--cyan);
  opacity: 0.85;
  text-shadow: 0 0 16px rgba(var(--cyan-rgb), 0.55);
}

h1,
h2,
h3 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: -0.03em;
}

.hello h1 {
  margin-top: 8px;
  font-size: 27px;
  line-height: 1.15;
}

.hello p {
  margin: 8px 0 0;
  color: var(--muted);
  font-size: 14px;
}

h2 {
  font-size: 17px;
  letter-spacing: -0.02em;
}

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

.kicker {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.dot {
  color: var(--lime);
  text-shadow: var(--glow-lime);
}

.card {
  position: relative;
  background: linear-gradient(160deg, var(--card-bg-1), var(--card-bg-2));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: 0 18px 40px -24px rgba(0, 0, 0, 0.9), inset 0 1px 0 rgba(255, 255, 255, 0.04);
}

.glow-border {
  border-color: rgba(var(--cyan-rgb), 0.22);
  box-shadow:
    0 0 0 1px rgba(var(--violet-rgb), 0.06),
    0 10px 40px -18px rgba(var(--cyan-rgb), 0.28),
    0 18px 50px -30px rgba(var(--violet-rgb), 0.5),
    inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 24px 0 12px;
}

.link-btn {
  border: 0;
  background: none;
  padding: 0;
  color: var(--cyan);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  opacity: 0.9;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.link-btn svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ------------------------------ hero ------------------------------ */

.hero {
  padding: 18px;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  width: 220px;
  height: 220px;
  right: -90px;
  top: -110px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(var(--cyan-rgb), 0.22), transparent 65%);
  pointer-events: none;
}

.hero-grid {
  display: flex;
  align-items: center;
  gap: 16px;
}

.ring-wrap {
  position: relative;
  width: 108px;
  height: 108px;
  flex: 0 0 auto;
}

.ring-wrap svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.ring-track {
  fill: none;
  stroke: rgba(var(--line-rgb), 0.13);
  stroke-width: 8;
}

.ring-bar {
  fill: none;
  stroke: url(#ringGrad);
  stroke-width: 8;
  stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(var(--cyan-rgb), 0.6));
  transition: stroke-dashoffset 0.6s cubic-bezier(0.22, 1, 0.36, 1);
}

.ring-center {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  text-align: center;
}

.ring-center b {
  font-family: var(--font-display);
  font-size: 25px;
  font-weight: 800;
  line-height: 1;
}

.ring-center span {
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}

.hero-info {
  min-width: 0;
}

.hero-big {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 800;
  line-height: 1.1;
  margin-top: 2px;
  letter-spacing: -0.04em;
}

.hero-big span {
  font-size: 18px;
  color: var(--muted-2);
}

.hero-sub {
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 10px;
  padding: 5px 10px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 800;
  border: 1px solid rgba(var(--lime-rgb), 0.25);
  background: var(--lime-soft);
  color: var(--lime);
  box-shadow: 0 0 18px rgba(var(--lime-rgb), 0.12);
}

.pill-cyan {
  border-color: rgba(var(--cyan-rgb), 0.3);
  background: var(--cyan-soft);
  color: var(--cyan);
  box-shadow: 0 0 18px rgba(var(--cyan-rgb), 0.12);
}

.pill-violet {
  border-color: rgba(var(--violet-rgb), 0.32);
  background: var(--violet-soft);
  color: #c3a6ff;
  box-shadow: 0 0 18px rgba(var(--violet-rgb), 0.14);
}

.pill-muted {
  border-color: var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  box-shadow: none;
}

.pill svg {
  width: 12px;
  height: 12px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.neon-divider {
  height: 1px;
  margin: 16px 0;
  background: linear-gradient(90deg, transparent, rgba(var(--cyan-rgb), 0.5), rgba(var(--violet-rgb), 0.4), transparent);
  box-shadow: 0 0 12px rgba(var(--cyan-rgb), 0.35);
}

.hero-mini {
  display: grid;
  grid-template-columns: 1.08fr 1.12fr 0.9fr 0.9fr;
  gap: 10px;
  margin-top: 14px;
}

.hero-mini-item {
  min-width: 0;
  padding: 8px 9px;
  border-radius: 12px;
  border: 1px solid rgba(var(--line-rgb), 0.1);
  background: rgba(255, 255, 255, 0.025);
}

.hero-mini-item > span {
  display: block;
  font-size: 7.5px;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted-2);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero-mini-item > b {
  display: block;
  margin-top: 3px;
  font-size: 13px;
  line-height: 1.15;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hero-mini-item > small {
  display: block;
  margin-top: 2px;
  font-size: 8.5px;
  line-height: 1.25;
  color: var(--muted-2);
  white-space: normal;
  overflow-wrap: anywhere;
}

@media (max-width: 360px) {
  .hero-mini {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.hero-actions {
  display: flex;
  gap: 10px;
  margin-top: 14px;
}

.hero-actions .btn {
  flex: 1;
  min-width: 0;
}

.hero-start-btn > span {
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

/* ------------------------------ buttons ------------------------------ */

.btn {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 48px;
  padding: 0 18px;
  border-radius: 15px;
  border: 1px solid transparent;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 800;
  letter-spacing: 0.01em;
  color: var(--text);
  background: rgba(255, 255, 255, 0.05);
  cursor: pointer;
  transition: transform 0.12s ease, filter 0.2s ease, box-shadow 0.2s ease;
  user-select: none;
}

.btn:active {
  transform: scale(0.975);
}

.btn svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.btn-primary {
  color: #06090b;
  background: linear-gradient(120deg, var(--lime), var(--primary-mid) 45%, var(--cyan));
  border-color: rgba(255, 255, 255, 0.22);
  box-shadow: 0 8px 28px -8px rgba(120, 255, 190, 0.55), 0 0 24px rgba(var(--cyan-rgb), 0.25);
  text-shadow: 0 1px 0 rgba(255, 255, 255, 0.25);
}

.btn-primary svg {
  stroke-width: 2.4;
}

.btn-cyan {
  color: #03181c;
  background: linear-gradient(120deg, var(--cyan), #8ff0ff);
  box-shadow: 0 8px 26px -10px rgba(var(--cyan-rgb), 0.8);
}

.btn-ghost {
  background: rgba(255, 255, 255, 0.045);
  border-color: var(--line);
  color: var(--text);
}

.btn-danger {
  background: rgba(255, 84, 112, 0.13);
  border-color: rgba(255, 84, 112, 0.35);
  color: #ff879b;
}

.btn-sm {
  min-height: 38px;
  padding: 0 14px;
  font-size: 12px;
  border-radius: 12px;
}

.btn-block {
  width: 100%;
}

.btn-icon {
  flex: 0 0 auto;
  width: 42px;
  min-height: 42px;
  padding: 0;
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
}

.btn-icon svg {
  width: 18px;
  height: 18px;
}

.btn[disabled] {
  opacity: 0.45;
  pointer-events: none;
}

/* ------------------------------ programs ------------------------------ */

.program-create-card {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px;
  margin-bottom: 14px;
  text-align: left;
  border: 1px dashed rgba(var(--lime-rgb), 0.38);
  border-radius: var(--radius);
  background: linear-gradient(145deg, rgba(var(--lime-rgb), 0.1), rgba(var(--cyan-rgb), 0.04));
  color: var(--text);
  cursor: pointer;
  box-shadow: 0 0 26px -16px rgba(var(--lime-rgb), 0.45);
}

.program-create-card .pc-icon {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  color: var(--lime);
  border: 1px solid rgba(var(--lime-rgb), 0.3);
  background: rgba(var(--lime-rgb), 0.1);
}

.program-create-card .pc-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.program-create-card .pc-head {
  flex: 1;
  min-width: 0;
}

.program-create-card .pc-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
}

.program-create-card .pc-sub {
  margin-top: 3px;
  font-size: 11px;
  line-height: 1.4;
  color: var(--muted);
}

.program-card {
  position: relative;
  display: block;
  width: 100%;
  text-align: left;
  padding: 16px;
  margin-bottom: 12px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(150deg, var(--card-bg-1), var(--card-bg-2));
  color: var(--text);
  cursor: pointer;
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.15s ease;
}

.program-card:active {
  transform: scale(0.985);
}

.program-card::after {
  content: '';
  position: absolute;
  inset: auto -40px -70px auto;
  width: 150px;
  height: 150px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--pc-glow, rgba(var(--cyan-rgb), 0.18)), transparent 70%);
  pointer-events: none;
}

.pc-top {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.pc-icon {
  width: 44px;
  height: 44px;
  border-radius: 13px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line-strong);
  background: linear-gradient(145deg, rgba(var(--cyan-rgb), 0.14), rgba(var(--violet-rgb), 0.14));
  color: var(--cyan);
  box-shadow: inset 0 0 14px rgba(var(--cyan-rgb), 0.1);
}

.pc-icon svg {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.pc-head {
  flex: 1;
  min-width: 0;
}

.pc-title {
  font-family: var(--font-display);
  font-size: 16px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.pc-sub {
  margin-top: 3px;
  font-size: 12px;
  color: var(--muted);
}

.pc-arrow {
  color: var(--muted-2);
  padding-top: 4px;
}

.pc-arrow svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.pc-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 14px;
}

.tag {
  padding: 4px 9px;
  border-radius: 8px;
  font-size: 10px;
  font-weight: 700;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.06);
}

.tag-lime {
  color: var(--lime);
  background: var(--lime-soft);
  border-color: rgba(var(--lime-rgb), 0.22);
}

.tag-cyan {
  color: var(--cyan);
  background: var(--cyan-soft);
  border-color: rgba(var(--cyan-rgb), 0.24);
}

/* ------------------------------ segmented / chips ------------------------------ */

.segmented {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: 1fr;
  gap: 4px;
  padding: 4px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--line);
  margin-bottom: 16px;
}

.segmented button {
  border: 0;
  background: transparent;
  color: var(--muted);
  font-family: var(--font-body);
  font-weight: 700;
  font-size: 12px;
  padding: 9px 8px;
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.18s ease;
}

.segmented button.active {
  color: #04120c;
  background: linear-gradient(120deg, var(--lime), var(--cyan));
  box-shadow: 0 0 18px rgba(var(--lime-rgb), 0.25);
}

.chips {
  display: flex;
  gap: 8px;
  overflow-x: auto;
  padding: 2px 0 10px;
  scrollbar-width: none;
  margin: 0 -18px;
  padding-left: 18px;
  padding-right: 18px;
}

.chips::-webkit-scrollbar {
  display: none;
}

.chip {
  flex: 0 0 auto;
  padding: 8px 13px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.18s ease;
}

.chip.active {
  color: var(--cyan);
  border-color: rgba(var(--cyan-rgb), 0.45);
  background: var(--cyan-soft);
  box-shadow: 0 0 16px rgba(var(--cyan-rgb), 0.18);
}

.chip .count {
  opacity: 0.55;
  margin-left: 4px;
  font-size: 10px;
}

/* ------------------------------ search ------------------------------ */

.search {
  position: relative;
  margin-bottom: 14px;
}

.search svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  width: 17px;
  height: 17px;
  fill: none;
  stroke: var(--muted-2);
  stroke-width: 2;
  stroke-linecap: round;
}

.search input {
  width: 100%;
  height: 46px;
  padding: 0 14px 0 40px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  outline: none;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search input::placeholder {
  color: var(--muted-2);
}

.search input:focus {
  border-color: rgba(var(--cyan-rgb), 0.5);
  box-shadow: 0 0 0 3px rgba(var(--cyan-rgb), 0.1), 0 0 20px rgba(var(--cyan-rgb), 0.12);
}

/* ------------------------------ exercise rows ------------------------------ */

.ex-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  margin-bottom: 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: linear-gradient(150deg, var(--card-bg-1), var(--card-bg-2));
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, background 0.18s ease;
}

.ex-row:active {
  background: rgba(var(--cyan-rgb), 0.06);
  border-color: rgba(var(--cyan-rgb), 0.35);
}

.ex-thumb {
  width: 40px;
  height: 40px;
  flex: 0 0 auto;
  border-radius: 11px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 800;
  color: var(--group-color, var(--cyan));
  background: color-mix(in srgb, var(--group-color, var(--cyan)) 12%, transparent);
  border: 1px solid color-mix(in srgb, var(--group-color, var(--cyan)) 30%, transparent);
}

.ex-main {
  flex: 1;
  min-width: 0;
}

.ex-name {
  font-size: 14px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ex-sub {
  margin-top: 2px;
  font-size: 11px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ex-plus {
  width: 30px;
  height: 30px;
  flex: 0 0 auto;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--cyan);
  background: rgba(var(--cyan-rgb), 0.1);
}

.ex-plus svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
}

/* ------------------------------ stats ------------------------------ */

.stat-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.stat {
  padding: 15px 16px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: linear-gradient(155deg, var(--card-bg-1), var(--card-bg-2));
}

.stat-label {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.stat-label svg {
  width: 13px;
  height: 13px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.stat-value {
  margin-top: 7px;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
}

.stat-value small {
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  color: var(--muted);
  letter-spacing: 0;
}

.stat-sub {
  margin-top: 3px;
  font-size: 11px;
  color: var(--muted);
}

.text-lime {
  color: var(--lime);
  text-shadow: 0 0 18px rgba(var(--lime-rgb), 0.3);
}

.text-cyan {
  color: var(--cyan);
  text-shadow: 0 0 18px rgba(var(--cyan-rgb), 0.3);
}

.text-violet {
  color: #c4a8ff;
}

.text-danger {
  color: #ff879b;
  text-shadow: 0 0 18px rgba(255, 84, 112, 0.35);
}

/* ------------------------------ charts ------------------------------ */

.chart-card {
  margin-top: 12px;
  padding: 16px;
}

.chart-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 14px;
}

.chart-head h3 {
  font-size: 14px;
  letter-spacing: -0.01em;
}

.chart-head span {
  font-size: 11px;
  color: var(--muted);
}

.bars {
  width: 100%;
}

.bars svg {
  width: 100%;
  height: auto;
  overflow: visible;
}

.bar-rect {
  transition: height 0.4s ease;
}

.bar-label {
  font-family: var(--font-body);
  font-size: 8.5px;
  font-weight: 600;
  fill: var(--muted-2);
}

.bar-value {
  font-family: var(--font-body);
  font-size: 8.5px;
  font-weight: 800;
  fill: var(--cyan);
}

.donut-wrap {
  display: flex;
  align-items: center;
  gap: 18px;
}

.donut {
  position: relative;
  width: 116px;
  height: 116px;
  flex: 0 0 auto;
  border-radius: 50%;
  filter: drop-shadow(0 0 16px rgba(var(--cyan-rgb), 0.18));
}

.donut::after {
  content: '';
  position: absolute;
  inset: 13px;
  border-radius: 50%;
  background: #0a0d19;
  border: 1px solid rgba(255, 255, 255, 0.04);
}

.donut-center {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: grid;
  place-content: center;
  text-align: center;
}

.donut-center b {
  font-family: var(--font-display);
  font-size: 20px;
  line-height: 1;
}

.donut-center span {
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 4px;
}

.legend {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 7px;
}

.legend-row {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 11.5px;
  color: var(--muted);
}

.legend-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex: 0 0 auto;
  box-shadow: 0 0 8px currentColor;
}

.legend-row b {
  margin-left: auto;
  color: var(--text);
  font-size: 11px;
  font-weight: 700;
}

/* ------------------------------ workout rows ------------------------------ */

.workout-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 14px;
  margin-bottom: 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.028);
  text-align: left;
  color: var(--text);
  cursor: pointer;
  transition: background 0.18s ease;
}

.workout-row:active {
  background: rgba(255, 255, 255, 0.06);
}

.date-badge {
  width: 44px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 11px;
  display: grid;
  place-content: center;
  text-align: center;
  background: linear-gradient(160deg, rgba(var(--violet-rgb), 0.16), rgba(var(--cyan-rgb), 0.08));
  border: 1px solid rgba(var(--violet-rgb), 0.28);
}

.date-badge b {
  font-family: var(--font-display);
  font-size: 16px;
  line-height: 1;
}

.date-badge span {
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
  margin-top: 3px;
}

.wr-main {
  flex: 1;
  min-width: 0;
}

.wr-title {
  font-size: 13.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wr-meta {
  margin-top: 3px;
  display: flex;
  gap: 8px;
  font-size: 10.5px;
  color: var(--muted);
  flex-wrap: wrap;
}

.wr-meta i {
  font-style: normal;
  color: var(--muted-2);
}

.month-label {
  margin: 18px 0 8px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted-2);
}

/* ------------------------------ empty ------------------------------ */

.empty {
  padding: 34px 20px;
  text-align: center;
  border: 1px dashed rgba(var(--line-rgb), 0.2);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.02);
}

.empty-icon {
  width: 52px;
  height: 52px;
  margin: 0 auto 12px;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: var(--cyan);
  background: var(--cyan-soft);
  border: 1px solid rgba(var(--cyan-rgb), 0.25);
}

.empty-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
}

.empty h3 {
  font-size: 15px;
  margin-bottom: 6px;
}

.empty p {
  margin: 0 auto 16px;
  max-width: 260px;
  font-size: 12.5px;
  color: var(--muted);
}

/* ------------------------------ tabbar ------------------------------ */

.tabbar {
  position: fixed;
  z-index: 40;
  left: 50%;
  bottom: calc(10px + var(--safe-bottom));
  transform: translateX(-50%);
  width: calc(100% - 28px);
  max-width: 520px;
  display: grid;
  grid-template-columns: repeat(var(--tabs, 4), 1fr);
  gap: 4px;
  padding: 7px;
  border-radius: 22px;
  border: 1px solid rgba(var(--line-rgb), 0.16);
  background: color-mix(in srgb, var(--bg) 86%, transparent);
  backdrop-filter: blur(22px);
  -webkit-backdrop-filter: blur(22px);
  box-shadow: 0 18px 40px -12px rgba(0, 0, 0, 0.85), 0 0 0 1px rgba(var(--cyan-rgb), 0.04), 0 0 30px -10px rgba(var(--violet-rgb), 0.25);
}

.tab {
  position: relative;
  border: 0;
  background: transparent;
  color: var(--muted-2);
  font-family: var(--font-body);
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.02em;
  padding: 7px 2px 6px;
  border-radius: 15px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  cursor: pointer;
  transition: color 0.2s ease, background 0.2s ease;
}

.tab svg {
  width: 21px;
  height: 21px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
  transition: filter 0.2s ease;
}

.tab.active {
  color: var(--cyan);
  background: linear-gradient(180deg, rgba(var(--cyan-rgb), 0.1), rgba(var(--cyan-rgb), 0.02));
}

.tab.active svg {
  filter: drop-shadow(0 0 7px rgba(var(--cyan-rgb), 0.7));
}

.tab.active::after {
  content: '';
  position: absolute;
  top: 4px;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--lime);
  box-shadow: 0 0 8px var(--lime);
}

/* ------------------------------ workout screen ------------------------------ */

.app.workout .topbar,
.app.workout .tabbar {
  display: none;
}

.app.workout .view-root {
  padding-bottom: calc(32px + var(--safe-bottom));
}

.wk-screen {
  min-height: 100vh;
  padding-bottom: 28px;
}

.wk-top {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: calc(14px + env(safe-area-inset-top, 0px)) 16px 12px;
  background: linear-gradient(180deg, rgba(5, 6, 12, 0.96) 70%, rgba(5, 6, 12, 0));
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

.wk-top .btn-icon {
  width: 40px;
  min-height: 40px;
}

.wk-top .btn-finish {
  margin-left: auto;
}

.wk-heading {
  min-width: 0;
  flex: 1;
}

.wk-heading b {
  display: block;
  font-family: var(--font-display);
  font-size: 13px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.wk-clock {
  display: flex;
  align-items: center;
  gap: 5px;
  margin-top: 2px;
  font-size: 11px;
  font-weight: 700;
  color: var(--cyan);
  font-variant-numeric: tabular-nums;
}

.wk-clock svg {
  width: 12px;
  height: 12px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.wk-body {
  padding: 6px 16px 130px;
}

.wk-hint {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px 12px;
  margin-bottom: 12px;
  border-radius: 12px;
  font-size: 11.5px;
  color: var(--muted);
  border: 1px dashed rgba(var(--line-rgb), 0.2);
  background: rgba(255, 255, 255, 0.02);
}

.wk-hint b {
  color: var(--text);
}

.ex-block {
  margin-bottom: 12px;
  padding: 14px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(160deg, var(--card-bg-1), var(--card-bg-2));
}

.ex-block-head {
  display: flex;
  align-items: center;
  gap: 10px;
}

.ex-block-title {
  flex: 1;
  min-width: 0;
}

.ex-block-title b {
  display: block;
  font-size: 14px;
  font-weight: 800;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.ex-block-title span {
  font-size: 10.5px;
  color: var(--muted);
}

.ex-remove {
  border: 0;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted-2);
  width: 28px;
  height: 28px;
  border-radius: 9px;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.ex-remove svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.set-table {
  margin-top: 12px;
  display: grid;
  gap: 6px;
}

.set-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) minmax(0, 1fr) 42px;
  align-items: center;
  gap: 6px;
  font-size: 11px;
}

.set-row.head {
  color: var(--muted-2);
  font-weight: 800;
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 0 2px;
}

.set-row.head span:first-child {
  text-align: center;
}

.set-idx {
  font-family: var(--font-display);
  font-size: 11px;
  color: var(--muted);
  text-align: center;
}

.set-cell {
  width: 100%;
  min-width: 0;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  text-align: center;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
  -moz-appearance: textfield;
}

.set-cell::-webkit-outer-spin-button,
.set-cell::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.set-cell:focus {
  border-color: rgba(var(--cyan-rgb), 0.55);
  box-shadow: 0 0 0 2px rgba(var(--cyan-rgb), 0.12), 0 0 16px rgba(var(--cyan-rgb), 0.15);
}

.set-check {
  height: 38px;
  border-radius: 10px;
  border: 1px solid rgba(var(--lime-rgb), 0.3);
  background: rgba(var(--lime-rgb), 0.1);
  color: var(--lime);
  display: grid;
  place-items: center;
  cursor: pointer;
  transition: transform 0.12s ease, background 0.2s ease;
}

.set-check:active {
  transform: scale(0.92);
  background: rgba(var(--lime-rgb), 0.22);
}

.set-check svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.6;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.set-done {
  display: flex;
  align-items: center;
  gap: 4px;
  justify-content: center;
  height: 38px;
  border-radius: 10px;
  padding: 0 8px;
  font-size: 12px;
  font-weight: 700;
  color: var(--muted);
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--line);
  white-space: nowrap;
  overflow: hidden;
}

.set-done b {
  color: var(--text);
}

.set-done span {
  color: var(--muted-2);
  font-size: 10px;
}

.ex-add-set {
  width: 100%;
  margin-top: 8px;
  min-height: 40px;
  border-radius: 11px;
  border: 1px dashed rgba(var(--cyan-rgb), 0.3);
  background: rgba(var(--cyan-rgb), 0.05);
  color: var(--cyan);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.ex-add-set svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
}

.add-ex {
  width: 100%;
  min-height: 50px;
  border-radius: var(--radius-sm);
  border: 1px dashed rgba(var(--violet-rgb), 0.35);
  background: rgba(var(--violet-rgb), 0.06);
  color: #c4a8ff;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 800;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  margin-top: 4px;
}

.add-ex svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.wk-summary {
  display: flex;
  gap: 8px;
  margin-bottom: 14px;
}

.wk-summary .stat {
  flex: 1;
  padding: 11px 12px;
}

.wk-summary .stat-value {
  font-size: 17px;
}

/* ------------------------------ rest timer ------------------------------ */

.rest-card {
  position: fixed;
  z-index: 45;
  left: 50%;
  bottom: calc(14px + var(--safe-bottom));
  transform: translateX(-50%);
  width: calc(100% - 28px);
  max-width: 420px;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 14px;
  border-radius: 20px;
  border: 1px solid rgba(var(--cyan-rgb), 0.35);
  background: rgba(8, 11, 22, 0.94);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: 0 0 30px rgba(var(--cyan-rgb), 0.18), 0 20px 40px -15px rgba(0, 0, 0, 0.9);
  animation: timerIn 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

@keyframes timerIn {
  from {
    opacity: 0;
    transform: translate(-50%, 20px);
  }
  to {
    opacity: 1;
    transform: translate(-50%, 0);
  }
}

.rest-ring {
  position: relative;
  width: 58px;
  height: 58px;
  flex: 0 0 auto;
}

.rest-ring svg {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.rest-ring circle {
  fill: none;
  stroke-width: 4;
}

.rest-ring .track {
  stroke: rgba(255, 255, 255, 0.1);
}

.rest-ring .bar {
  stroke: var(--lime);
  stroke-linecap: round;
  filter: drop-shadow(0 0 6px rgba(var(--lime-rgb), 0.7));
  transition: stroke-dashoffset 0.3s linear;
}

.rest-ring b {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 13px;
  font-variant-numeric: tabular-nums;
}

.rest-info {
  flex: 1;
  min-width: 0;
}

.rest-info b {
  display: block;
  font-size: 12px;
  font-weight: 800;
}

.rest-info span {
  font-size: 10px;
  color: var(--muted);
}

.rest-actions {
  display: flex;
  gap: 6px;
}

.rest-actions button {
  height: 34px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 10.5px;
  font-weight: 800;
  cursor: pointer;
}

.rest-actions .skip {
  color: var(--cyan);
  border-color: rgba(var(--cyan-rgb), 0.3);
  background: rgba(var(--cyan-rgb), 0.08);
}

/* ------------------------------ sheet ------------------------------ */

.backdrop {
  position: fixed;
  inset: 0;
  z-index: 60;
  background: rgba(2, 3, 8, 0.66);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  opacity: 0;
  animation: backdropIn 0.2s ease forwards;
}

@keyframes backdropIn {
  to {
    opacity: 1;
  }
}

.sheet {
  position: fixed;
  z-index: 61;
  left: 50%;
  bottom: 0;
  transform: translate(-50%, 100%);
  width: 100%;
  max-width: 640px;
  max-height: 90vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-radius: 26px 26px 0 0;
  border: 1px solid rgba(var(--cyan-rgb), 0.16);
  border-bottom: 0;
  background: linear-gradient(175deg, var(--sheet-1) 0%, var(--bg) 60%);
  box-shadow: 0 -20px 60px -20px rgba(var(--cyan-rgb), 0.25), 0 -30px 80px rgba(0, 0, 0, 0.7);
  padding: 10px 18px calc(24px + var(--safe-bottom));
  animation: sheetUp 0.3s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

@keyframes sheetUp {
  to {
    transform: translate(-50%, 0);
  }
}

.sheet-grip {
  width: 38px;
  height: 4px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.16);
  margin: 0 auto 14px;
}

.sheet-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 14px;
}

.sheet-title {
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.2;
}

.sheet-sub {
  margin-top: 5px;
  font-size: 12px;
  color: var(--muted);
}

.sheet-close {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.sheet-close svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.sheet-body {
  display: grid;
  gap: 12px;
  min-width: 0;
}

.sheet-body > * {
  min-width: 0;
}

.sheet-actions {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}

.sheet-actions .btn {
  flex: 1;
}

.program-text-preview {
  margin: 0;
  padding: 16px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: 500 12.5px/1.7 "Manrope", ui-monospace, SFMono-Regular, Menlo, monospace;
  white-space: pre-wrap;
  word-break: break-word;
  overflow: auto;
  max-height: 52vh;
  -webkit-overflow-scrolling: touch;
}

.program-image-preview {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 18px;
  border: 1px solid var(--line);
  background: #08090c;
}

.program-image-preview.export-save-preview {
  max-height: 52vh;
  object-fit: contain;
  -webkit-touch-callout: default;
  user-select: auto;
}

.admin-user-row {
  display: flex;
  gap: 10px;
  align-items: center;
  padding: 12px;
  min-width: 0;
}

.admin-user-row .wr-main {
  flex: 1;
  min-width: 0;
}

.admin-user-row .wr-title {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  align-items: center;
}

.admin-user-row .wr-meta {
  flex-wrap: wrap;
}

.admin-user-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  align-items: flex-end;
  flex: 0 0 auto;
}

.admin-user-actions .btn {
  white-space: nowrap;
}

.admin-screen .segmented {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
}

.admin-screen .segmented button {
  flex: 1 1 calc(33.333% - 4px);
  min-width: 0;
  padding: 9px 6px;
  white-space: nowrap;
}

/* ------------------------------ forms ------------------------------ */

.field {
  display: grid;
  gap: 6px;
  min-width: 0;
}

.field-row > * {
  min-width: 0;
}

.field-row.diary-date-time-row {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  align-items: end;
  gap: 8px;
}

.field-row.diary-date-time-row.note-mode {
  grid-template-columns: 1fr;
}

.field-row.diary-date-time-row > .field,
.field-row.diary-date-time-row .date-input-wrap,
.field-row.diary-date-time-row .time-input-wrap,
.field-row.diary-date-time-row input {
  min-width: 0;
  max-width: 100%;
}

@media (max-width: 360px) {
  .field-row.diary-date-time-row {
    grid-template-columns: 1fr;
  }
}

.field > label {
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

.field input[type='text'],
.field input[type='password'],
.field input[type='date'],
.field input[type='time'],
.field input[type='url'],
.field input[type='number'],
.field input[type='search'],
.field textarea,
.field select {
  width: 100%;
  min-height: 44px;
  padding: 10px 13px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  outline: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.field textarea {
  min-height: 84px;
  resize: vertical;
}

.time-input-wrap,
.date-input-wrap {
  position: relative;
  width: 100%;
  min-width: 0;
}

.time-input-wrap input[type='time'],
.date-input-wrap input[type='date'] {
  display: block;
  width: 100%;
  max-width: 100%;
  min-width: 0;
  min-height: 44px;
  padding: 10px 13px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.2;
  text-align: left;
  direction: ltr;
  outline: none;
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
}

.time-input-wrap input[type='time']:focus,
.date-input-wrap input[type='date']:focus {
  border-color: rgba(var(--cyan-rgb), 0.5);
  box-shadow: 0 0 0 3px rgba(var(--cyan-rgb), 0.1);
}

.time-input-wrap input[type='time']::-webkit-date-and-time-value,
.date-input-wrap input[type='date']::-webkit-date-and-time-value {
  text-align: left;
}

.field input[type='time'] {
  box-sizing: border-box;
  -webkit-appearance: none;
  appearance: none;
}

.field input[type='time']::-webkit-calendar-picker-indicator {
  opacity: 0.72;
  cursor: pointer;
}


.field input:focus,
.field textarea:focus,
.field select:focus {
  border-color: rgba(var(--cyan-rgb), 0.5);
  box-shadow: 0 0 0 3px rgba(var(--cyan-rgb), 0.1);
}

.field-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.stepper {
  display: flex;
  align-items: center;
  gap: 10px;
}

.stepper button {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  font-size: 17px;
  font-weight: 700;
  cursor: pointer;
}

.stepper b {
  min-width: 24px;
  text-align: center;
  font-family: var(--font-display);
  font-size: 15px;
}

.switch {
  position: relative;
  width: 46px;
  height: 27px;
  flex: 0 0 auto;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.07);
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease;
}

.switch::after {
  content: '';
  position: absolute;
  top: 3px;
  left: 3px;
  width: 19px;
  height: 19px;
  border-radius: 50%;
  background: var(--muted);
  transition: transform 0.2s cubic-bezier(0.22, 1, 0.36, 1), background 0.2s ease;
}

.switch.on {
  background: rgba(var(--lime-rgb), 0.16);
  border-color: rgba(var(--lime-rgb), 0.45);
  box-shadow: 0 0 16px rgba(var(--lime-rgb), 0.18);
}

.switch.on::after {
  transform: translateX(19px);
  background: var(--lime);
  box-shadow: 0 0 10px rgba(var(--lime-rgb), 0.8);
}

.days {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 5px;
}

.day-toggle {
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--muted);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.15s ease;
}

.day-toggle.on {
  color: var(--cyan);
  border-color: rgba(var(--cyan-rgb), 0.45);
  background: var(--cyan-soft);
  box-shadow: 0 0 12px rgba(var(--cyan-rgb), 0.15);
}

.divider {
  height: 1px;
  background: var(--line);
  margin: 4px 0;
}

.note {
  padding: 13px;
  border-radius: 14px;
  border: 1px solid rgba(var(--violet-rgb), 0.22);
  background: linear-gradient(150deg, rgba(var(--violet-rgb), 0.1), rgba(var(--cyan-rgb), 0.04));
  font-size: 12.5px;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.note.danger-note {
  border-color: rgba(255, 107, 122, 0.42);
  background: linear-gradient(150deg, rgba(255, 107, 122, 0.13), rgba(255, 107, 122, 0.03));
}

.note.danger-note .note-head {
  color: var(--danger);
}

.admin-angry {
  text-align: center;
  padding: 22px 16px;
}

.admin-angry-text {
  font-family: var(--font-display);
  font-size: 24px;
  line-height: 1.2;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-transform: uppercase;
  color: var(--danger);
  text-shadow: 0 0 24px rgba(255, 107, 122, 0.35);
  animation: angry-shake 0.45s ease-in-out;
}

.admin-angry .small {
  margin-top: 10px;
  display: block;
}

@keyframes angry-shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-7px) rotate(-1deg); }
  40% { transform: translateX(7px) rotate(1deg); }
  60% { transform: translateX(-5px); }
  80% { transform: translateX(4px); }
}

.coach-leave-progress {
  height: 4px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
}

.coach-leave-progress > span {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--lime), var(--cyan));
  transition: width 0.25s linear;
}

.note-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: #b79aff;
}

.note-head button {
  border: 0;
  background: none;
  color: var(--muted-2);
  font-size: 10px;
  cursor: pointer;
  padding: 0;
}

.note-list {
  display: grid;
  gap: 8px;
}

.note-text {
  white-space: pre-wrap;
}

.note-image-btn {
  display: block;
  width: 100%;
  padding: 0;
  margin-top: 9px;
  border: 0;
  background: none;
  cursor: zoom-in;
  text-align: left;
}

.note-image {
  display: block;
  width: 100%;
  max-height: 420px;
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #05060a;
}

.note-image-full {
  display: block;
  width: 100%;
  max-height: 68vh;
  object-fit: contain;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: #05060a;
}

.note-image-preview {
  position: relative;
  margin-top: 10px;
}

.note-image-preview img {
  display: block;
  width: 100%;
  max-height: 220px;
  object-fit: contain;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: #05060a;
}

.note-image-remove {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 10px;
  background: rgba(6, 8, 14, 0.78);
  color: var(--text);
  cursor: pointer;
  backdrop-filter: blur(8px);
}

.note-image-remove svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.note-emoji-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}

.emoji-chip {
  width: 36px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.04);
  font-size: 17px;
  line-height: 1;
  cursor: pointer;
}

.emoji-chip:active {
  transform: scale(0.94);
  border-color: rgba(var(--cyan-rgb), 0.4);
}

.note-attach-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 8px;
}

.sheet.chat-full {
  top: 0;
  bottom: 0;
  height: 100vh;
  height: 100dvh;
  max-height: none;
  max-width: 100%;
  border: 0;
  border-radius: 0;
  overflow: hidden;
  padding: calc(10px + env(safe-area-inset-top)) 18px calc(12px + env(safe-area-inset-bottom));
  display: flex;
  flex-direction: column;
}

.sheet.chat-full .sheet-grip {
  display: none;
}

.sheet.chat-full .sheet-head {
  flex: 0 0 auto;
  margin-bottom: 10px;
}

.chat-sheet {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 0;
  flex: 1;
}

.sheet.chat-full .chat-list {
  flex: 1;
  max-height: none;
  min-height: 0;
}

.sheet.chat-full .chat-compose {
  flex: 0 0 auto;
}

.quick-last {
  display: grid;
  gap: 5px;
  margin-top: 12px;
  padding: 10px 12px;
  border: 1px solid rgba(var(--cyan-rgb), 0.18);
  border-radius: 13px;
  background: rgba(var(--cyan-rgb), 0.05);
}

.quick-last-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.quick-last-head span:last-child {
  color: var(--muted-2);
  font-size: 9px;
  letter-spacing: 0;
  text-transform: none;
}

.quick-last-text {
  overflow: hidden;
  color: var(--text);
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.quick-last-image {
  display: block;
  width: 100%;
  max-height: 190px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #05060a;
}

.chat-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 46vh;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 3px 2px 9px;
}

.chat-msg {
  align-self: flex-start;
  max-width: 86%;
  padding: 9px 11px 7px;
  border-radius: 14px;
  border: 1px solid rgba(var(--cyan-rgb), 0.18);
  background: rgba(255, 255, 255, 0.05);
  overflow-wrap: anywhere;
}

.chat-msg.out {
  align-self: flex-end;
  border-color: rgba(var(--lime-rgb), 0.28);
  background: linear-gradient(145deg, rgba(var(--lime-rgb), 0.16), rgba(var(--cyan-rgb), 0.08));
}

.chat-author {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cyan);
}

.mini-avatar {
  position: relative;
  width: 20px;
  height: 20px;
  flex: 0 0 auto;
  overflow: hidden;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, rgba(var(--cyan-rgb), 0.22), rgba(var(--violet-rgb), 0.22));
  border: 1px solid rgba(var(--cyan-rgb), 0.3);
  color: var(--text);
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0;
}

.chat-text {
  font-size: 13px;
  line-height: 1.45;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.chat-time {
  margin-top: 4px;
  font-size: 9px;
  color: var(--muted-2);
  text-align: right;
}

.chat-image-btn {
  display: block;
  width: 100%;
  padding: 0;
  margin-top: 6px;
  border: 0;
  background: none;
  cursor: zoom-in;
  text-align: left;
}

.chat-image {
  display: block;
  width: 100%;
  max-height: 260px;
  object-fit: contain;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: #05060a;
}

.chat-bubbles {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-top: 8px;
}

.chat-bubble-wrap {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.chat-bubble-wrap .chat-msg {
  width: 100%;
  max-width: 100%;
}

.chat-delete {
  align-self: flex-end;
  margin-top: 2px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--muted-2);
  font-size: 9px;
  cursor: pointer;
}

.chat-compose {
  display: grid;
  gap: 7px;
  padding-top: 9px;
  border-top: 1px solid var(--line);
}

.chat-compose .chat-emojis {
  margin-top: 0;
}

.chat-input-row {
  display: flex;
  align-items: flex-end;
  gap: 7px;
}

.chat-input-row textarea {
  flex: 1;
  width: 100%;
  min-height: 42px;
  max-height: 120px;
  padding: 10px 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  font-size: 13px;
  line-height: 1.4;
  resize: none;
  outline: none;
}

.chat-input-row textarea:focus {
  border-color: rgba(var(--cyan-rgb), 0.4);
  box-shadow: 0 0 0 2px rgba(var(--cyan-rgb), 0.08);
}

.chat-attach,
.chat-send-btn {
  flex: 0 0 auto;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  border-radius: 13px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  cursor: pointer;
}

.chat-attach svg,
.chat-send-btn svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.chat-send-btn {
  border: 0;
  color: #071014;
  background: linear-gradient(120deg, var(--lime), var(--cyan));
  box-shadow: 0 0 18px rgba(var(--lime-rgb), 0.22);
}

.chat-send-btn:disabled {
  opacity: 0.5;
}

.chat-empty {
  padding: 26px 12px;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

.chat-empty .empty-icon {
  margin: 0 auto 8px;
}

.image-overlay {
  position: fixed;
  inset: 0;
  z-index: 90;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(2, 3, 7, 0.94);
  backdrop-filter: blur(8px);
}

.image-overlay img {
  display: block;
  max-width: 100%;
  max-height: 86vh;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: 0 20px 70px rgba(0, 0, 0, 0.7);
}

.image-overlay-close {
  position: absolute;
  top: calc(14px + env(safe-area-inset-top));
  right: 14px;
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  background: rgba(10, 12, 18, 0.8);
  color: var(--text);
  cursor: pointer;
}

.image-overlay-close svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.install-hero {
  display: grid;
  justify-items: center;
  gap: 7px;
  padding: 20px 16px;
  text-align: center;
  border: 1px solid rgba(var(--lime-rgb), 0.28);
  border-radius: 16px;
  background: linear-gradient(145deg, rgba(var(--lime-rgb), 0.12), rgba(var(--cyan-rgb), 0.05));
}

.install-hero-icon {
  width: 52px;
  height: 52px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  color: #071014;
  background: linear-gradient(140deg, var(--lime), var(--cyan));
  box-shadow: 0 0 24px rgba(var(--lime-rgb), 0.25);
}

.install-hero-icon svg {
  width: 26px;
  height: 26px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.install-hero b {
  font-family: var(--font-display);
  font-size: 17px;
}

.install-hero span {
  max-width: 280px;
  font-size: 12px;
  line-height: 1.5;
  color: var(--muted);
}

.install-steps {
  display: grid;
  gap: 9px;
}

.install-step {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.035);
  font-size: 12.5px;
  line-height: 1.45;
}

.install-step > b {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  color: #071014;
  background: var(--lime);
  font-size: 11px;
}

.install-step span {
  padding-top: 2px;
}

.install-step span b {
  color: var(--text);
  font-weight: 800;
}

.install-link {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 8px;
  padding: 8px 8px 8px 12px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.04);
}

.install-link code {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 11px;
  color: var(--muted);
}

.install-link button {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 10px;
  background: rgba(var(--cyan-rgb), 0.12);
  color: var(--cyan);
  cursor: pointer;
}

.install-link button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.install-access {
  display: grid;
  gap: 8px;
  min-width: 0;
  padding: 12px;
  border: 1px solid rgba(var(--cyan-rgb), 0.22);
  border-radius: 15px;
  background: rgba(var(--cyan-rgb), 0.05);
}

.install-access-head {
  display: flex;
  align-items: center;
  gap: 7px;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--cyan);
}

.install-access-head svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.install-code {
  display: flex;
  min-width: 0;
  align-items: center;
  gap: 9px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.04);
}

.install-code span {
  flex: 1;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.install-code b {
  font-family: var(--font-display);
  font-size: 16px;
  letter-spacing: 0.08em;
  color: var(--lime);
}

.install-code button {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 9px;
  background: rgba(var(--lime-rgb), 0.12);
  color: var(--lime);
  cursor: pointer;
}

.install-code button svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.contact-card {
  margin-top: 10px;
  padding: 14px;
  border-color: rgba(var(--cyan-rgb), 0.22);
  background:
    radial-gradient(120% 130% at 100% 0%, rgba(var(--cyan-rgb), 0.1), transparent 58%),
    rgba(255, 255, 255, 0.035);
}

.contact-head {
  display: flex;
  align-items: center;
  gap: 12px;
}

.contact-head .coach-head-main {
  flex: 1;
  min-width: 0;
}

.contact-head .coach-head-main b {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-head .coach-head-main span {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contact-actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.contact-actions .btn {
  flex: 1;
}

.team-chat-card {
  border-color: rgba(var(--violet-rgb), 0.22);
  background:
    radial-gradient(120% 130% at 100% 0%, rgba(var(--violet-rgb), 0.1), transparent 58%),
    rgba(255, 255, 255, 0.035);
}

.current-program-card {
  border-color: rgba(var(--violet-rgb), 0.28);
  background:
    radial-gradient(120% 130% at 100% 0%, rgba(var(--violet-rgb), 0.12), transparent 58%),
    rgba(255, 255, 255, 0.035);
}

.assign-exercises-box {
  display: grid;
  gap: 10px;
}

.assign-exercise-list {
  display: grid;
  gap: 6px;
  max-height: 240px;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: rgba(255, 255, 255, 0.025);
}

.assign-ex {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 9px;
  border-radius: 9px;
  background: rgba(255, 255, 255, 0.035);
  font-size: 12px;
  cursor: pointer;
}

.assign-ex input {
  flex: 0 0 auto;
  accent-color: var(--lime);
}

.assign-ex span {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.assign-ex small {
  color: var(--muted-2);
  font-size: 9px;
  white-space: nowrap;
}

/* ------------------------------ coach ------------------------------ */

.coach-head {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  margin-bottom: 12px;
  border-radius: var(--radius);
  border: 1px solid rgba(var(--cyan-rgb), 0.25);
  background:
    radial-gradient(120% 120% at 90% 0%, rgba(var(--cyan-rgb), 0.14), transparent 55%),
    radial-gradient(90% 90% at 0% 100%, rgba(var(--violet-rgb), 0.16), transparent 60%),
    linear-gradient(160deg, rgba(18, 23, 44, 0.95), rgba(8, 10, 20, 0.96));
  box-shadow: 0 0 34px -14px rgba(var(--cyan-rgb), 0.4);
}

.coach-icon {
  width: 46px;
  height: 46px;
  flex: 0 0 auto;
  border-radius: 14px;
  display: grid;
  place-items: center;
  color: var(--cyan);
  background: rgba(var(--cyan-rgb), 0.1);
  border: 1px solid rgba(var(--cyan-rgb), 0.35);
  box-shadow: inset 0 0 18px rgba(var(--cyan-rgb), 0.12);
}

.coach-icon svg {
  width: 23px;
  height: 23px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.coach-head-main {
  flex: 1;
  min-width: 0;
}

.coach-head-main b {
  display: block;
  font-family: var(--font-display);
  font-size: 15px;
  letter-spacing: -0.02em;
}

.coach-head-main span {
  font-size: 11px;
  color: var(--muted);
}

.code-box {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px dashed rgba(var(--cyan-rgb), 0.35);
  background: rgba(var(--cyan-rgb), 0.05);
}

.code-box code {
  flex: 1;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 700;
  letter-spacing: 0.16em;
  color: var(--cyan);
  text-shadow: 0 0 16px rgba(var(--cyan-rgb), 0.45);
}

.code-box button {
  border: 0;
  background: rgba(var(--cyan-rgb), 0.12);
  color: var(--cyan);
  width: 34px;
  height: 34px;
  border-radius: 10px;
  display: grid;
  place-items: center;
  cursor: pointer;
}

.code-box button svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.athlete-card {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 13px 14px;
  margin-bottom: 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: linear-gradient(150deg, var(--card-bg-1), var(--card-bg-2));
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, transform 0.15s ease;
}

.athlete-card:active {
  transform: scale(0.985);
}

.athlete-card.attention {
  border-color: rgba(255, 84, 112, 0.35);
  box-shadow: inset 0 0 22px rgba(255, 84, 112, 0.05);
}

.athlete-avatar {
  position: relative;
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  border-radius: 50%;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  color: #dffcff;
  background: linear-gradient(145deg, rgba(var(--cyan-rgb), 0.22), rgba(var(--violet-rgb), 0.22));
  border: 1px solid rgba(var(--cyan-rgb), 0.3);
}

.athlete-avatar .warn {
  position: absolute;
  right: -1px;
  top: -1px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--danger);
  border: 2px solid #0b0e1a;
  box-shadow: 0 0 10px rgba(255, 84, 112, 0.9);
  animation: pulse 2s infinite;
}

@keyframes pulse {
  0%,
  100% {
    opacity: 1;
  }
  50% {
    opacity: 0.45;
  }
}

.athlete-info {
  flex: 1;
  min-width: 0;
}

.athlete-info b {
  display: block;
  font-size: 13.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.athlete-meta {
  margin-top: 3px;
  display: flex;
  gap: 7px;
  flex-wrap: wrap;
  font-size: 10.5px;
  color: var(--muted);
}

.athlete-meta i {
  font-style: normal;
  color: var(--muted-2);
}

.mini-bars {
  width: 52px;
  flex: 0 0 auto;
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 26px;
}

.mini-bars i {
  flex: 1;
  min-height: 2px;
  border-radius: 2px;
  background: linear-gradient(180deg, var(--cyan), rgba(var(--cyan-rgb), 0.15));
  box-shadow: 0 0 6px rgba(var(--cyan-rgb), 0.3);
}

.mini-bars i.zero {
  background: rgba(255, 255, 255, 0.08);
  box-shadow: none;
}

.detail-head {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 14px;
}

.detail-head .back {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.05);
  color: var(--text);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex: 0 0 auto;
}

.detail-head .back svg {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.detail-title {
  flex: 1;
  min-width: 0;
}

.detail-title b {
  display: block;
  font-family: var(--font-display);
  font-size: 17px;
  letter-spacing: -0.02em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.detail-title span {
  font-size: 11px;
  color: var(--muted);
}

.insight {
  display: flex;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 14px;
  border: 1px solid rgba(var(--lime-rgb), 0.22);
  background: rgba(var(--lime-rgb), 0.06);
  font-size: 12px;
  color: var(--muted);
  line-height: 1.45;
}

.insight svg {
  width: 17px;
  height: 17px;
  flex: 0 0 auto;
  fill: none;
  stroke: var(--lime);
  stroke-width: 1.9;
  stroke-linecap: round;
  margin-top: 1px;
}

.insight b {
  color: var(--text);
}

.tech-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 9px;
  counter-reset: tech;
}

.tech-list li {
  position: relative;
  padding-left: 31px;
  font-size: 12.5px;
  line-height: 1.5;
  color: var(--muted);
  counter-increment: tech;
}

.ex-description {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-size: 12.5px;
  line-height: 1.55;
  color: var(--muted);
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.025);
}

.tech-list li::before {
  content: counter(tech);
  position: absolute;
  left: 0;
  top: 0;
  width: 21px;
  height: 21px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  font-size: 10px;
  font-weight: 800;
  color: var(--lime);
  background: rgba(var(--lime-rgb), 0.08);
  border: 1px solid rgba(var(--lime-rgb), 0.25);
  box-shadow: 0 0 12px rgba(var(--lime-rgb), 0.1);
}

.wk-detail {
  border: 1px solid var(--line);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.025);
  overflow: hidden;
  margin-bottom: 8px;
}

.wk-detail summary {
  list-style: none;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 11px 13px;
  cursor: pointer;
}

.wk-detail summary::-webkit-details-marker {
  display: none;
}

.wk-detail summary .chev {
  margin-left: auto;
  color: var(--muted-2);
  transition: transform 0.2s ease;
}

.wk-detail[open] summary .chev {
  transform: rotate(90deg);
}

.wk-detail summary .chev svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
}

.wk-detail-body {
  padding: 0 13px 12px;
  font-size: 11.5px;
  color: var(--muted);
  display: grid;
  gap: 6px;
}

.wk-detail-body .line {
  display: flex;
  justify-content: space-between;
  gap: 10px;
}

.wk-detail-body .line b {
  color: var(--text);
  font-weight: 600;
}

.offline-note {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 11px 13px;
  border-radius: 12px;
  border: 1px solid rgba(255, 200, 90, 0.25);
  background: rgba(255, 200, 90, 0.07);
  color: #e8c98a;
  font-size: 11.5px;
  line-height: 1.45;
}

.offline-note svg {
  width: 15px;
  height: 15px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  margin-top: 1px;
}

/* ------------------------------ toast ------------------------------ */

.toast {
  position: fixed;
  z-index: 90;
  left: 50%;
  bottom: calc(92px + var(--safe-bottom));
  transform: translate(-50%, 14px);
  max-width: calc(100% - 40px);
  padding: 11px 16px;
  border-radius: 13px;
  border: 1px solid rgba(var(--cyan-rgb), 0.35);
  background: rgba(8, 11, 22, 0.96);
  color: var(--text);
  font-size: 12.5px;
  font-weight: 600;
  box-shadow: 0 0 26px rgba(var(--cyan-rgb), 0.18), 0 16px 30px -12px rgba(0, 0, 0, 0.8);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.22s ease, transform 0.22s ease;
  text-align: center;
  line-height: 1.35;
}

.toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.quote-card {
  position: relative;
  margin-top: 16px;
  padding: 16px 16px 14px 20px;
  overflow: hidden;
  border-color: rgba(var(--violet-rgb), 0.22);
  background:
    radial-gradient(120% 140% at 100% 0%, rgba(var(--violet-rgb), 0.12), transparent 60%),
    linear-gradient(145deg, rgba(255, 255, 255, 0.045), rgba(255, 255, 255, 0.02));
}

.quote-mark {
  position: absolute;
  top: -18px;
  left: 10px;
  color: rgba(var(--violet-rgb), 0.22);
  font-family: Georgia, serif;
  font-size: 76px;
  line-height: 1;
  pointer-events: none;
}

.quote-text {
  position: relative;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--text);
}

.quote-author {
  margin-top: 9px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--violet);
}

.admin-card-codes {
  display: flex;
  flex-wrap: wrap;
  gap: 5px 10px;
  margin-top: 6px;
  font-size: 9px;
  color: var(--muted-2);
}

.admin-card-codes code {
  color: var(--cyan);
  font-size: 10px;
  letter-spacing: 0.06em;
}

.admin-code-block {
  display: grid;
  gap: 5px;
  margin-top: 10px;
}

.admin-code-block .code-box {
  margin: 0;
}

/* ------------------------------ misc ------------------------------ */

.avatar-edit-badge {
  position: absolute;
  right: -4px;
  bottom: -4px;
  width: 22px;
  height: 22px;
  display: grid;
  place-items: center;
  border-radius: 8px;
  border: 2px solid var(--bg);
  background: linear-gradient(140deg, var(--lime), var(--cyan));
  color: #06110c;
  box-shadow: 0 0 12px rgba(var(--cyan-rgb), 0.35);
  pointer-events: none;
}

.avatar-edit-badge svg {
  width: 12px;
  height: 12px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.profile-hero {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px;
  border-radius: var(--radius);
  border: 1px solid var(--line);
  background: linear-gradient(150deg, var(--card-bg-1), var(--card-bg-2));
  margin-bottom: 12px;
}

.profile-avatar-wrap {
  position: relative;
  width: 56px;
  height: 56px;
  flex: 0 0 auto;
}

.profile-avatar-button {
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  cursor: pointer;
  font: inherit;
}

.profile-avatar {
  width: 56px;
  height: 56px;
  overflow: hidden;
  border-radius: 18px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 20px;
  font-weight: 800;
  color: #06110c;
  background: linear-gradient(140deg, var(--lime), var(--cyan));
  box-shadow: 0 0 24px rgba(var(--cyan-rgb), 0.3);
}

.profile-hero > div:last-child {
  flex: 1;
  min-width: 0;
}

.profile-hero b {
  display: block;
  overflow-wrap: anywhere;
  font-family: var(--font-display);
  font-size: 16px;
}

.profile-hero span {
  font-size: 11.5px;
  color: var(--muted);
}

.row-link {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 13px 2px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: none;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 600;
  text-align: left;
  cursor: pointer;
}

.row-link:last-child {
  border-bottom: 0;
}

.row-link svg {
  width: 17px;
  height: 17px;
  fill: none;
  stroke: var(--cyan);
  stroke-width: 1.9;
  stroke-linecap: round;
}

.row-link .arrow {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-left: auto;
  color: var(--muted-2);
  font-size: 10.5px;
  font-weight: 700;
  line-height: 1;
  white-space: nowrap;
}

.row-link .arrow svg {
  stroke: currentColor;
  width: 14px;
  height: 14px;
}

.small {
  font-size: 11px;
  color: var(--muted);
  line-height: 1.5;
}

.center {
  text-align: center;
}

.stack-8 {
  display: grid;
  gap: 8px;
}

.stack-12 {
  display: grid;
  gap: 12px;
}

.mt-12 {
  margin-top: 12px;
}

.mt-16 {
  margin-top: 16px;
}

.hidden {
  display: none !important;
}


/* ------------------------------ календарь планов ------------------------------ */

.calendar-card {
  padding: 14px;
  margin-bottom: 14px;
}

.cal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.cal-title {
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.cal-nav {
  display: flex;
  gap: 6px;
}

.cal-nav button {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.cal-nav button:active {
  color: var(--cyan);
  border-color: rgba(var(--cyan-rgb), 0.4);
}

.cal-nav svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.cal-nav button.prev svg {
  transform: rotate(180deg);
}

.cal-dow {
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  gap: 4px;
  margin-bottom: 4px;
}

.cal-dow span {
  text-align: center;
  font-size: 9px;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--muted-2);
}

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

.cal-cell {
  position: relative;
  aspect-ratio: 1 / 1;
  min-height: 38px;
  border-radius: 11px;
  border: 1px solid transparent;
  background: transparent;
  color: var(--text);
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 600;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  cursor: pointer;
  transition: background 0.15s ease, border-color 0.15s ease;
}

.cal-cell.other {
  opacity: 0.25;
  pointer-events: none;
}

.cal-cell.today {
  border-color: rgba(var(--cyan-rgb), 0.35);
  background: rgba(var(--cyan-rgb), 0.05);
}

.cal-cell.selected {
  background: linear-gradient(140deg, var(--team-accent), var(--cyan));
  border-color: rgba(255, 255, 255, 0.35);
  color: #04110b;
  font-weight: 800;
  box-shadow: 0 0 18px rgba(var(--cyan-rgb), 0.25);
}

.cal-cell.selected .cal-dot {
  background: #04110b;
  box-shadow: none;
}

.cal-dots {
  display: flex;
  gap: 2px;
  height: 4px;
  align-items: center;
}

.cal-dot {
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--team-accent);
  box-shadow: 0 0 6px var(--team-accent);
}

.cal-dot.team {
  background: var(--cyan);
  box-shadow: 0 0 6px var(--cyan);
}

.cal-cell.workout-day:not(.selected) {
  background: rgba(var(--lime-rgb), 0.07);
}

.cal-cell.workout-day .cal-dot {
  width: 6px;
  height: 6px;
  box-shadow: 0 0 8px var(--lime);
}

.calendar-legend {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px;
  margin-left: 50%;
  transform: translateX(-50%);
  margin-top: -4px;
  color: var(--muted-2);
}

.cal-cell.diary-day:not(.selected) {
  background: rgba(var(--cyan-rgb), 0.045);
}

.cal-dot.task {
  background: var(--pink);
  box-shadow: 0 0 6px var(--pink);
}

.cal-dot.plan {
  background: var(--violet);
  box-shadow: 0 0 6px var(--violet);
}

.diary-plan-card {
  padding: 12px;
  margin-bottom: 9px;
}

button.diary-plan-card {
  width: 100%;
  color: inherit;
  font-family: var(--font-body);
  text-align: left;
  cursor: pointer;
}

.diary-completed-card .plan-icon.done {
  color: var(--lime);
  border-color: rgba(var(--lime-rgb), 0.3);
  background: rgba(var(--lime-rgb), 0.08);
}

.diary-subhead {
  margin: 12px 0 7px;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-2);
}

.missed-alert {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 10px;
}

.missed-alert-main {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.missed-alert .coach-icon {
  color: var(--danger);
  border-color: rgba(255, 107, 122, 0.35);
  background: rgba(255, 107, 122, 0.08);
}

.missed-alert .wr-main {
  min-width: 0;
}

.missed-alert .wr-title {
  color: var(--text);
}

.diary-week-card {
  padding: 6px 13px;
}

.diary-week-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 9px 0;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.diary-week-row:last-child {
  border-bottom: 0;
}

.diary-week-row.selected {
  background: rgba(var(--cyan-rgb), 0.05);
}

.diary-week-day {
  width: 40px;
  flex: 0 0 40px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-size: 10px;
  font-weight: 800;
  color: var(--cyan);
  text-transform: uppercase;
}

.diary-week-day small {
  font-size: 12px;
  color: var(--text);
  text-transform: none;
}

.diary-week-row .wr-main b {
  display: block;
  font-size: 13px;
  line-height: 1.35;
}

.diary-week-row .wr-main small {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--muted-2);
}

.diary-quarter-month {
  padding: 13px;
  margin-bottom: 9px;
}

.diary-quarter-month .field-row b {
  font-size: 14px;
}

.diary-plan-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 10px;
}

.diary-plan-chips button {
  display: inline-flex;
  flex-direction: column;
  gap: 2px;
  max-width: 100%;
  padding: 6px 9px;
  border-radius: 10px;
  border: 1px solid rgba(var(--cyan-rgb), 0.22);
  background: rgba(var(--cyan-rgb), 0.06);
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.diary-plan-chips b {
  font-size: 9px;
  color: var(--cyan);
  text-transform: uppercase;
}

.diary-plan-chips span {
  font-size: 11px;
  overflow-wrap: anywhere;
}

.diary-month-nav {
  display: flex;
  gap: 4px;
}

.diary-month-nav button {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.diary-month-nav button:first-child svg {
  transform: rotate(180deg);
}

.diary-month-nav svg {
  width: 15px;
  height: 15px;
}

.diary-plan-card .plan-icon {
  flex: 0 0 auto;
}

.diary-calendar .cal-cell {
  min-width: 0;
  min-height: 0;
  padding: 3px 0 2px;
  justify-content: flex-start;
  gap: 0;
}

.diary-calendar .cal-day {
  position: relative;
  z-index: 1;
  line-height: 1.15;
}

.diary-calendar .cal-dots {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 1px;
  height: 13px;
  min-height: 0;
  line-height: 0;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.diary-calendar .cal-dot {
  width: 4px;
  height: 4px;
}

.diary-calendar .cal-task-count {
  min-width: 13px;
  height: 13px;
  padding: 0 2px;
  border-radius: 7px;
  display: inline-grid;
  place-items: center;
  background: var(--pink);
  color: #1a0610;
  font-size: 8px;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 0 8px rgba(var(--pink-rgb), 0.45);
}

.diary-calendar .cal-cell.selected .cal-task-count {
  background: #04110b;
  color: var(--pink);
  box-shadow: none;
}

.diary-calendar .cal-cell.selected .cal-dot {
  width: 5px;
  height: 5px;
}

.calendar-legend .cal-task-count {
  box-shadow: none;
}

.calendar-legend .legend-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  white-space: nowrap;
}

.cal-cell.selected,
.cal-cell.selected.workout-day,
.cal-cell.selected.diary-day {
  background: linear-gradient(140deg, var(--team-accent), var(--cyan));
  border-color: rgba(255, 255, 255, 0.35);
  color: #04110b;
  font-weight: 800;
  box-shadow: 0 0 18px rgba(var(--cyan-rgb), 0.25);
}

.diary-entry {
  padding: 13px;
  margin-bottom: 9px;
}

button.diary-entry-button {
  width: 100%;
  color: inherit;
  font-family: var(--font-body);
  text-align: left;
  cursor: pointer;
}

.diary-entry.important {
  border-color: rgba(var(--lime-rgb), 0.3);
  background: linear-gradient(145deg, rgba(var(--lime-rgb), 0.06), var(--card));
}

.diary-entry.done .diary-entry-title {
  opacity: 0.55;
  text-decoration: line-through;
}

.diary-entry-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.diary-entry-row .wr-main {
  min-width: 0;
  flex: 1;
}

.diary-entry-title {
  font-size: 14px;
  font-weight: 800;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.diary-entry-text {
  margin-top: 4px;
  color: var(--muted);
  font-size: 12.5px;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.diary-check,
.diary-note-icon {
  width: 32px;
  height: 32px;
  flex: 0 0 32px;
  border-radius: 50%;
  display: grid;
  place-items: center;
}

.diary-check {
  border: 1.5px solid rgba(var(--lime-rgb), 0.35);
  background: rgba(var(--lime-rgb), 0.06);
  color: var(--lime);
  cursor: pointer;
}

.diary-check svg {
  width: 16px;
  height: 16px;
}

.diary-check.on {
  background: linear-gradient(140deg, var(--lime), var(--cyan));
  border-color: transparent;
  color: #04120c;
}

.diary-note-icon {
  background: rgba(var(--cyan-rgb), 0.09);
  border: 1px solid rgba(var(--cyan-rgb), 0.22);
  color: var(--cyan);
}

.diary-note-icon svg {
  width: 15px;
  height: 15px;
}

.diary-task-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 11px 3px;
  border: 0;
  border-bottom: 1px solid var(--line);
  background: transparent;
  color: inherit;
  text-align: left;
  cursor: pointer;
}

.diary-task-row:last-child {
  border-bottom: 0;
}

.diary-task-date {
  width: 40px;
  flex: 0 0 40px;
  display: grid;
  place-items: center;
  padding: 5px 0;
  border-radius: 10px;
  background: rgba(var(--cyan-rgb), 0.08);
  color: var(--cyan);
  font-weight: 800;
  line-height: 1.1;
}

.diary-task-date small {
  font-size: 9px;
  text-transform: uppercase;
  color: var(--muted-2);
}

.diary-task-row .wr-main b {
  display: block;
  font-size: 14px;
  line-height: 1.35;
}

.diary-task-row .wr-main small {
  display: block;
  margin-top: 2px;
  font-size: 10.5px;
  color: var(--muted-2);
}

.diary-task-row.overdue .diary-task-date {
  background: rgba(255, 107, 122, 0.1);
  color: var(--danger);
}

.diary-task-row.overdue .wr-main small {
  color: var(--danger);
}

.cal-dot.done {
  background: var(--lime);
  box-shadow: 0 0 6px var(--lime);
}

.plan-filter {
  width: 100%;
  min-height: 42px;
  margin-bottom: 12px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
}

.plan-card {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 13px 14px;
  margin-bottom: 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--line);
  background: linear-gradient(150deg, var(--card-bg-1), var(--card-bg-2));
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, transform 0.15s ease;
}

.plan-card:active {
  transform: scale(0.985);
}

.plan-icon {
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 12px;
  display: grid;
  place-items: center;
  color: var(--cyan);
  background: rgba(var(--cyan-rgb), 0.1);
  border: 1px solid rgba(var(--cyan-rgb), 0.28);
}

.plan-icon.done {
  color: #06110c;
  background: linear-gradient(140deg, var(--lime), var(--cyan));
  border-color: rgba(255, 255, 255, 0.25);
  box-shadow: 0 0 18px rgba(var(--lime-rgb), 0.25);
}

.plan-icon svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.plan-status {
  flex: 0 0 auto;
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-2);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 4px 8px;
}

.plan-status.done {
  color: var(--lime);
  border-color: rgba(var(--lime-rgb), 0.3);
  background: rgba(var(--lime-rgb), 0.07);
}

.calendar-actions {
  display: flex;
  gap: 8px;
  margin-top: 4px;
}

.calendar-actions .btn {
  flex: 1;
}

/* ------------------------------ конструктор ------------------------------ */

.editor-screen .wk-body {
  padding: 6px 16px 40px;
}

.editor-block {
  padding: 14px;
  margin-bottom: 12px;
  display: grid;
  gap: 12px;
}

.plan-ex {
  padding: 14px;
  margin-bottom: 10px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: linear-gradient(160deg, var(--card-bg-1), var(--card-bg-2));
  display: grid;
  gap: 10px;
}

.plan-ex-head {
  display: flex;
  align-items: center;
  gap: 8px;
}

.plan-ex-name {
  flex: 1;
  min-width: 0;
  height: 42px;
  padding: 0 12px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  outline: none;
}

.plan-ex-name:focus {
  border-color: rgba(var(--cyan-rgb), 0.5);
  box-shadow: 0 0 0 3px rgba(var(--cyan-rgb), 0.1);
}

.plan-ex-group {
  display: flex;
  align-items: center;
  gap: 8px;
}

.plan-ex-group select {
  flex: 1;
  min-width: 0;
  height: 36px;
  padding: 0 10px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 12px;
  outline: none;
}

.plan-set-head {
  display: grid;
  grid-template-columns: 24px 1fr 1fr 30px;
  gap: 6px;
  font-size: 8.5px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-2);
  padding: 0 2px;
}

.plan-set-head span:first-child {
  text-align: center;
}

.plan-set-row {
  display: grid;
  grid-template-columns: 24px minmax(0, 1fr) minmax(0, 1fr) 30px;
  gap: 6px;
  align-items: center;
  margin-top: 5px;
}

.plan-set-row input {
  width: 100%;
  -moz-appearance: textfield;
  min-width: 0;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 700;
  text-align: center;
  outline: none;
}

.plan-set-row input::-webkit-outer-spin-button,
.plan-set-row input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

.plan-set-row input:focus {
  border-color: rgba(var(--cyan-rgb), 0.5);
  box-shadow: 0 0 0 2px rgba(var(--cyan-rgb), 0.12);
}

.editor-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 14px;
}

.editor-actions .btn {
  flex: 1;
  min-width: 120px;
}

/* ------------------------------ библиотека ------------------------------ */

.library-card {
  padding: 16px;
  margin-bottom: 12px;
}

.library-card h3 {
  font-size: 14px;
  letter-spacing: -0.01em;
}

.library-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  border-bottom: 1px solid var(--line);
}

.library-row:last-child {
  border-bottom: 0;
}

.program-numbers {
  display: flex;
  gap: 5px;
  flex: 0 0 auto;
}

.program-numbers label {
  display: grid;
  gap: 2px;
  font-size: 8px;
  font-weight: 700;
  color: var(--muted-2);
  text-align: center;
}

.program-numbers input {
  width: 48px;
  height: 34px;
  padding: 0 4px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  font-size: 11px;
  text-align: center;
  outline: none;
}

.library-row .wr-main {
  flex: 1;
  min-width: 0;
}

.lib-input,
.lib-select {
  height: 42px;
  min-width: 0;
  padding: 0 12px;
  border-radius: 11px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.035);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 14px;
  outline: none;
}

.lib-input {
  flex: 1;
}

.lib-select {
  flex: 0 1 130px;
}

.lib-input:focus,
.lib-select:focus {
  border-color: rgba(var(--cyan-rgb), 0.5);
}

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

.swatch {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid transparent;
  cursor: pointer;
  box-shadow: 0 0 14px currentColor;
  transition: transform 0.15s ease, border-color 0.15s ease;
}

.swatch:active {
  transform: scale(0.92);
}

.swatch.active {
  border-color: #fff;
  transform: scale(1.06);
}

.lib-group-chip {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin: 4px 6px 4px 0;
  padding: 6px 10px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  font-size: 11px;
  font-weight: 700;
  color: var(--text);
}

.lib-group-chip .legend-dot {
  width: 7px;
  height: 7px;
}

.lib-group-chip button {
  border: 0;
  background: none;
  color: var(--muted-2);
  font-size: 13px;
  cursor: pointer;
  padding: 0;
  line-height: 1;
}

.plan-note-box {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(var(--violet-rgb), 0.25);
  background: rgba(var(--violet-rgb), 0.07);
  font-size: 12.5px;
  color: var(--muted);
  line-height: 1.45;
}

.plan-note-box b {
  color: var(--text);
}

.plan-note-box code {
  color: var(--cyan);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 10.5px;
  overflow-wrap: anywhere;
}

/* сегменты внутри кабинета тренера */
.coach-seg {
  margin-bottom: 16px;
}

.coach-seg button {
  font-size: 11px;
}


/* ------------------------------ питание ------------------------------ */

.day-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 12px;
  margin-bottom: 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
}

.day-nav .nav-btn {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.04);
  color: var(--muted);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.day-nav .nav-btn.prev svg {
  transform: rotate(180deg);
}

.day-nav .nav-btn svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
}

.day-nav .day-label {
  flex: 1;
  text-align: center;
  font-size: 12px;
  font-weight: 800;
}

.day-nav .day-label span {
  display: block;
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted-2);
  margin-top: 2px;
}

.kcal-hero {
  padding: 16px;
  margin-bottom: 12px;
}

.kcal-top {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 14px;
}

.kcal-main {
  flex: 1;
  min-width: 0;
}

.kcal-big {
  font-family: var(--font-display);
  font-size: 30px;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1.1;
  margin-top: 2px;
}

.kcal-big span {
  font-size: 15px;
  color: var(--muted-2);
}

.kcal-icon {
  width: 52px;
  height: 52px;
  flex: 0 0 auto;
  border-radius: 16px;
  display: grid;
  place-items: center;
  color: var(--lime);
  background: var(--lime-soft);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow: 0 0 20px var(--lime-soft);
}

.kcal-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.9;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.macro-list {
  display: grid;
  gap: 9px;
}

.macro-row {
  display: grid;
  grid-template-columns: 18px 1fr auto;
  align-items: center;
  gap: 9px;
  font-size: 11px;
}

.macro-letter {
  width: 18px;
  height: 18px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  font-size: 9px;
  font-weight: 800;
  color: #051014;
  background: var(--macro-color, var(--cyan));
}

.macro-track {
  height: 6px;
  border-radius: 99px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.macro-fill {
  height: 100%;
  border-radius: 99px;
  background: var(--macro-color, var(--cyan));
  box-shadow: 0 0 10px var(--macro-color, var(--cyan));
  transition: width 0.4s ease;
}

.macro-value {
  font-variant-numeric: tabular-nums;
  color: var(--muted);
  font-weight: 700;
  white-space: nowrap;
}

.macro-value b {
  color: var(--text);
}

.water-row {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  padding-top: 13px;
  border-top: 1px solid var(--line);
}

.water-info {
  flex: 1;
  min-width: 0;
}

.water-info b {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  font-weight: 800;
}

.water-info b svg {
  width: 14px;
  height: 14px;
  fill: none;
  stroke: var(--cyan);
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.water-info span {
  font-size: 10.5px;
  color: var(--muted);
}

.water-actions {
  display: flex;
  gap: 6px;
}

.water-actions button {
  height: 34px;
  min-width: 34px;
  padding: 0 9px;
  border-radius: 10px;
  border: 1px solid rgba(var(--cyan-rgb), 0.3);
  background: rgba(var(--cyan-rgb), 0.08);
  color: var(--cyan);
  font-family: var(--font-body);
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
}

.meal-card {
  padding: 14px;
  margin-bottom: 10px;
}

.meal-head {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 8px;
}

.meal-head .meal-title {
  flex: 1;
  min-width: 0;
}

.meal-head .meal-title b {
  display: block;
  font-size: 13px;
  font-weight: 800;
}

.meal-head .meal-title span {
  font-size: 10.5px;
  color: var(--muted);
}

.meal-add {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  border: 1px solid rgba(var(--cyan-rgb), 0.35);
  background: rgba(var(--cyan-rgb), 0.08);
  color: var(--cyan);
  display: grid;
  place-items: center;
  cursor: pointer;
}

.meal-add svg {
  width: 15px;
  height: 15px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
}

.food-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.food-row:first-child {
  border-top: 0;
}

.food-main {
  flex: 1;
  min-width: 0;
}

.food-name {
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.food-sub {
  font-size: 10px;
  color: var(--muted);
  margin-top: 1px;
}

.food-kcal {
  font-size: 12px;
  font-weight: 800;
  color: var(--lime);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.food-del {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  border: 0;
  background: rgba(255, 255, 255, 0.05);
  color: var(--muted-2);
  display: grid;
  place-items: center;
  cursor: pointer;
  flex: 0 0 auto;
}

.food-del svg {
  width: 12px;
  height: 12px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.2;
  stroke-linecap: round;
}

.food-empty {
  padding: 10px 0 2px;
  font-size: 11px;
  color: var(--muted-2);
}

.integration {
  padding: 15px;
  margin-bottom: 12px;
}

.integration-head {
  display: flex;
  align-items: center;
  gap: 11px;
}

.integration-logo {
  width: 38px;
  height: 38px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  font-family: var(--font-display);
  font-size: 15px;
  font-weight: 800;
  color: #061018;
  background: linear-gradient(140deg, #ffd166, #ff8a5c);
  box-shadow: 0 0 18px rgba(255, 180, 90, 0.25);
}

.integration-logo svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: #06110c;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.integration-info {
  flex: 1;
  min-width: 0;
}

.integration-info b {
  display: block;
  font-size: 13px;
}

.integration-info span {
  font-size: 10.5px;
  color: var(--muted);
  line-height: 1.4;
  display: block;
  margin-top: 2px;
}

.integration-actions {
  display: flex;
  gap: 7px;
  margin-top: 11px;
}

.integration-actions .btn {
  flex: 1;
}

.result-list {
  display: grid;
  gap: 7px;
}

.result-row {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  text-align: left;
  cursor: pointer;
}

.result-row:active {
  border-color: rgba(var(--cyan-rgb), 0.4);
}

.result-main {
  flex: 1;
  min-width: 0;
}

.result-name {
  font-size: 12.5px;
  font-weight: 700;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.result-sub {
  font-size: 10px;
  color: var(--muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.result-kcal {
  font-size: 11px;
  font-weight: 800;
  color: var(--cyan);
  white-space: nowrap;
}

.selected-food {
  padding: 13px;
  border-radius: 14px;
  border: 1px solid rgba(var(--cyan-rgb), 0.3);
  background: rgba(var(--cyan-rgb), 0.06);
  display: grid;
  gap: 10px;
}

.selected-food b {
  font-size: 13px;
}

.macro-preview {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 10.5px;
  color: var(--muted);
}

.macro-preview span {
  padding: 4px 8px;
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--line);
}

.macro-preview b {
  font-size: 10.5px;
  color: var(--text);
}

.admin-screen .wk-body {
  padding: 6px 16px 44px;
}

.code-big {
  font-family: var(--font-display);
  font-size: 21px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--cyan);
  text-shadow: 0 0 18px rgba(102, 227, 255, 0.3);
  margin-top: 4px;
}

.scanner-shell {
  position: relative;
}

.scanner-wrap {
  position: relative;
  width: 100%;
  aspect-ratio: 4 / 3;
  max-height: 320px;
  border-radius: 16px;
  overflow: hidden;
  background: #000;
  border: 1px solid var(--line);
}

.scanner-wrap video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

#scanner-view #qr-shaded-region {
  border-color: transparent !important;
  box-shadow: none !important;
}


.theme-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 9px;
}

.theme-card {
  position: relative;
  padding: 12px;
  border-radius: 14px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  text-align: left;
  cursor: pointer;
  transition: border-color 0.18s ease, transform 0.15s ease;
}

.theme-card:active {
  transform: scale(0.97);
}

.theme-card.active {
  border-color: var(--cyan);
  box-shadow: 0 0 0 2px rgba(var(--cyan-rgb), 0.14), 0 0 20px rgba(var(--cyan-rgb), 0.12);
}

.theme-dots {
  display: flex;
  gap: 5px;
  margin-bottom: 8px;
}

.theme-dots i {
  width: 14px;
  height: 14px;
  border-radius: 50%;
}

.theme-card b {
  display: block;
  font-size: 12px;
  font-weight: 800;
}

.theme-card span {
  font-size: 9.5px;
  color: var(--muted);
}

.theme-gender {
  position: absolute;
  top: 10px;
  right: 10px;
  font-size: 8px;
  font-weight: 800;
  letter-spacing: 0.06em;
  padding: 3px 6px;
  border-radius: 6px;
  background: rgba(255, 255, 255, 0.06);
  color: var(--muted);
}

.body-card .body-chart {
  margin: 10px 0 4px;
}

.body-chart svg {
  width: 100%;
  height: auto;
}

.body-stats {
  display: flex;
  gap: 16px;
  align-items: baseline;
}

.body-stats b {
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: -0.03em;
}

.body-stats span {
  font-size: 11px;
  color: var(--muted);
}

.body-delta {
  font-size: 11px;
  font-weight: 800;
  color: var(--lime);
}

.body-delta.down {
  color: var(--cyan);
}

.body-history {
  display: grid;
  gap: 6px;
  margin-top: 8px;
}

.body-history .food-row {
  padding: 6px 0;
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
}
