/*
Theme Name: MG Trust Laboratory
Theme URI: https://mgtrust.example.com
Author: MG Trust Lab
Description: Official WordPress theme for MG TRUST Laboratory. Hybrid multi-page, neumorphism design, dark/light theme, mobile-first with desktop responsive layout. Powered by Cybe AI.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 8.0
Text Domain: mg-trust
*/

/* ═══════════════════════════════════════════
   COLOR PALETTE — Extracted from MG TRUST Logo
   Green ring, teal figure, medical caduceus
   ═══════════════════════════════════════════ */

:root {
  --radius: 18px;
  --radius-sm: 12px;
  --radius-lg: 28px;
  --transition: 0.3s cubic-bezier(.4,0,.2,1);
  --font: 'Plus Jakarta Sans', sans-serif;
}

[data-theme="dark"] {
  /* Base surfaces — all same grey family */
  --bg:           #1e2128;
  --bg2:          #222631;
  --bg3:          #262b38;
  --surface:      #222631;
  --surface2:     #262b38;

  /* Neumorphism shadows — light source top-left */
  --nm-light:     rgba(255,255,255,0.06);
  --nm-dark:      rgba(0,0,0,0.50);

  /* Inset shadows — pressed/input state */
  --inset-light:  rgba(0,0,0,0.45);
  --inset-dark:   rgba(255,255,255,0.04);

  /* Text — dark green tones */
  --text:         #e2e8f0;
  --text2:        #94a3b8;
  --text3:        #4ade80;

  /* Borders */
  --border:       rgba(255,255,255,0.05);

  /* Input background */
  --input-bg:     #1a1e28;

  /* Brand accent — dark green for buttons, text, small shadow glow */
  --g1:           #22c55e;
  --g2:           #16a34a;
  --g3:           #15803d;
  --g4:           #166534;

  /* Semantic */
  --danger:       #ef4444;
  --warning:      #f59e0b;
  --success:      #22c55e;
  --overlay:      rgba(0,0,0,0.70);

  /* Small green glow for buttons and active states */
  --glow:         rgba(34,197,94,0.20);
}

[data-theme="light"] {
  /* Base surfaces — all same warm grey family */
  --bg:           #e0e5ec;
  --bg2:          #e4e9f0;
  --bg3:          #d8dde8;
  --surface:      #e4e9f0;
  --surface2:     #d8dde8;

  /* Neumorphism shadows — light source top-left */
  --nm-light:     rgba(255,255,255,0.80);
  --nm-dark:      rgba(163,177,198,0.60);

  /* Inset shadows */
  --inset-light:  rgba(255,255,255,0.70);
  --inset-dark:   rgba(163,177,198,0.50);

  /* Text — dark green tones */
  --text:         #1e293b;
  --text2:        #334155;
  --text3:        #15803d;

  /* Borders */
  --border:       rgba(163,177,198,0.40);

  /* Input background */
  --input-bg:     #dde1e8;

  /* Brand accent — dark green for buttons, text, small shadow glow */
  --g1:           #16a34a;
  --g2:           #15803d;
  --g3:           #166534;
  --g4:           #14532d;

  /* Semantic */
  --danger:       #dc2626;
  --warning:      #d97706;
  --success:      #16a34a;
  --overlay:      rgba(0,0,0,0.50);

  /* Small green glow */
  --glow:         rgba(22,163,74,0.15);
}

/* ═══════════════════════════════════════════
   RESET
   ═══════════════════════════════════════════ */
*, *::before, *::after {
  margin: 0; padding: 0;
  box-sizing: border-box;
  -webkit-tap-highlight-color: transparent;
}
html { scroll-behavior: smooth; }
body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  overflow-x: hidden;
  transition: background var(--transition), color var(--transition);
}
a { text-decoration: none; color: inherit; }
button { cursor: pointer; font-family: var(--font); }
img { max-width: 100%; }
input, select, textarea { font-family: var(--font); }

/* ═══════════════════════════════════════════
   APP SHELL
   ═══════════════════════════════════════════ */
.app-shell {
  width: 100%;
  max-width: 430px;
  min-height: 100vh;
  margin: 0 auto;
  background: var(--bg);
  display: flex;
  flex-direction: column;
  position: relative;
}

/* ═══════════════════════════════════════════
   NEUMORPHISM HELPERS
   ═══════════════════════════════════════════ */
.nm-raised {
  background: var(--bg2);
  box-shadow:
    6px 6px 14px var(--nm-dark),
    -6px -6px 14px var(--nm-light);
  border: 1px solid var(--border);
}
.nm-inset {
  background: var(--input-bg);
  box-shadow:
    inset 4px 4px 10px var(--inset-light),
    inset -4px -4px 10px var(--inset-dark);
  border: 1px solid var(--border);
}
.nm-flat {
  background: var(--bg2);
  box-shadow:
    3px 3px 8px var(--nm-dark),
    -3px -3px 8px var(--nm-light);
}

/* ═══════════════════════════════════════════
   SCROLL AREA
   ═══════════════════════════════════════════ */
.scroll-area {
  flex: 1;
  overflow-y: auto;
  padding: 0 16px 110px;
  scrollbar-width: none;
}
.scroll-area::-webkit-scrollbar { display: none; }

/* ═══════════════════════════════════════════
   HEADER
   ═══════════════════════════════════════════ */
.site-header {
  padding: 16px 20px 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-shrink: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 40;
}
.logo-wrap { display: flex; align-items: center; gap: 10px; }
.logo-wrap a { display: flex; align-items: center; gap: 10px; }
.logo-icon {
  width: 42px; height: 42px;
  border-radius: 14px;
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}
.logo-icon img { width: 100%; height: 100%; object-fit: cover; }
.logo-icon-svg {
  width: 42px; height: 42px; border-radius: 14px;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  display: flex; align-items: center; justify-content: center;
}
.logo-text { line-height: 1.2; }
.logo-text .brand {
  font-size: 15px; font-weight: 800; letter-spacing: .5px;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.logo-text .sub {
  font-size: 9px; color: var(--text3); font-weight: 500;
  letter-spacing: 1px; text-transform: uppercase;
}
.header-actions { display: flex; gap: 8px; align-items: center; }
.icon-btn {
  width: 38px; height: 38px; border-radius: 12px; border: none;
  display: flex; align-items: center; justify-content: center;
  color: var(--text2); transition: var(--transition);
}
.icon-btn svg { width: 18px; height: 18px; }
.icon-btn:active { transform: scale(.94); }
.notif-wrap { position: relative; }
.notif-badge {
  position: absolute; top: -3px; right: -3px;
  min-width: 16px; height: 16px; border-radius: 8px;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  font-size: 8px; font-weight: 700; color: #000;
  display: flex; align-items: center; justify-content: center;
  padding: 0 3px;
}

/* ═══════════════════════════════════════════
   TOP NAV — Desktop
   ═══════════════════════════════════════════ */
.top-nav {
  display: none;
  align-items: center;
  gap: 4px;
}
.top-nav-item {
  padding: 8px 14px; border-radius: 10px; border: none;
  font-size: 13px; font-weight: 600; color: var(--text2);
  background: transparent; transition: var(--transition);
  text-decoration: none;
}
.top-nav-item:hover { color: var(--g1); background: var(--bg2); }
.top-nav-item.active { color: var(--g1); background: var(--bg2); }

/* ═══════════════════════════════════════════
   BOTTOM NAV — Mobile
   ═══════════════════════════════════════════ */
.bottom-nav {
  position: fixed; bottom: 0; left: 50%;
  transform: translateX(-50%);
  width: 100%; max-width: 430px;
  z-index: 50;
  background: var(--bg);
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 20px var(--nm-dark);
}
.nav-inner {
  display: flex; justify-content: space-around; align-items: center;
  padding: 10px 8px calc(10px + env(safe-area-inset-bottom, 0px));
}
.nav-item {
  flex: 1; display: flex; flex-direction: column;
  align-items: center; gap: 4px;
  margin: 0 3px; padding: 8px 4px; border-radius: 14px;
  transition: var(--transition); border: none;
  color: var(--text3); text-decoration: none;
}
.nav-item svg { width: 20px; height: 20px; transition: var(--transition); }
.nav-item span { font-size: 9px; font-weight: 600; transition: var(--transition); }
.nav-item:active { transform: scale(.93); }
.nav-item.active {
  color: var(--g1);
  background: var(--bg2);
  box-shadow:
    inset 4px 4px 10px var(--inset-light),
    inset -4px -4px 10px var(--inset-dark);
}
.nav-item.active span { font-weight: 700; }

/* ═══════════════════════════════════════════
   SECTION TITLES
   ═══════════════════════════════════════════ */
.sec-title {
  display: flex; align-items: center; justify-content: space-between;
  margin-bottom: 14px; margin-top: 24px;
}
.sec-title h3 { font-size: 16px; font-weight: 800; color: var(--text); }
.sec-title a { font-size: 12px; color: var(--g2); font-weight: 600; }

/* ═══════════════════════════════════════════
   BUTTONS
   ═══════════════════════════════════════════ */
.btn-primary {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 20px; border-radius: var(--radius); border: none;
  font-size: 14px; font-weight: 700; color: #000; letter-spacing: .3px;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  box-shadow:
    0 6px 20px var(--glow),
    3px 3px 8px var(--nm-dark),
    -2px -2px 6px var(--nm-light);
  color: #ffffff;
  transition: var(--transition); width: 100%;
}
.btn-primary:active {
  box-shadow:
    inset 3px 3px 8px rgba(0,0,0,0.30),
    inset -2px -2px 6px rgba(255,255,255,0.05);
  transform: scale(0.97);
}
.btn-outline {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 20px; border-radius: var(--radius); border: none;
  font-size: 14px; font-weight: 600; color: var(--g1);
  background: transparent; border: 1.5px solid var(--g2);
  transition: var(--transition); width: 100%;
}
.btn-outline:active { transform: scale(.97); }
.btn-ghost {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 10px 16px; border-radius: var(--radius-sm); border: none;
  font-size: 13px; font-weight: 600; color: var(--text2);
  background: var(--bg2); transition: var(--transition);
}
.btn-ghost:active { transform: scale(.96); }
.btn-sm { padding: 8px 14px; font-size: 12px; border-radius: 10px; }
.btn-danger {
  background: linear-gradient(135deg, var(--danger), #c62828);
  color: #fff; box-shadow: 0 4px 14px rgba(239,83,80,.3);
}

/* ═══════════════════════════════════════════
   FORMS
   ═══════════════════════════════════════════ */
.form-group { margin-bottom: 14px; }
.form-group label {
  font-size: 11px; font-weight: 600; color: var(--text2);
  text-transform: uppercase; letter-spacing: .8px;
  display: block; margin-bottom: 7px;
}
.form-input {
  width: 100%; padding: 13px 16px; border-radius: 14px;
  border: none; outline: none; color: var(--text);
  font-size: 14px; background: var(--input-bg);
  box-shadow:
    inset 4px 4px 10px var(--inset-light),
    inset -4px -4px 10px var(--inset-dark);
  border: 1px solid var(--border);
  transition: box-shadow var(--transition);
}
.form-input:focus {
  box-shadow:
    inset 4px 4px 10px var(--inset-light),
    inset -4px -4px 10px var(--inset-dark),
    0 0 0 2px var(--glow);
}
.form-input::placeholder { color: var(--text3); }
.form-select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%2366BB6A' viewBox='0 0 16 16'%3E%3Cpath d='M7.247 11.14L2.451 5.658C1.885 5.013 2.345 4 3.204 4h9.592a1 1 0 0 1 .753 1.659l-4.796 5.48a1 1 0 0 1-1.506 0z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: right 14px center;
}
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }

/* ═══════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════ */
.card {
  border-radius: 20px; padding: 16px;
  transition: var(--transition);
}
.card:hover { transform: translateY(-3px); }
.card:active { transform: scale(.98); }

/* ═══════════════════════════════════════════
   HERO / SLIDER
   ═══════════════════════════════════════════ */
.slider-section { margin-bottom: 20px; position: relative; }
.slider-wrap {
  border-radius: 24px; overflow: hidden; position: relative;
  height: 200px;
  box-shadow: 0 8px 30px rgba(0,0,0,.4);
}
.slide {
  position: absolute; inset: 0;
  display: flex; flex-direction: column;
  align-items: flex-start; justify-content: flex-end;
  padding: 20px 22px;
  opacity: 0; transition: opacity .6s ease;
}
.slide.active { opacity: 1; }
.slide-eyebrow {
  font-size: 10px; font-weight: 600; letter-spacing: 1.5px;
  text-transform: uppercase; color: rgba(255,255,255,.7);
  margin-bottom: 6px;
}
.slide h2 { font-size: 22px; font-weight: 900; color: #fff; line-height: 1.2; margin-bottom: 6px; }
.slide p { font-size: 12px; color: rgba(255,255,255,.65); line-height: 1.4; }
.slide-dots {
  display: flex; gap: 6px; justify-content: center;
  margin-top: 10px;
}
.dot {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--text3); transition: var(--transition); border: none;
}
.dot.active { width: 20px; border-radius: 3px; background: var(--g1); }
.slide-arrows {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 100%; display: flex; justify-content: space-between;
  padding: 0 10px; pointer-events: none;
}
.slide-arrow {
  width: 32px; height: 32px; border-radius: 50%; border: none;
  background: rgba(0,0,0,.3); backdrop-filter: blur(4px);
  color: #fff; display: flex; align-items: center; justify-content: center;
  pointer-events: all; cursor: pointer; transition: var(--transition);
}
.slide-arrow:hover { background: rgba(0,0,0,.5); }
.slide-arrow svg { width: 16px; height: 16px; }

/* ═══════════════════════════════════════════
   CYBE AI RECEPTIONIST
   ═══════════════════════════════════════════ */
.receptionist-section {
  border-radius: 24px; padding: 0; margin-bottom: 20px; overflow: hidden;
}
.receptionist-header {
  padding: 16px 18px 12px;
  display: flex; align-items: center; gap: 12px;
  border-bottom: 1px solid var(--border);
}
.cybe-avatar {
  width: 44px; height: 44px; border-radius: 14px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 4px 12px rgba(46,125,50,.3);
}
.cybe-avatar img { width: 28px; height: 28px; }
.cybe-avatar svg { width: 24px; height: 24px; color: #000; }
.cybe-info { flex: 1; }
.cybe-name { font-size: 14px; font-weight: 700; color: var(--text); }
.cybe-status { font-size: 10px; color: var(--g1); font-weight: 500; display: flex; align-items: center; gap: 4px; }
.cybe-status-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--g1); box-shadow: 0 0 6px var(--g1); }
.chat-messages {
  max-height: 260px; overflow-y: auto; padding: 14px;
  display: flex; flex-direction: column; gap: 10px;
  scrollbar-width: none;
}
.chat-messages::-webkit-scrollbar { display: none; }
.msg { display: flex; gap: 8px; align-items: flex-end; }
.msg.bot { flex-direction: row; }
.msg.user { flex-direction: row-reverse; }
.msg-avatar-sm {
  width: 26px; height: 26px; border-radius: 9px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center; font-size: 10px;
}
.msg.bot .msg-avatar-sm { background: linear-gradient(135deg, var(--g1), var(--g2)); color: #000; font-weight: 800; }
.msg.user .msg-avatar-sm { background: var(--bg3); color: var(--text2); }
.msg-bubble {
  max-width: 80%; padding: 10px 13px; border-radius: 16px;
  font-size: 13px; line-height: 1.5;
  animation: msgIn .3s ease;
}
.msg.bot .msg-bubble { background: var(--bg3); color: var(--text); border-radius: 4px 16px 16px 16px; }
.msg.user .msg-bubble { background: linear-gradient(135deg, var(--g1), var(--g2)); color: #000; font-weight: 500; border-radius: 16px 16px 4px 16px; }
.cybe-powered-badge {
  text-align: center; padding: 4px 0; margin: 0;
  font-size: 9px; color: var(--text3); letter-spacing: .4px;
  border-top: 1px solid var(--border); background: var(--bg);
  flex-shrink: 0;
}
.cybe-powered-badge a {
  color: var(--g1); font-weight: 700; text-decoration: none;
  border-bottom: 1px solid rgba(34,197,94,0.3);
  transition: var(--transition);
}
.cybe-powered-badge a:hover { border-bottom-color: var(--g1); }
.quick-replies { display: flex; flex-wrap: wrap; gap: 6px; padding: 4px 0 8px; }
.qr-btn {
  padding: 6px 12px; border-radius: 20px; border: 1.5px solid rgba(102,187,106,.3);
  background: transparent; color: var(--g1); font-size: 11px; font-weight: 600;
  cursor: pointer; transition: var(--transition);
}
.qr-btn:active { background: rgba(102,187,106,.1); transform: scale(.96); }
.typing-indicator { display: flex; gap: 4px; align-items: center; padding: 8px 0; }
.typing-indicator span {
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--text3); animation: bounce .8s infinite;
}
.typing-indicator span:nth-child(2) { animation-delay: .15s; }
.typing-indicator span:nth-child(3) { animation-delay: .3s; }
.receptionist-input {
  padding: 12px 14px; border-top: 1px solid var(--border);
  display: flex; gap: 8px; align-items: center;
}
.chat-input-field {
  flex: 1; padding: 10px 14px; border-radius: 12px; border: none; outline: none;
  color: var(--text); font-size: 13px; background: var(--input-bg);
  box-shadow:
    inset 4px 4px 10px var(--inset-light),
    inset -4px -4px 10px var(--inset-dark);
  border: 1px solid var(--border);
}
.chat-input-field::placeholder { color: var(--text3); }
.receptionist-btns { display: flex; gap: 6px; }
/* 3-icon input bar */
.rcpt-icon-row { display: flex; gap: 8px; align-items: center; justify-content: center; width: 100%; padding: 4px 0; }
.rcpt-icon-btn {
  flex: 1; display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 10px 8px; border-radius: 14px; border: 1.5px solid var(--border);
  background: var(--bg3); color: var(--text2); cursor: pointer; transition: var(--transition);
}
.rcpt-icon-btn svg { width: 22px; height: 22px; }
.rcpt-icon-btn span { font-size: 9px; font-weight: 600; letter-spacing: .3px; }
.rcpt-icon-btn:active, .rcpt-icon-btn.active { background: linear-gradient(135deg,var(--g1),var(--g2)); color: #000; border-color: var(--g1); }
.rcpt-keyboard-row { display: flex; gap: 8px; align-items: center; width: 100%; margin-top: 8px; }
/* 3-icon for all AI pages */
.ai-icon-row { display: flex; gap: 8px; align-items: center; justify-content: center; flex-shrink: 0; }
.ai-icon-btn {
  display: flex; flex-direction: column; align-items: center; gap: 4px;
  padding: 8px 12px; border-radius: 12px; border: 1.5px solid var(--border);
  background: var(--bg3); color: var(--text2); cursor: pointer; transition: var(--transition);
  flex-shrink: 0;
}
.ai-icon-btn svg { width: 20px; height: 20px; }
.ai-icon-btn span { font-size: 9px; font-weight: 600; }
.ai-icon-btn:active, .ai-icon-btn.active { background: linear-gradient(135deg,var(--g1),var(--g2)); color: #000; border-color: var(--g1); }
.rcpt-btn {
  width: 36px; height: 36px; border-radius: 11px; border: none;
  display: flex; align-items: center; justify-content: center;
  transition: var(--transition); flex-shrink: 0;
}
.rcpt-btn svg { width: 16px; height: 16px; }
.rcpt-btn.template { background: var(--bg3); color: var(--text2); }
.rcpt-btn.voice { background: linear-gradient(135deg, var(--g2), var(--g4)); color: #fff; }
.rcpt-btn.send { background: linear-gradient(135deg, var(--g1), var(--g2)); color: #000; }
.rcpt-btn:active { transform: scale(.92); }

/* ═══════════════════════════════════════════
   FLOATING MEDICAL TIPS
   ═══════════════════════════════════════════ */
.medical-tip-float {
  position: fixed; bottom: 90px; left: 16px;
  max-width: 200px; border-radius: 12px; padding: 8px 10px;
  z-index: 90; animation: float 3s ease-in-out infinite;
  cursor: grab; touch-action: none;
}
.medical-tip-float.dragging { animation: none; cursor: grabbing; }
.draggable-float { touch-action: none; user-select: none; -webkit-user-select: none; }
.tip-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 6px; }
.tip-label { font-size: 9px; font-weight: 700; color: var(--g1); letter-spacing: .8px; text-transform: uppercase; }
.tip-actions { display: flex; gap: 4px; }
.tip-btn {
  width: 22px; height: 22px; border-radius: 7px; border: none;
  background: var(--bg3); color: var(--text3); font-size: 10px;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; transition: var(--transition);
}
.tip-btn svg { width: 11px; height: 11px; }
.tip-text { font-size: 10px; color: var(--text2); line-height: 1.4; }

/* ═══════════════════════════════════════════
   CYBE AI ADMINISTRATOR FLOAT BUTTON
   ═══════════════════════════════════════════ */
.cybe-admin-btn {
  position: fixed; top: 70px; right: 16px;
  width: 48px; height: 48px; border-radius: 16px; border: none;
  background: linear-gradient(135deg, #1a3a1e, #2e7d32);
  box-shadow: 0 6px 20px rgba(46,125,50,.4);
  display: flex; align-items: center; justify-content: center;
  z-index: 200; cursor: grab; touch-action: none;
  animation: pulse 3s infinite;
}
.cybe-admin-btn.dragging { cursor: grabbing; animation: none; }
.cybe-admin-btn svg { width: 22px; height: 22px; color: var(--g1); }
.cybe-admin-btn:active { transform: scale(.9); }
.cybe-admin-tooltip {
  position: absolute; right: 56px; top: 50%; transform: translateY(-50%);
  background: var(--surface); color: var(--text); font-size: 11px; font-weight: 600;
  padding: 5px 10px; border-radius: 8px; white-space: nowrap;
  border: 1px solid var(--border); pointer-events: none;
  opacity: 0; transition: opacity .2s;
}
.cybe-admin-btn:hover .cybe-admin-tooltip { opacity: 1; }

/* ═══════════════════════════════════════════
   CYBE AI ASSISTANT FLOAT BUTTON
   ═══════════════════════════════════════════ */
.cybe-assist-btn {
  position: fixed; bottom: 90px; right: 16px;
  width: 56px; height: 56px; border-radius: 18px; border: none;
  background: linear-gradient(135deg, var(--g2), var(--g4));
  box-shadow: 0 8px 24px rgba(0,105,92,.4);
  display: flex; align-items: center; justify-content: center;
  z-index: 100; cursor: grab; touch-action: none;
  animation: pulse 2s infinite;
}
.cybe-assist-btn.dragging { cursor: grabbing; animation: none; }
.cybe-assist-btn svg { width: 26px; height: 26px; color: #fff; }
.cybe-assist-btn:active { transform: scale(.9); }
.cybe-assist-label {
  position: absolute; bottom: -18px; left: 50%; transform: translateX(-50%);
  font-size: 8px; font-weight: 700; color: var(--text3); white-space: nowrap;
  letter-spacing: .5px;
}

/* ═══════════════════════════════════════════
   TEST CARDS
   ═══════════════════════════════════════════ */
.tests-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 24px;
}
.test-card {
  border-radius: 20px; padding: 16px; cursor: pointer;
  transition: var(--transition); position: relative; overflow: hidden;
}
.test-card:hover {
  transform: translateY(-4px);
  box-shadow:
    8px 8px 18px var(--nm-dark),
    -6px -6px 14px var(--nm-light),
    0 0 16px var(--glow);
}
.test-card:active { transform: scale(.97); }
.test-num {
  position: absolute; top: 12px; right: 12px;
  font-size: 10px; font-weight: 800; color: var(--text3); opacity: .5;
}
.test-emoji { font-size: 32px; margin-bottom: 10px; }
.test-name { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 3px; line-height: 1.3; }
.test-short { font-size: 10px; color: var(--text3); margin-bottom: 8px; }
.test-price { font-size: 16px; font-weight: 800; color: var(--g1); margin-bottom: 2px; }
.test-time { font-size: 10px; color: var(--text3); margin-bottom: 10px; }
.test-cat {
  font-size: 9px; font-weight: 700; padding: 3px 8px; border-radius: 20px;
  background: rgba(102,187,106,.12); color: var(--g1); display: inline-block; margin-bottom: 10px;
}
.cat-scroll {
  display: flex; gap: 8px; overflow-x: auto; padding-bottom: 8px; margin-bottom: 16px;
  scrollbar-width: none;
}
.cat-scroll::-webkit-scrollbar { display: none; }
.cat-chip {
  flex-shrink: 0; padding: 7px 14px; border-radius: 20px; font-size: 12px;
  font-weight: 600; cursor: pointer; transition: var(--transition); white-space: nowrap; border: none;
  background: var(--bg2); color: var(--text2);
  box-shadow: 3px 3px 8px var(--nm-dark), -3px -3px 8px var(--nm-light);
}
.cat-chip.active {
  background: linear-gradient(135deg, var(--g1), var(--g2));
  color: #000; box-shadow: 0 4px 14px rgba(46,125,50,.35);
}
.cat-chip:active { transform: scale(.95); }

/* ═══════════════════════════════════════════
   INSTRUCTIONS
   ═══════════════════════════════════════════ */
.instructions-section { margin-bottom: 24px; }
.step-card {
  border-radius: 18px; padding: 16px;
  display: flex; align-items: flex-start; gap: 14px;
  margin-bottom: 10px; transition: var(--transition);
}
.step-num {
  width: 36px; height: 36px; border-radius: 12px; flex-shrink: 0;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  display: flex; align-items: center; justify-content: center;
  font-size: 15px; font-weight: 900; color: #000;
}
.step-info h4 { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 4px; }
.step-info p { font-size: 11px; color: var(--text3); line-height: 1.5; }

/* ═══════════════════════════════════════════
   CONSULTATION
   ═══════════════════════════════════════════ */
.consult-section {
  border-radius: 24px; padding: 22px; margin-bottom: 24px;
  background: linear-gradient(135deg, rgba(46,125,50,.15), rgba(0,105,92,.1));
  border: 1px solid rgba(102,187,106,.2); text-align: center;
}
.consult-icon { font-size: 40px; margin-bottom: 14px; }
.consult-section h3 { font-size: 18px; font-weight: 800; color: var(--text); margin-bottom: 8px; }
.consult-section p { font-size: 12px; color: var(--text3); line-height: 1.6; margin-bottom: 18px; }

/* ═══════════════════════════════════════════
   BLOG
   ═══════════════════════════════════════════ */
.blog-hero {
  border-radius: 24px; padding: 22px; margin-top: 16px; margin-bottom: 20px;
  background: linear-gradient(135deg, #002010, #003a1a, #004d24);
  position: relative; overflow: hidden;
}
.blog-hero::before {
  content: ''; position: absolute; right: -20px; top: -20px;
  width: 140px; height: 140px; border-radius: 50%;
  background: radial-gradient(circle, rgba(102,187,106,.2), transparent 70%);
}
.blog-hero h2 { font-size: 22px; font-weight: 800; color: #fff; margin-bottom: 6px; position: relative; }
.blog-hero p { font-size: 12px; color: rgba(255,255,255,.6); position: relative; }
.blog-featured {
  border-radius: 22px; padding: 18px; margin-bottom: 16px;
  background: linear-gradient(135deg, rgba(46,125,50,.12), rgba(0,105,92,.08));
  border: 1px solid rgba(102,187,106,.15);
}
.blog-featured-label { font-size: 9px; font-weight: 700; color: var(--g1); letter-spacing: 1px; text-transform: uppercase; margin-bottom: 8px; }
.blog-featured h4 { font-size: 16px; font-weight: 800; color: var(--text); margin-bottom: 6px; line-height: 1.3; }
.blog-featured p { font-size: 12px; color: var(--text3); line-height: 1.5; margin-bottom: 12px; }
.blog-list { display: flex; flex-direction: column; gap: 14px; margin-bottom: 24px; }
.blog-card { border-radius: 20px; overflow: hidden; cursor: pointer; transition: var(--transition); display: block; }
.blog-card:hover { transform: translateY(-3px); }
.blog-card:active { transform: scale(.98); }
.blog-card-img {
  height: 140px; display: flex; align-items: flex-end; padding: 14px;
  position: relative; overflow: hidden;
}
.blog-card-img-bg { position: absolute; inset: 0; background-size: cover; background-position: center; }
.blog-card-img-emoji { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-60%); font-size: 54px; opacity: .3; }
.blog-cat-pill {
  font-size: 9px; font-weight: 700; padding: 3px 10px; border-radius: 20px;
  background: rgba(102,187,106,.2); color: var(--g1); letter-spacing: .6px;
  text-transform: uppercase; position: relative; z-index: 1;
}
.blog-card-body { padding: 14px 16px; }
.blog-card-body h4 { font-size: 14px; font-weight: 700; color: var(--text); margin-bottom: 6px; line-height: 1.35; }
.blog-card-body p { font-size: 11px; color: var(--text3); line-height: 1.5; margin-bottom: 10px; }
.blog-meta { display: flex; align-items: center; gap: 8px; }
.blog-meta .author { font-size: 10px; font-weight: 600; color: var(--text2); }
.blog-meta .dot { width: 3px; height: 3px; border-radius: 50%; background: var(--text3); }
.blog-meta .date { font-size: 10px; color: var(--text3); }
.blog-read { font-size: 10px; font-weight: 600; color: var(--g1); margin-left: auto; }

/* ═══════════════════════════════════════════
   SINGLE POST
   ═══════════════════════════════════════════ */
.post-topbar {
  position: sticky; top: 0; z-index: 10; background: var(--bg);
  border-bottom: 1px solid var(--border);
  display: flex; justify-content: space-between; align-items: center; padding: 12px 16px;
}
.post-back { display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; color: var(--g1); background: none; border: none; cursor: pointer; text-decoration: none; }
.post-share-btn { font-size: 12px; font-weight: 600; color: var(--text2); background: none; border: 1px solid var(--border); border-radius: 20px; padding: 5px 12px; cursor: pointer; }
.post-scroll { padding: 0 16px 40px; }
.post-cat-pill { display: inline-block; font-size: 9px; font-weight: 700; letter-spacing: .6px; text-transform: uppercase; padding: 3px 10px; border-radius: 20px; background: rgba(102,187,106,.18); color: var(--g1); margin: 16px 0 10px; }
.post-title { font-size: 22px; font-weight: 800; line-height: 1.25; color: var(--text); margin-bottom: 14px; }
.post-meta-row { display: flex; align-items: center; gap: 10px; margin-bottom: 18px; }
.post-avatar-circle { width: 36px; height: 36px; border-radius: 50%; background: linear-gradient(135deg, var(--g1), var(--g2)); color: #000; display: flex; align-items: center; justify-content: center; font-weight: 800; font-size: 14px; flex-shrink: 0; }
.post-author { font-size: 13px; font-weight: 700; color: var(--text); }
.post-date-read { font-size: 11px; color: var(--text3); }
.post-hero-img { width: calc(100% + 32px); margin: 0 -16px 20px; max-height: 220px; object-fit: cover; display: block; }
.post-body { font-size: 15px; line-height: 1.75; color: var(--text2); }
.post-body p { margin-bottom: 16px; }
.post-body h2, .post-body h3 { color: var(--text); font-weight: 700; margin: 20px 0 8px; }
.post-body a { color: var(--g1); }
.post-body img { width: 100%; border-radius: 12px; margin: 12px 0; }
.post-share-bar { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--border); }
.post-share-label { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: .5px; color: var(--text3); margin-bottom: 10px; }
.post-share-btns { display: flex; flex-wrap: wrap; gap: 8px; }
.post-shr-btn { font-size: 11px; font-weight: 600; padding: 7px 12px; border-radius: 20px; background: var(--surface); border: 1px solid var(--border); color: var(--text2); cursor: pointer; }
.comment-section { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--border); }
.comment-section h3 { font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 16px; }

/* ═══════════════════════════════════════════
   PROFILE
   ═══════════════════════════════════════════ */
.profile-header {
  border-radius: 24px; padding: 22px; margin-bottom: 20px; text-align: center;
  background: linear-gradient(135deg, rgba(46,125,50,.15), rgba(0,105,92,.1));
  border: 1px solid rgba(102,187,106,.15);
}
.profile-avatar {
  width: 72px; height: 72px; border-radius: 22px; margin: 0 auto 12px;
  background: linear-gradient(135deg, var(--g1), var(--g2));
  display: flex; align-items: center; justify-content: center;
  font-size: 28px; font-weight: 900; color: #000;
  box-shadow: 0 8px 20px rgba(46,125,50,.35);
}
.profile-name { font-size: 18px; font-weight: 800; color: var(--text); margin-bottom: 4px; }
.profile-email { font-size: 12px; color: var(--text3); margin-bottom: 14px; }
.profile-stats { display: flex; gap: 12px; justify-content: center; }
.p-stat { text-align: center; padding: 10px 16px; border-radius: 14px; min-width: 70px; }
.p-stat .v { font-size: 20px; font-weight: 900; color: var(--g1); }
.p-stat .l { font-size: 9px; color: var(--text3); text-transform: uppercase; letter-spacing: .5px; }

/* Results */
.result-card { border-radius: 20px; padding: 16px; margin-bottom: 14px; }
.result-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 14px; }
.result-header h4 { font-size: 14px; font-weight: 700; color: var(--text); }
.result-chip { font-size: 10px; font-weight: 600; padding: 4px 10px; border-radius: 20px; background: rgba(102,187,106,.15); color: var(--g1); }
.result-row { display: flex; align-items: center; justify-content: space-between; padding: 9px 0; border-bottom: 1px solid var(--border); }
.result-row:last-child { border-bottom: none; }
.result-test-name { font-size: 13px; font-weight: 600; color: var(--text); }
.result-range { font-size: 10px; color: var(--text3); }
.result-val { font-size: 13px; font-weight: 700; font-family: 'JetBrains Mono', monospace; }
.result-val.normal { color: var(--g1); }
.result-val.high { color: var(--danger); }
.result-val.low { color: var(--warning); }

/* Settings */
.settings-list { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.settings-item { border-radius: 16px; padding: 14px 16px; display: flex; align-items: center; gap: 12px; cursor: pointer; transition: var(--transition); }
.settings-item:active { transform: scale(.98); }
.settings-icon { width: 36px; height: 36px; border-radius: 12px; display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.settings-icon svg { width: 18px; height: 18px; }
.settings-info { flex: 1; }
.settings-info h4 { font-size: 13px; font-weight: 600; color: var(--text); margin-bottom: 2px; }
.settings-info p { font-size: 11px; color: var(--text3); }
.settings-arrow svg { width: 16px; height: 16px; color: var(--text3); }
.toggle { position: relative; width: 44px; height: 24px; }
.toggle input { opacity: 0; width: 0; height: 0; }
.toggle-slider { position: absolute; inset: 0; border-radius: 12px; cursor: pointer; background: var(--bg3); transition: var(--transition); box-shadow: inset 2px 2px 5px var(--inset-light), inset -2px -2px 5px var(--inset-dark); }
.toggle-slider::before { content: ''; position: absolute; width: 18px; height: 18px; border-radius: 50%; left: 3px; top: 3px; background: var(--text3); transition: var(--transition); }
.toggle input:checked + .toggle-slider { background: linear-gradient(135deg, var(--g1), var(--g2)); }
.toggle input:checked + .toggle-slider::before { transform: translateX(20px); background: #000; }

/* Auth */
.auth-tabs { display: flex; gap: 0; background: var(--input-bg); border-radius: 16px; padding: 5px; margin-bottom: 24px; box-shadow: inset 3px 3px 8px var(--inset-light), inset -3px -3px 8px var(--inset-dark); }
.auth-tab { flex: 1; padding: 8px; border-radius: 10px; border: none; font-size: 12px; font-weight: 700; background: transparent; color: var(--text3); transition: var(--transition); letter-spacing: .2px; }
.auth-tab.active { background: linear-gradient(135deg, var(--g1), var(--g2)); color: #000; box-shadow: 0 4px 14px rgba(46,125,50,.35); }
.auth-panel { display: none; }
.auth-panel.active { display: block; }
.auth-field { position: relative; margin-bottom: 16px; }
.auth-field label { display: block; font-size: 11px; font-weight: 700; color: var(--g1); letter-spacing: .6px; text-transform: uppercase; margin-bottom: 6px; }
.auth-input {
  width: 100%; padding: 11px 14px; border-radius: 12px; border: none; outline: none;
  color: var(--text); font-size: 13px; font-weight: 500;
  background: var(--input-bg);
  box-shadow: inset 3px 3px 8px var(--inset-light), inset -3px -3px 8px var(--inset-dark);
  border: 1.5px solid transparent; transition: border-color .25s, box-shadow .25s;
  box-sizing: border-box;
}
.auth-input:focus { border-color: var(--g1); box-shadow: inset 2px 2px 6px var(--inset-light), inset -2px -2px 6px var(--inset-dark), 0 0 0 3px rgba(102,187,106,.12); }
.auth-input::placeholder { color: var(--text3); font-size: 13px; }
.auth-forgot { text-align: right; margin-bottom: 14px; }
.auth-forgot a { font-size: 11px; color: var(--g2); font-weight: 600; cursor: pointer; }
.auth-divider { display: flex; align-items: center; gap: 10px; margin: 16px 0; }
.auth-divider::before, .auth-divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }
.auth-divider span { font-size: 11px; color: var(--text3); font-weight: 500; white-space: nowrap; }
.btn-google { display: flex; align-items: center; justify-content: center; gap: 10px; width: 100%; padding: 11px; border-radius: var(--radius); border: 1.5px solid var(--border); font-size: 13px; font-weight: 600; color: var(--text); background: var(--bg3); transition: var(--transition); }
.btn-google svg { width: 20px; height: 20px; }
.btn-google:active { transform: scale(.97); }
.auth-terms { font-size: 10px; color: var(--text3); text-align: center; margin-top: 14px; line-height: 1.5; }
.auth-terms a { color: var(--g2); }

/* ═══════════════════════════════════════════
   CONTACT
   ═══════════════════════════════════════════ */
.branch-card { border-radius: 20px; padding: 16px; display: flex; align-items: flex-start; gap: 12px; margin-bottom: 12px; }
.branch-num { width: 36px; height: 36px; border-radius: 12px; flex-shrink: 0; background: linear-gradient(135deg, var(--g1), var(--g2)); display: flex; align-items: center; justify-content: center; font-size: 14px; font-weight: 900; color: #000; }
.branch-info h4 { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 3px; }
.branch-info p { font-size: 11px; color: var(--text3); line-height: 1.5; }
.branch-open { font-size: 10px; font-weight: 600; color: var(--g1); margin-top: 4px; }
.branch-closed { font-size: 10px; font-weight: 600; color: var(--danger); margin-top: 4px; }
.branch-tag { font-size: 9px; font-weight: 700; padding: 2px 8px; border-radius: 20px; background: rgba(102,187,106,.1); color: var(--g1); margin-top: 6px; display: inline-block; }
.map-embed { border-radius: 16px; overflow: hidden; width: 100%; height: 180px; margin: 14px 0; border: 1px solid var(--border); }
.map-embed iframe { width: 100%; height: 100%; border: none; }

/* ═══════════════════════════════════════════
   ADMIN DASHBOARD
   ═══════════════════════════════════════════ */
.admin-section { border-radius: 20px; padding: 16px; margin-bottom: 14px; }
.admin-section-title { font-size: 13px; font-weight: 700; color: var(--g1); text-transform: uppercase; letter-spacing: .8px; margin-bottom: 14px; display: flex; align-items: center; gap: 8px; }
.admin-section-title svg { width: 16px; height: 16px; }
.admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 14px; }
.admin-stat { border-radius: 14px; padding: 14px; text-align: center; }
.admin-stat .v { font-size: 22px; font-weight: 900; color: var(--g1); }
.admin-stat .l { font-size: 10px; color: var(--text3); margin-top: 2px; }
.mode-toggle { display: flex; gap: 8px; margin-bottom: 16px; }
.mode-btn { flex: 1; padding: 10px; border-radius: 12px; border: none; font-size: 13px; font-weight: 600; transition: var(--transition); }
.mode-btn.active { background: linear-gradient(135deg, var(--g1), var(--g2)); color: #000; }
.mode-btn:not(.active) { background: var(--bg3); color: var(--text3); }
.user-row { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-bottom: 1px solid var(--border); }
.user-avatar-sm { width: 34px; height: 34px; border-radius: 11px; background: linear-gradient(135deg, var(--g1), var(--g2)); display: flex; align-items: center; justify-content: center; font-size: 13px; font-weight: 800; color: #000; flex-shrink: 0; }
.user-info { flex: 1; }
.user-info .uname { font-size: 13px; font-weight: 600; color: var(--text); }
.user-info .uemail { font-size: 10px; color: var(--text3); }
.user-badge { font-size: 9px; font-weight: 700; padding: 2px 8px; border-radius: 20px; }
.badge-admin { background: rgba(102,187,106,.15); color: var(--g1); }
.badge-user { background: rgba(38,166,154,.15); color: var(--g2); }
.badge-pending { background: rgba(255,167,38,.15); color: var(--warning); }

/* ═══════════════════════════════════════════
   CHAT DRAWER (Cybe AI full)
   ═══════════════════════════════════════════ */
.chat-overlay { position: fixed; inset: 0; background: var(--overlay); z-index: 300; opacity: 0; pointer-events: none; transition: var(--transition); }
.chat-overlay.open { opacity: 1; pointer-events: all; }
.chat-drawer {
  position: fixed; bottom: 0; left: 50%; transform: translateX(-50%) translateY(100%);
  width: 100%; max-width: 430px; height: 85vh; border-radius: 28px 28px 0 0;
  background: var(--bg2); z-index: 301; transition: transform .4s cubic-bezier(.4,0,.2,1);
  display: flex; flex-direction: column; box-shadow: 0 -10px 40px rgba(0,0,0,.5);
}
.chat-drawer.open { transform: translateX(-50%) translateY(0); }
.drawer-handle { width: 40px; height: 4px; border-radius: 2px; background: var(--text3); margin: 12px auto 0; flex-shrink: 0; }
.drawer-top { padding: 12px 18px 10px; display: flex; align-items: center; justify-content: space-between; flex-shrink: 0; border-bottom: 1px solid var(--border); }
.drawer-close { width: 32px; height: 32px; border-radius: 10px; border: none; background: var(--bg3); color: var(--text2); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.drawer-close svg { width: 16px; height: 16px; }
.drawer-messages { flex: 1; overflow-y: auto; padding: 12px 16px; display: flex; flex-direction: column; gap: 10px; scrollbar-width: none; }
.drawer-messages::-webkit-scrollbar { display: none; }
.drawer-input { padding: 12px 16px calc(12px + env(safe-area-inset-bottom,0px)); display: flex; gap: 8px; align-items: flex-end; flex-shrink: 0; border-top: 1px solid var(--border); }
.drawer-textarea { flex: 1; padding: 11px 14px; border-radius: 14px; border: 1px solid var(--border); outline: none; color: var(--text); font-size: 13px; background: var(--input-bg); box-shadow: inset 4px 4px 10px var(--inset-light), inset -4px -4px 10px var(--inset-dark); resize: none; max-height: 100px; overflow-y: auto; }
.send-btn { width: 44px; height: 44px; border-radius: 14px; border: none; background: linear-gradient(135deg, var(--g1), var(--g2)); color: #000; display: flex; align-items: center; justify-content: center; flex-shrink: 0; box-shadow: 0 4px 14px rgba(46,125,50,.35); transition: var(--transition); }
.send-btn:active { transform: scale(.92); }
.send-btn svg { width: 18px; height: 18px; }

/* ═══════════════════════════════════════════
   MODALS
   ═══════════════════════════════════════════ */
.modal-overlay { position: fixed; inset: 0; background: var(--overlay); z-index: 400; display: none; align-items: center; justify-content: center; padding: 20px; }
.modal-overlay.open { display: flex; }
.modal-card { background: var(--bg2); border-radius: 28px; width: 100%; max-width: 380px; max-height: 90vh; overflow-y: auto; padding: 24px; box-shadow: 0 20px 60px rgba(0,0,0,.5); animation: slideUp .3s cubic-bezier(.4,0,.2,1); }
.modal-header { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.modal-title { font-size: 16px; font-weight: 800; color: var(--text); }
.modal-close { width: 32px; height: 32px; border-radius: 10px; border: none; background: var(--bg3); color: var(--text2); display: flex; align-items: center; justify-content: center; cursor: pointer; }
.modal-close svg { width: 16px; height: 16px; }

/* ═══════════════════════════════════════════
   TOAST
   ═══════════════════════════════════════════ */
.toast {
  position: fixed; top: 20px; left: 50%; transform: translateX(-50%) translateY(-80px);
  width: calc(100% - 32px); max-width: 400px; border-radius: 16px; padding: 14px 16px;
  display: flex; align-items: center; gap: 12px;
  backdrop-filter: blur(12px); border: 1px solid rgba(102,187,106,.25);
  z-index: 1000; transition: transform .4s cubic-bezier(.4,0,.2,1);
}
.toast.show { transform: translateX(-50%) translateY(0); }
.toast.success { background: linear-gradient(135deg, rgba(46,125,50,.95), rgba(0,105,92,.9)); }
.toast.error { background: linear-gradient(135deg, rgba(198,40,40,.95), rgba(183,28,28,.9)); }
.toast.info { background: linear-gradient(135deg, rgba(13,31,15,.95), rgba(26,58,30,.9)); }
.toast-icon { width: 32px; height: 32px; border-radius: 10px; flex-shrink: 0; background: rgba(255,255,255,.15); display: flex; align-items: center; justify-content: center; }
.toast-icon svg { width: 18px; height: 18px; color: #fff; }
.toast-text h4 { font-size: 13px; font-weight: 700; color: #fff; }
.toast-text p { font-size: 11px; color: rgba(255,255,255,.7); }

/* ═══════════════════════════════════════════
   CYBE AI PAGE (full chat)
   ═══════════════════════════════════════════ */
.cybe-page { display: flex; flex-direction: column; height: calc(100vh - 60px); }
.cybe-chat-area { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 12px; scrollbar-width: none; }
.cybe-chat-area::-webkit-scrollbar { display: none; }
.call-btn {
  position: absolute; top: 12px; right: 60px;
  width: 34px; height: 34px; border-radius: 11px; border: none;
  background: linear-gradient(135deg, var(--g2), var(--g4)); color: #fff;
  display: flex; align-items: center; justify-content: center; cursor: pointer;
  transition: var(--transition);
}
.call-btn svg { width: 16px; height: 16px; }
.call-screen {
  position: fixed; inset: 0; background: linear-gradient(160deg, #0a1f0c, #001a0e);
  z-index: 500; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 20px;
}
.call-avatar { width: 100px; height: 100px; border-radius: 30px; background: linear-gradient(135deg, var(--g1), var(--g2)); display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 0 rgba(102,187,106,.5); animation: callPulse 2s infinite; }
.call-avatar svg { width: 50px; height: 50px; color: #000; }
.call-name { font-size: 22px; font-weight: 800; color: #fff; }
.call-status { font-size: 14px; color: rgba(255,255,255,.6); }
.call-timer { font-size: 28px; font-weight: 800; color: var(--g1); font-family: 'JetBrains Mono', monospace; }
.call-controls { display: flex; gap: 20px; margin-top: 20px; }
.call-ctrl { width: 60px; height: 60px; border-radius: 20px; border: none; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: var(--transition); }
.call-ctrl svg { width: 26px; height: 26px; }
.call-ctrl.mute { background: rgba(255,255,255,.15); color: #fff; }
.call-ctrl.speaker { background: rgba(255,255,255,.15); color: #fff; }
.call-ctrl.end { background: linear-gradient(135deg, #ef5350, #c62828); color: #fff; }
.call-ctrl:active { transform: scale(.9); }
.call-wave { display: flex; gap: 4px; align-items: center; height: 40px; }
.call-wave span { width: 4px; border-radius: 2px; background: var(--g1); animation: wave 1s ease-in-out infinite; }
.call-wave span:nth-child(1) { animation-delay: 0s; }
.call-wave span:nth-child(2) { animation-delay: .1s; }
.call-wave span:nth-child(3) { animation-delay: .2s; }
.call-wave span:nth-child(4) { animation-delay: .3s; }
.call-wave span:nth-child(5) { animation-delay: .4s; }

/* ═══════════════════════════════════════════
   ABOUT
   ═══════════════════════════════════════════ */
.about-hero { border-radius: 24px; padding: 28px 22px; margin-bottom: 20px; background: linear-gradient(135deg, #002010, #003a1a); text-align: center; }
.about-hero h2 { font-size: 24px; font-weight: 900; color: #fff; margin-bottom: 8px; }
.about-hero p { font-size: 13px; color: rgba(255,255,255,.65); line-height: 1.6; }
.about-stats { display: grid; grid-template-columns: repeat(2,1fr); gap: 12px; margin-bottom: 20px; }
.about-stat { border-radius: 18px; padding: 18px; text-align: center; }
.about-stat .v { font-size: 28px; font-weight: 900; color: var(--g1); }
.about-stat .l { font-size: 11px; color: var(--text3); margin-top: 4px; }
.team-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 20px; }
.team-card { border-radius: 18px; padding: 16px; text-align: center; }
.team-avatar { width: 56px; height: 56px; border-radius: 18px; background: linear-gradient(135deg, var(--g1), var(--g2)); display: flex; align-items: center; justify-content: center; margin: 0 auto 10px; font-size: 22px; font-weight: 800; color: #000; }
.team-name { font-size: 13px; font-weight: 700; color: var(--text); margin-bottom: 3px; }
.team-role { font-size: 10px; color: var(--text3); }

/* ═══════════════════════════════════════════
   FOOTER
   ═══════════════════════════════════════════ */
.site-footer {
  padding: 32px 20px 24px; border-top: 1px solid var(--border);
  margin-top: 20px; text-align: center;
}
.footer-brand { margin-bottom: 20px; display: flex; flex-direction: column; align-items: center; }
.footer-logo { width: 56px; height: 56px; object-fit: contain; margin-bottom: 10px; border-radius: 14px; }
.footer-brand .brand { font-size: 18px; font-weight: 800; background: linear-gradient(135deg, var(--g1), var(--g2)); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }
.footer-brand p { font-size: 12px; color: var(--text3); margin-top: 4px; line-height: 1.5; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-bottom: 20px; justify-content: center; }
.footer-links a { font-size: 12px; color: var(--text2); font-weight: 600; }
.footer-contact { text-align: center; }
.footer-contact p { font-size: 12px; color: var(--text3); margin-bottom: 4px; }
.footer-copy { font-size: 11px; color: var(--text3); margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--border); text-align: center; }

/* ═══════════════════════════════════════════
   PRIVACY
   ═══════════════════════════════════════════ */
.privacy-section { margin-bottom: 24px; }
.privacy-section h3 { font-size: 15px; font-weight: 700; color: var(--text); margin-bottom: 10px; }
.privacy-section p { font-size: 13px; color: var(--text2); line-height: 1.7; margin-bottom: 10px; }
.privacy-section ul { padding-left: 16px; }
.privacy-section li { font-size: 13px; color: var(--text2); line-height: 1.7; margin-bottom: 6px; }

/* ═══════════════════════════════════════════
   ANIMATIONS
   ═══════════════════════════════════════════ */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes slideUp {
  from { opacity: 0; transform: translateY(30px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes msgIn {
  from { opacity: 0; transform: translateY(8px) scale(.96); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes bounce {
  0%,60%,100% { transform: translateY(0); }
  30%          { transform: translateY(-6px); }
}
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(102,187,106,.5); }
  70%  { box-shadow: 0 0 0 10px rgba(102,187,106,0); }
  100% { box-shadow: 0 0 0 0 rgba(102,187,106,0); }
}
@keyframes float {
  0%,100% { transform: translateY(0); }
  50%      { transform: translateY(-8px); }
}
@keyframes wave {
  0%,100% { height: 8px; }
  50%      { height: 32px; }
}
@keyframes callPulse {
  0%   { box-shadow: 0 0 0 0 rgba(102,187,106,.6); }
  70%  { box-shadow: 0 0 0 20px rgba(102,187,106,0); }
  100% { box-shadow: 0 0 0 0 rgba(102,187,106,0); }
}
@keyframes spin {
  to { transform: rotate(360deg); }
}
@keyframes drawCheck {
  from { stroke-dashoffset: 100; }
  to   { stroke-dashoffset: 0; }
}

.animate-fade-up { animation: fadeInUp .4s ease both; }
.animate-fade { animation: fadeIn .3s ease both; }
.scroll-reveal { opacity: 0; transform: translateY(24px); transition: opacity .5s ease, transform .5s ease; }
.scroll-reveal.visible { opacity: 1; transform: translateY(0); }

/* ═══════════════════════════════════════════
   SPINNER
   ═══════════════════════════════════════════ */
.spinner { width: 32px; height: 32px; border: 3px solid var(--border); border-top-color: var(--g1); border-radius: 50%; animation: spin .7s linear infinite; }
.loading-overlay { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 50px; gap: 14px; }
.loading-overlay p { font-size: 13px; color: var(--text3); }

/* ═══════════════════════════════════════════
   404
   ═══════════════════════════════════════════ */
.not-found { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 60px 20px; text-align: center; }
.not-found .code { font-size: 80px; font-weight: 900; color: var(--g1); line-height: 1; }
.not-found h2 { font-size: 22px; font-weight: 800; color: var(--text); margin: 12px 0 8px; }
.not-found p { font-size: 13px; color: var(--text3); margin-bottom: 24px; }

/* ═══════════════════════════════════════════
   UTILITIES
   ═══════════════════════════════════════════ */
.text-center { text-align: center; }
.text-right { text-align: right; }
.text-g1 { color: var(--g1); }
.text-danger { color: var(--danger); }
.text-warning { color: var(--warning); }
.flex { display: flex; }
.flex-center { display: flex; align-items: center; justify-content: center; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mb-8 { margin-bottom: 8px; }
.mb-12 { margin-bottom: 12px; }
.mb-16 { margin-bottom: 16px; }
.mb-20 { margin-bottom: 20px; }
.mb-24 { margin-bottom: 24px; }
.p-16 { padding: 16px; }
.hidden { display: none !important; }

/* ═══════════════════════════════════════════
   RESPONSIVE — Desktop
   ═══════════════════════════════════════════ */
@media (min-width: 769px) {
  body { display: block; }
  .app-shell { max-width: 100%; }
  .bottom-nav { display: none; }
  .top-nav { display: flex; }
  .scroll-area { padding: 0 40px 60px; }
  .tests-grid { grid-template-columns: repeat(4,1fr); }
  .about-stats { grid-template-columns: repeat(4,1fr); }
  .team-grid { grid-template-columns: repeat(4,1fr); }
  .about-stat, .team-card { border-radius: 20px; }
  .cybe-assist-btn { right: 30px; }
  .cybe-admin-btn { right: 30px; }
  .medical-tip-float { left: 30px; }
  .blog-list { display: grid; grid-template-columns: 1fr 1fr; }
  .branches-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
  .form-row { grid-template-columns: repeat(3,1fr); }
  .chat-drawer { max-width: 480px; }
}

@media (min-width: 1200px) {
  .scroll-area { padding: 0 80px 60px; max-width: 1200px; margin: 0 auto; }
  .tests-grid { grid-template-columns: repeat(5,1fr); }
}

/* ═══════════════════════════════════════════
   POWERED BY BADGE — between header and messages
   ═══════════════════════════════════════════ */
[data-cybe-badge] {
  border-top: none;
  border-bottom: 1px solid var(--border);
  background: var(--bg);
  padding: 4px 0 5px;
  font-size: 9px;
  letter-spacing: .4px;
  color: var(--text3);
  text-align: center;
  flex-shrink: 0;
}

/* ═══════════════════════════════════════════
   RCPT KEYBOARD ROW FLEX
   ═══════════════════════════════════════════ */
#receptionistKeyboardRow,
#bookingKeyboardRow,
#cybeMedKeyboardRow {
  display: none;
  gap: 8px;
  align-items: flex-end;
  width: 100%;
  margin-top: 8px;
}
#receptionistKeyboardRow.open,
#bookingKeyboardRow.open,
#cybeMedKeyboardRow.open {
  display: flex !important;
}

/* ═══════════════════════════════════════════
   CHAT PAGES — FULL WIDTH FIX
   Break cybe/booking shells out of scroll-area padding
   ═══════════════════════════════════════════ */
.cybe-page-wrap,
.booking-shell {
  margin-left: -16px;
  margin-right: -16px;
  width: calc(100% + 32px);
}

/* Remove scroll-area padding on full-screen chat pages */
body.page-template-page-cybeai .scroll-area,
body.page-template-page-book .scroll-area {
  padding: 0;
  overflow: hidden;
}

@media (min-width: 769px) {
  .cybe-page-wrap,
  .booking-shell {
    margin-left: -40px;
    margin-right: -40px;
    width: calc(100% + 80px);
  }
}

@media (min-width: 1200px) {
  .cybe-page-wrap,
  .booking-shell {
    margin-left: -80px;
    margin-right: -80px;
    width: calc(100% + 160px);
  }
}

/* Hide WP-injected page titles on chat pages */
body.page-template-page-cybeai .entry-title,
body.page-template-page-cybeai h1.page-title,
body.page-template-page-book .entry-title,
body.page-template-page-book h1.page-title {
  display: none;
}
