/* =========================================================================
   LawOffice — modern responsive design system (RTL / Arabic)
   ========================================================================= */

@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('../Fonts/cairo-arabic.woff2') format('woff2');
  unicode-range: U+0600-06FF, U+0750-077F, U+0870-0891, U+0897-08E1, U+08E3-08FF, U+200C-200E,
    U+2010-2011, U+204F, U+2E41, U+FB50-FDFF, U+FE70-FE74, U+FE76-FEFC;
}
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('../Fonts/cairo-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4;
}
@font-face {
  font-family: 'Cairo';
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url('../Fonts/cairo-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+2000-206F;
}

:root {
  --navy: #0b1f3a;
  --navy-2: #12294a;
  --navy-3: #1b3a63;
  --gold: #c9a227;
  --gold-2: #e0be5b;
  --gold-ink: #8a6b12;
  --ivory: #f8f6f1;
  --paper: #ffffff;
  --ink: #16202e;
  --muted: #6b7688;
  --line: #e6e4dd;
  --ok: #17915b;
  --warn: #b7791f;
  --danger: #c0392b;
  --info: #2563a8;

  --radius: 16px;
  --radius-sm: 10px;
  --radius-lg: 26px;
  --shadow-sm: 0 2px 8px rgba(11, 31, 58, .06);
  --shadow: 0 14px 34px rgba(11, 31, 58, .10);
  --shadow-lg: 0 30px 70px rgba(11, 31, 58, .18);

  --max: 1200px;
  --nav-h: 74px;
  --ease: cubic-bezier(.22, .68, .36, 1);
}

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

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

body {
  margin: 0;
  font-family: 'Cairo', 'Segoe UI', Tahoma, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.85;
  color: var(--ink);
  background: var(--ivory);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img, svg, video { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, h5 { margin: 0 0 .5em; line-height: 1.35; font-weight: 800; color: var(--navy); }
p { margin: 0 0 1em; }
ul { margin: 0; padding: 0; list-style: none; }

::selection { background: var(--gold); color: #fff; }

:focus-visible {
  outline: 3px solid rgba(201, 162, 39, .55);
  outline-offset: 2px;
  border-radius: 6px;
}

/* --------------------------- utilities ---------------------------- */
.container { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: 20px; }
.container-sm { max-width: 860px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.gold { color: var(--gold-ink); }
.mt-0 { margin-top: 0 !important; }
.mt-1 { margin-top: 10px; }
.mt-2 { margin-top: 20px; }
.mt-3 { margin-top: 34px; }
.mt-4 { margin-top: 54px; }
.mb-2 { margin-bottom: 20px; }
.hide { display: none !important; }
.full { width: 100%; }
.nowrap { white-space: nowrap; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: .82rem; font-weight: 800; letter-spacing: .06em;
  color: var(--gold-ink); text-transform: uppercase;
  background: rgba(201, 162, 39, .12);
  border: 1px solid rgba(201, 162, 39, .3);
  padding: 6px 16px; border-radius: 999px; margin-bottom: 16px;
}
.eyebrow::before { content: ""; width: 22px; height: 2px; background: var(--gold); border-radius: 2px; }

.section { padding: 84px 0; position: relative; }
.section-alt { background: var(--paper); }
.section-dark { background: linear-gradient(150deg, var(--navy) 0%, var(--navy-2) 60%, var(--navy-3) 100%); color: #e9edf4; }
.section-dark h2, .section-dark h3 { color: #fff; }

.section-head { max-width: 720px; margin-bottom: 44px; }
.section-head.center { margin-inline: auto; }
.section-head h2 { font-size: clamp(1.7rem, 3.4vw, 2.5rem); }
.section-head p { color: var(--muted); font-size: 1.03rem; margin: 0; }
.section-dark .section-head p { color: #b9c4d6; }

.rule { height: 3px; width: 64px; background: linear-gradient(90deg, var(--gold), var(--gold-2)); border-radius: 3px; margin: 14px 0 0; }
.center .rule { margin-inline: auto; }

/* ----------------------------- buttons ---------------------------- */
.btn {
  --btn-bg: var(--navy);
  --btn-fg: #fff;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 13px 28px; border-radius: 999px;
  background: var(--btn-bg); color: var(--btn-fg);
  border: 1.5px solid transparent; cursor: pointer;
  font-weight: 700; font-size: .97rem; letter-spacing: .01em;
  transition: transform .25s var(--ease), box-shadow .25s var(--ease), background .25s, color .25s, border-color .25s;
  position: relative; overflow: hidden; white-space: nowrap;
}
.btn:hover { transform: translateY(-3px); box-shadow: 0 14px 26px rgba(11, 31, 58, .22); }
.btn:active { transform: translateY(-1px); }
.btn svg { width: 18px; height: 18px; }

.btn-primary { --btn-bg: linear-gradient(135deg, var(--gold), var(--gold-2)); --btn-fg: #2c2103; }
.btn-primary:hover { box-shadow: 0 16px 30px rgba(201, 162, 39, .4); }
.btn-dark { --btn-bg: linear-gradient(135deg, var(--navy-2), var(--navy)); }
.btn-outline { --btn-bg: transparent; --btn-fg: var(--navy); border-color: rgba(11, 31, 58, .25); }
.btn-outline:hover { border-color: var(--navy); background: rgba(11, 31, 58, .05); }
.btn-ghost-light { --btn-bg: transparent; --btn-fg: #fff; border-color: rgba(255, 255, 255, .38); }
.btn-ghost-light:hover { background: rgba(255, 255, 255, .12); }
.btn-danger { --btn-bg: var(--danger); }
.btn-success { --btn-bg: var(--ok); }
.btn-sm { padding: 9px 18px; font-size: .87rem; }
.btn-lg { padding: 16px 38px; font-size: 1.05rem; }
.btn-block { display: flex; width: 100%; }
.btn[disabled], .btn.is-disabled { opacity: .55; pointer-events: none; }

.link-arrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-weight: 700; color: var(--gold-ink);
}
.link-arrow::after { content: "←"; transition: transform .25s var(--ease); }
.link-arrow:hover::after { transform: translateX(-6px); }

/* ------------------------------ topbar ---------------------------- */
.topbar {
  background: var(--navy); color: #c3ccdb;
  font-size: .86rem; padding: 9px 0;
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}
.topbar .container { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.topbar-info { display: flex; gap: 22px; flex-wrap: wrap; }
.topbar-info span { display: inline-flex; align-items: center; gap: 8px; }
.topbar-info svg { width: 15px; height: 15px; color: var(--gold); }
.topbar a:hover { color: #fff; }
.topbar-social { display: flex; gap: 6px; }
.topbar-social a {
  width: 28px; height: 28px; display: grid; place-items: center;
  border-radius: 50%; background: rgba(255, 255, 255, .07); color: #c3ccdb;
  transition: .25s var(--ease);
}
.topbar-social a:hover { background: var(--gold); color: var(--navy); transform: translateY(-2px); }
.topbar-social svg { width: 14px; height: 14px; }

/* ------------------------------ navbar ---------------------------- */
.navbar {
  position: sticky; top: 0; z-index: 900;
  background: rgba(255, 255, 255, .92);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .3s var(--ease), background .3s;
}
.navbar.is-stuck { box-shadow: 0 10px 30px rgba(11, 31, 58, .1); }
.navbar .container { display: flex; align-items: center; justify-content: space-between; gap: 20px; min-height: var(--nav-h); }

.brand { display: flex; align-items: center; gap: 12px; }
.brand-mark {
  width: 46px; height: 46px; flex: none; border-radius: 14px;
  background: linear-gradient(140deg, var(--navy), var(--navy-3));
  display: grid; place-items: center;
  box-shadow: 0 8px 18px rgba(11, 31, 58, .3);
  position: relative;
}
.brand-mark::after {
  content: ""; position: absolute; inset: auto -4px -4px auto;
  width: 16px; height: 16px; border-radius: 50%;
  background: var(--gold); border: 3px solid #fff;
}
.brand-mark svg { width: 26px; height: 26px; color: var(--gold-2); }
.brand-text { line-height: 1.25; }
.brand-text strong { display: block; font-size: 1.06rem; color: var(--navy); font-weight: 900; }
.brand-text small { display: block; font-size: .74rem; color: var(--muted); letter-spacing: .04em; }

.nav-menu { display: flex; align-items: center; gap: 4px; }
.nav-menu a {
  position: relative; padding: 10px 15px; border-radius: 10px;
  font-weight: 700; font-size: .96rem; color: #33405a;
  transition: color .2s, background .2s;
}
.nav-menu a::after {
  content: ""; position: absolute; inset-inline: 15px; bottom: 4px;
  height: 2px; background: var(--gold); transform: scaleX(0);
  transform-origin: right; transition: transform .3s var(--ease);
}
.nav-menu a:hover { color: var(--navy); background: rgba(11, 31, 58, .045); }
.nav-menu a:hover::after { transform: scaleX(1); }
.nav-menu a.is-active { color: var(--navy); }
.nav-menu a.is-active::after, .nav-menu a.is-active + a::after { transform: scaleX(1); }

.nav-actions { display: flex; align-items: center; gap: 10px; }
.nav-toggle {
  display: none; width: 44px; height: 44px; border: 1.5px solid var(--line);
  background: #fff; border-radius: 12px; cursor: pointer;
  align-items: center; justify-content: center; flex-direction: column; gap: 5px;
}
.nav-toggle span { width: 20px; height: 2px; background: var(--navy); border-radius: 2px; transition: .3s var(--ease); }
.nav-toggle.is-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle.is-open span:nth-child(2) { opacity: 0; }
.nav-toggle.is-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.user-chip {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 7px 8px 7px 16px; border-radius: 999px;
  background: rgba(11, 31, 58, .05); border: 1px solid var(--line);
  font-weight: 700; font-size: .9rem;
}
.user-chip .avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(140deg, var(--gold), var(--gold-2));
  color: #2c2103; display: grid; place-items: center; font-weight: 900; font-size: .9rem;
}

/* ------------------------------- hero ----------------------------- */
.hero {
  position: relative; overflow: hidden; color: #fff;
  background:
    radial-gradient(1100px 520px at 88% -12%, rgba(201, 162, 39, .3), transparent 60%),
    radial-gradient(760px 480px at 6% 110%, rgba(37, 99, 168, .35), transparent 62%),
    linear-gradient(150deg, #081729 0%, var(--navy) 46%, var(--navy-3) 100%);
  padding: 96px 0 110px;
}
.hero::before {
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, .045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .045) 1px, transparent 1px);
  background-size: 58px 58px;
  mask-image: radial-gradient(760px 420px at 70% 30%, #000 30%, transparent 78%);
  -webkit-mask-image: radial-gradient(760px 420px at 70% 30%, #000 30%, transparent 78%);
  pointer-events: none;
}
.hero .container { position: relative; z-index: 2; display: grid; grid-template-columns: 1.12fr .88fr; gap: 56px; align-items: center; }
.hero h1 { color: #fff; font-size: clamp(2.1rem, 5vw, 3.5rem); font-weight: 900; line-height: 1.22; margin-bottom: 20px; }
.hero h1 .accent {
  background: linear-gradient(120deg, var(--gold-2), var(--gold));
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero p.lead { color: #c4cee0; font-size: 1.1rem; max-width: 560px; margin-bottom: 30px; }
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }
.hero-facts { display: flex; gap: 34px; margin-top: 44px; flex-wrap: wrap; }
.hero-facts div strong { display: block; font-size: 1.9rem; color: var(--gold-2); font-weight: 900; line-height: 1.2; }
.hero-facts div span { font-size: .87rem; color: #a9b5c9; }

.hero-card {
  background: rgba(255, 255, 255, .07);
  border: 1px solid rgba(255, 255, 255, .16);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-radius: 24px; padding: 30px; box-shadow: var(--shadow-lg);
  position: relative;
}
.hero-card h3 { color: #fff; font-size: 1.2rem; margin-bottom: 6px; }
.hero-card > p { color: #b6c2d6; font-size: .93rem; }
.hero-list { display: grid; gap: 14px; margin-top: 20px; }
.hero-list li { display: flex; gap: 12px; align-items: flex-start; font-size: .95rem; color: #dfe6f1; }
.hero-list li svg { width: 20px; height: 20px; flex: none; color: var(--gold-2); margin-top: 3px; }
.hero-badge {
  position: absolute; inset-inline-start: -26px; top: -26px;
  background: linear-gradient(135deg, var(--gold), var(--gold-2));
  color: #2c2103; font-weight: 900; font-size: .8rem;
  padding: 10px 18px; border-radius: 999px; box-shadow: 0 12px 24px rgba(201, 162, 39, .4);
}

/* ------------------------------ cards ----------------------------- */
.grid { display: grid; gap: 26px; }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-auto { grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }

.card {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden;
  transition: transform .35s var(--ease), box-shadow .35s var(--ease), border-color .3s;
  display: flex; flex-direction: column;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow); border-color: rgba(201, 162, 39, .45); }
.card-body { padding: 24px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.card-body h3 { font-size: 1.14rem; margin: 0; line-height: 1.55; }
.card-body h3 a:hover { color: var(--gold-ink); }
.card-body p { color: var(--muted); font-size: .94rem; margin: 0; }
.card-media {
  position: relative; aspect-ratio: 16 / 9; overflow: hidden;
  background: linear-gradient(140deg, var(--navy-2), var(--navy-3));
  display: grid; place-items: center;
}
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .55s var(--ease); }
.card:hover .card-media img { transform: scale(1.07); }
.card-media .placeholder { color: rgba(255, 255, 255, .5); }
.card-media .placeholder svg { width: 54px; height: 54px; }

.card-meta {
  display: flex; align-items: center; gap: 14px; flex-wrap: wrap;
  font-size: .83rem; color: var(--muted);
  padding-top: 12px; border-top: 1px dashed var(--line); margin-top: auto;
}
.card-meta span { display: inline-flex; align-items: center; gap: 6px; }
.card-meta svg { width: 14px; height: 14px; color: var(--gold-ink); }

.chip {
  position: absolute; inset-inline-start: 14px; top: 14px; z-index: 2;
  background: rgba(11, 31, 58, .86); color: #fff;
  font-size: .76rem; font-weight: 700; padding: 5px 13px; border-radius: 999px;
  backdrop-filter: blur(6px);
}
.play-btn {
  position: absolute; inset: 0; margin: auto;
  width: 66px; height: 66px; border-radius: 50%;
  background: rgba(255, 255, 255, .92); color: var(--navy);
  display: grid; place-items: center; border: none; cursor: pointer;
  box-shadow: 0 12px 30px rgba(0, 0, 0, .35);
  transition: transform .3s var(--ease);
}
.play-btn::after {
  content: ""; position: absolute; inset: -10px; border-radius: 50%;
  border: 2px solid rgba(255, 255, 255, .5); animation: pulse 2.4s infinite;
}
.card:hover .play-btn { transform: scale(1.1); }
.play-btn svg { width: 26px; height: 26px; margin-inline-start: 4px; }
@keyframes pulse { 0% { transform: scale(.9); opacity: .9; } 70% { transform: scale(1.35); opacity: 0; } 100% { opacity: 0; } }

.duration {
  position: absolute; inset-inline-end: 12px; bottom: 12px;
  background: rgba(0, 0, 0, .78); color: #fff; font-size: .76rem;
  padding: 3px 9px; border-radius: 6px; font-variant-numeric: tabular-nums;
}

/* ------------------------------ services -------------------------- */
.service {
  position: relative; background: var(--paper);
  border: 1px solid var(--line); border-radius: var(--radius);
  padding: 34px 28px; overflow: hidden;
  transition: .35s var(--ease);
}
.service::before {
  content: ""; position: absolute; inset-inline-start: 0; top: 0; bottom: 0; width: 4px;
  background: linear-gradient(var(--gold), var(--gold-2)); transform: scaleY(0);
  transform-origin: top; transition: transform .4s var(--ease);
}
.service:hover { transform: translateY(-6px); box-shadow: var(--shadow); }
.service:hover::before { transform: scaleY(1); }
.service-icon {
  width: 62px; height: 62px; border-radius: 18px; display: grid; place-items: center;
  background: linear-gradient(140deg, rgba(201, 162, 39, .16), rgba(201, 162, 39, .06));
  color: var(--gold-ink); margin-bottom: 18px;
  transition: .35s var(--ease);
}
.service:hover .service-icon { background: linear-gradient(140deg, var(--navy), var(--navy-3)); color: var(--gold-2); transform: rotate(-6deg); }
.service-icon svg { width: 30px; height: 30px; }
.service h3 { font-size: 1.14rem; }
.service p { color: var(--muted); font-size: .94rem; margin: 0 0 14px; }

/* ------------------------------ stats ----------------------------- */
.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px; }
.stat {
  text-align: center; padding: 30px 16px; border-radius: var(--radius);
  background: rgba(255, 255, 255, .06); border: 1px solid rgba(255, 255, 255, .12);
}
.stat strong { display: block; font-size: 2.3rem; font-weight: 900; color: var(--gold-2); line-height: 1.2; }
.stat span { font-size: .9rem; color: #b6c2d6; }

/* ------------------------------ steps ----------------------------- */
.steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; counter-reset: step; }
.step { position: relative; padding-top: 22px; }
.step::before {
  counter-increment: step; content: counter(step, decimal-leading-zero);
  font-size: 3rem; font-weight: 900; color: rgba(201, 162, 39, .22);
  line-height: 1; display: block; margin-bottom: 8px;
}
.step h4 { font-size: 1.06rem; margin-bottom: 6px; }
.step p { color: var(--muted); font-size: .92rem; margin: 0; }
.step::after {
  content: ""; position: absolute; top: 34px; inset-inline-end: -14px;
  width: 26px; height: 2px; background: var(--line);
}

/* ---------------------------- page header ------------------------- */
.page-head {
  background:
    radial-gradient(700px 320px at 90% -30%, rgba(201, 162, 39, .3), transparent 62%),
    linear-gradient(150deg, var(--navy) 0%, var(--navy-2) 55%, var(--navy-3) 100%);
  color: #fff; padding: 60px 0 58px; position: relative; overflow: hidden;
}
.page-head::after {
  content: ""; position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255, 255, 255, .07) 1px, transparent 1px);
  background-size: 26px 26px; opacity: .5; pointer-events: none;
}
.page-head .container { position: relative; z-index: 2; }
.page-head h1 { color: #fff; font-size: clamp(1.8rem, 4vw, 2.7rem); margin-bottom: 10px; }
.page-head p { color: #bcc7da; max-width: 640px; margin: 0; }
.breadcrumb { display: flex; gap: 8px; flex-wrap: wrap; font-size: .87rem; color: #9fadc4; margin-bottom: 14px; }
.breadcrumb a { color: var(--gold-2); }
.breadcrumb span::before { content: "/"; margin-inline-end: 8px; opacity: .55; }

/* ----------------------------- filters ---------------------------- */
.toolbar {
  display: flex; gap: 14px; flex-wrap: wrap; align-items: center;
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); padding: 16px; margin-bottom: 30px;
  box-shadow: var(--shadow-sm);
}
.toolbar .field { flex: 1 1 200px; margin: 0; }
.search-box { position: relative; flex: 2 1 260px; }
.search-box input { padding-inline-start: 44px; }
.search-box svg {
  position: absolute; inset-inline-start: 15px; top: 50%; transform: translateY(-50%);
  width: 18px; height: 18px; color: var(--muted); pointer-events: none;
}

/* ------------------------------ forms ----------------------------- */
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 20px; }
.form-grid .span-2 { grid-column: 1 / -1; }

.field { display: flex; flex-direction: column; gap: 7px; margin-bottom: 18px; }
.field label { font-weight: 700; font-size: .92rem; color: var(--navy); }
.field label .req { color: var(--danger); }
.field .hint { font-size: .8rem; color: var(--muted); }

.input, .select, .textarea {
  width: 100%; padding: 13px 16px;
  background: #fff; border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  transition: border-color .2s, box-shadow .2s, background .2s;
  font-size: .97rem;
}
.input:hover, .select:hover, .textarea:hover { border-color: #cfcabb; }
.input:focus, .select:focus, .textarea:focus {
  outline: none; border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(201, 162, 39, .16);
}
.textarea { min-height: 130px; resize: vertical; line-height: 1.8; }
.select {
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%236b7688'%3E%3Cpath d='M8 11L3 6h10z'/%3E%3C/svg%3E");
  background-repeat: no-repeat; background-position: left 14px center; background-size: 14px;
  padding-inline-end: 16px; padding-inline-start: 40px;
}
.input[readonly], .input[disabled], .select[disabled] { background: #f2f0ea; color: var(--muted); }

.checkbox, .radio { display: flex; align-items: center; gap: 10px; cursor: pointer; font-size: .95rem; }
.checkbox input, .radio input { width: 18px; height: 18px; accent-color: var(--gold); cursor: pointer; }

.field-error {
  display: flex; align-items: center; gap: 7px;
  background: rgba(192, 57, 43, .09); border: 1px solid rgba(192, 57, 43, .28);
  color: #a02a1d; padding: 10px 14px; border-radius: var(--radius-sm);
  font-size: .9rem; font-weight: 600;
}
.field-error::before { content: "!"; display: grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; background: var(--danger); color: #fff; font-size: .75rem; flex: none; }
.alert {
  display: flex; align-items: flex-start; gap: 12px;
  padding: 15px 18px; border-radius: var(--radius-sm);
  font-size: .95rem; margin-bottom: 20px; border: 1px solid;
}
.alert svg { width: 20px; height: 20px; flex: none; margin-top: 3px; }
.alert-success { background: rgba(23, 145, 91, .09); border-color: rgba(23, 145, 91, .3); color: #0f6b43; }
.alert-info { background: rgba(37, 99, 168, .09); border-color: rgba(37, 99, 168, .3); color: #1c4f85; }
.alert-warning { background: rgba(183, 121, 31, .1); border-color: rgba(183, 121, 31, .3); color: #8a5a13; }
.alert-danger { background: rgba(192, 57, 43, .09); border-color: rgba(192, 57, 43, .3); color: #a02a1d; }

/* file drop zone */
.dropzone {
  border: 2px dashed #cfcabb; border-radius: var(--radius);
  background: #fff; padding: 34px 22px; text-align: center;
  transition: .25s var(--ease); cursor: pointer;
}
.dropzone:hover, .dropzone.is-over { border-color: var(--gold); background: rgba(201, 162, 39, .06); }
.dropzone svg { width: 40px; height: 40px; color: var(--gold-ink); margin-inline: auto; margin-bottom: 10px; }
.dropzone strong { display: block; color: var(--navy); }
.dropzone small { color: var(--muted); }

.file-list { display: grid; gap: 10px; margin-top: 16px; }
.file-item {
  display: flex; align-items: center; gap: 12px;
  background: #fff; border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 11px 15px; font-size: .92rem;
}
.file-item svg { width: 20px; height: 20px; color: var(--gold-ink); flex: none; }
.file-item .fi-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-item .fi-size { color: var(--muted); font-size: .82rem; }
.file-item .fi-remove {
  border: none; background: rgba(192, 57, 43, .1); color: var(--danger);
  width: 28px; height: 28px; border-radius: 8px; cursor: pointer; font-weight: 900;
}
.file-item .fi-remove:hover { background: var(--danger); color: #fff; }

/* ---------------------------- pagination -------------------------- */
.pagination { display: flex; gap: 8px; justify-content: center; flex-wrap: wrap; margin-top: 40px; }
.page-item {
  min-width: 42px; height: 42px; display: grid; place-items: center;
  background: #fff; border: 1.5px solid var(--line); border-radius: 12px;
  font-weight: 700; font-size: .93rem; transition: .2s;
}
a.page-item:hover { border-color: var(--navy); background: var(--navy); color: #fff; }
.page-item.active { background: var(--navy); border-color: var(--navy); color: #fff; }
.page-item.disabled { opacity: .45; pointer-events: none; }
.page-link { display: grid; place-items: center; width: 100%; height: 100%; padding: 0 12px; color: inherit; }
li.page-item.active .page-link, li.page-item .page-link { color: inherit; }
li.page-item.active a.page-link { color: #fff; }
li.page-item a.page-link:hover { color: #fff; }

/* ------------------------------ badges ---------------------------- */
.badge-success, .badge-danger, .badge-warning, .badge-info, .badge-muted {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 4px 13px; border-radius: 999px;
  font-size: .78rem; font-weight: 800; white-space: nowrap;
}
.badge-success { background: rgba(23, 145, 91, .13); color: #0f6b43; }
.badge-danger { background: rgba(192, 57, 43, .13); color: #a02a1d; }
.badge-warning { background: rgba(183, 121, 31, .15); color: #8a5a13; }
.badge-info { background: rgba(37, 99, 168, .13); color: #1c4f85; }
.badge-muted { background: rgba(107, 118, 136, .14); color: #525d70; }

/* ------------------------------ tabs ------------------------------ */
.tabs { display: flex; gap: 6px; flex-wrap: wrap; border-bottom: 2px solid var(--line); margin-bottom: 26px; }
.tab {
  padding: 12px 22px; border: none; background: transparent;
  font-weight: 700; font-size: .95rem; color: var(--muted);
  cursor: pointer; border-radius: 12px 12px 0 0; position: relative;
  transition: .2s;
}
.tab::after {
  content: ""; position: absolute; inset-inline: 12px; bottom: -2px; height: 3px;
  background: var(--gold); border-radius: 3px; transform: scaleX(0); transition: transform .3s var(--ease);
}
.tab:hover { color: var(--navy); background: rgba(11, 31, 58, .04); }
.tab.is-active { color: var(--navy); }
.tab.is-active::after { transform: scaleX(1); }
.tab .count {
  display: inline-grid; place-items: center; min-width: 22px; height: 22px;
  padding: 0 6px; margin-inline-start: 6px; border-radius: 999px;
  background: rgba(11, 31, 58, .09); font-size: .75rem;
}

/* MyPage tab panes: only the active pane is rendered */
.tab-pane { display: none; }
.tab-pane.active { display: block; }

/* consultation thread (client MyPage + admin details) */
.thread { display: flex; flex-direction: column; gap: 12px; }
.msg {
  max-width: 82%; padding: 12px 16px; border-radius: 14px;
  border: 1px solid var(--line); background: var(--paper);
}
.msg-client { align-self: flex-start; }
.msg-office { align-self: flex-end; background: var(--ivory); border-color: rgba(201, 162, 39, .45); }
.msg-head { display: flex; justify-content: space-between; gap: 14px; margin-bottom: 6px; font-size: .85rem; }
.msg-body { line-height: 1.75; white-space: pre-wrap; word-break: break-word; }
.reply-box { border-top: 1px dashed var(--line); padding-top: 18px; margin-top: 22px; }
.kv-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 14px; }
.kv-grid .kv { padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: #fcfbf8; }

/* ------------------------- client dashboard ----------------------- */
.profile-hero {
  display: flex; align-items: center; gap: 22px; flex-wrap: wrap;
  padding: 30px 32px; margin-bottom: 24px;
  background: linear-gradient(120deg, var(--navy), var(--navy-3));
  border-radius: var(--radius-lg); color: #fff; box-shadow: var(--shadow-sm);
}
.profile-hero-avatar {
  width: 66px; height: 66px; border-radius: 50%; flex: 0 0 auto;
  display: grid; place-items: center; font-size: 1.7rem; font-weight: 800;
  background: var(--gold); color: var(--navy);
}
.profile-hero-info h2 { margin: 0 0 4px; font-size: 1.35rem; color: #fff; }
.profile-hero-info p { margin: 0; color: rgba(255,255,255,.75); font-size: .95rem; }
.profile-hero-actions { margin-inline-start: auto; display: flex; gap: 10px; flex-wrap: wrap; }
.profile-hero-actions .btn { background: rgba(255,255,255,.12); border-color: rgba(255,255,255,.25); color: #fff; }
.profile-hero-actions .btn:hover { background: rgba(255,255,255,.24); }

.stat-strip { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; margin-bottom: 28px; }
.stat-box {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 20px 22px; display: flex; align-items: center; gap: 14px;
}
.stat-box .stat-ico {
  width: 46px; height: 46px; border-radius: 12px; flex: 0 0 auto;
  display: grid; place-items: center; background: rgba(11,31,58,.06); color: var(--navy);
}
.stat-box b { display: block; font-size: 1.5rem; line-height: 1.15; }
.stat-box span { font-size: .85rem; color: var(--muted); }

.mp-tabs {
  display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 26px;
  padding: 6px; background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
}
.mp-tab {
  border: none; background: transparent; cursor: pointer; font-family: inherit;
  padding: 12px 20px; border-radius: 12px; font-weight: 700; font-size: .95rem;
  color: var(--muted); transition: .2s;
}
.mp-tab:hover { background: rgba(11,31,58,.05); color: var(--navy); }
.mp-tab.active { background: var(--navy); color: #fff; }
.mp-tab .count {
  display: inline-grid; place-items: center; min-width: 22px; height: 22px; padding: 0 6px;
  margin-inline-start: 6px; border-radius: 999px; font-size: .75rem;
  background: rgba(11,31,58,.12); color: var(--navy);
}
.mp-tab.active .count { background: rgba(255,255,255,.22); color: #fff; }

.mp-pane { display: none; }
.mp-pane.active { display: block; animation: fadeUp .28s var(--ease); }
@keyframes fadeUp { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

.quick-cards { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-bottom: 24px; }
.quick-card {
  display: block; padding: 20px 22px; border-radius: var(--radius);
  background: var(--paper); border: 1px solid var(--line);
  transition: .22s; text-decoration: none; color: var(--ink);
}
.quick-card:hover { border-color: var(--navy); box-shadow: var(--shadow-sm); transform: translateY(-2px); }
.quick-card b { display: flex; align-items: center; gap: 10px; font-size: 1.02rem; }
.quick-card b i { font-style: normal; width: 38px; height: 38px; display: grid; place-items: center; border-radius: 10px; background: rgba(201,162,39,.15); color: var(--gold-ink); }
.quick-card p { margin: 8px 0 0; color: var(--muted); font-size: .88rem; }

/* ------------------------- modal ------------------------- */
.modal-backdrop {
  position: fixed; inset: 0; z-index: 1500; padding: 20px;
  background: rgba(11,31,58,.58); backdrop-filter: blur(3px);
  display: none; align-items: center; justify-content: center;
}
.modal-backdrop.open { display: flex; }
.modal {
  width: 100%; max-width: 780px; max-height: min(88vh, 780px);
  background: var(--paper); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-lg); overflow: hidden;
  display: flex; flex-direction: column; animation: popIn .25s var(--ease);
}
@keyframes popIn { from { opacity: 0; transform: scale(.96) translateY(12px); } to { opacity: 1; transform: none; } }
.modal-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 24px; background: var(--navy); color: #fff;
}
.modal-head h3 { margin: 0; font-size: 1.08rem; color: #fff; }
.modal-head h3 small { font-weight: 400; color: rgba(255,255,255,.7); }
.modal-close {
  border: none; cursor: pointer; flex: 0 0 auto;
  width: 36px; height: 36px; border-radius: 50%;
  background: rgba(255,255,255,.15); color: #fff; font-size: 1.25rem; line-height: 1;
  transition: .2s;
}
.modal-close:hover { background: rgba(255,255,255,.3); }
.modal-body { padding: 24px; overflow-y: auto; }
body.modal-open { overflow: hidden; }

@media (max-width: 860px) {
  .stat-strip { grid-template-columns: repeat(2, 1fr); }
  .quick-cards { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  .stat-strip { grid-template-columns: 1fr; }
  .profile-hero-actions { margin-inline-start: 0; }
}

/* ------------------------- panels / list -------------------------- */
.panel {
  background: var(--paper); border: 1px solid var(--line);
  border-radius: var(--radius); overflow: hidden; margin-bottom: 24px;
}
.panel-head {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 18px 24px; border-bottom: 1px solid var(--line);
  background: #fcfbf8; flex-wrap: wrap;
}
.panel-head h3 { margin: 0; font-size: 1.06rem; }
.panel-body { padding: 24px; }

.list-item {
  display: flex; gap: 18px; align-items: flex-start;
  padding: 20px 24px; border-bottom: 1px solid var(--line);
  transition: background .2s;
}
.list-item:last-child { border-bottom: none; }
.list-item:hover { background: #fcfbf8; }
.list-item .li-icon {
  width: 46px; height: 46px; flex: none; border-radius: 14px;
  background: rgba(201, 162, 39, .13); color: var(--gold-ink);
  display: grid; place-items: center;
}
.list-item .li-icon svg { width: 22px; height: 22px; }
.list-item .li-main { flex: 1; min-width: 0; }
.list-item .li-main strong { display: block; color: var(--navy); font-size: 1.01rem; }
.list-item .li-main p { margin: 4px 0 0; color: var(--muted); font-size: .9rem; }
.list-item .li-side { text-align: end; display: flex; flex-direction: column; gap: 6px; align-items: flex-end; }

/* ------------------------------ chat ------------------------------ */
.chat { display: flex; flex-direction: column; gap: 16px; max-height: 520px; overflow-y: auto; padding: 4px 2px 16px; }
.bubble {
  max-width: 78%; padding: 13px 18px; border-radius: 18px;
  font-size: .95rem; line-height: 1.8; position: relative;
  box-shadow: var(--shadow-sm);
}
.bubble .who { display: block; font-size: .78rem; font-weight: 800; margin-bottom: 4px; opacity: .8; }
.bubble .when { display: block; font-size: .72rem; margin-top: 6px; opacity: .65; }
.bubble-client { align-self: flex-start; background: #fff; border: 1px solid var(--line); border-start-start-radius: 6px; }
.bubble-office { align-self: flex-end; background: linear-gradient(135deg, var(--navy), var(--navy-3)); color: #fff; border-start-end-radius: 6px; }
.bubble-admin { align-self: flex-end; background: linear-gradient(135deg, var(--gold), var(--gold-2)); color: #2c2103; border-start-end-radius: 6px; }

/* ------------------------------ tables ---------------------------- */
.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
table.data {
  width: 100%; border-collapse: collapse; font-size: .93rem; min-width: 640px;
}
table.data thead th {
  background: #f5f3ee; color: var(--navy); font-weight: 800; font-size: .83rem;
  text-align: start; padding: 13px 16px; border-bottom: 2px solid var(--line);
  white-space: nowrap;
}
table.data tbody td { padding: 14px 16px; border-bottom: 1px solid var(--line); vertical-align: middle; }
table.data tbody tr:hover { background: #fcfbf8; }
table.data tbody tr:last-child td { border-bottom: none; }
table.data .empty { text-align: center; padding: 44px 16px; color: var(--muted); }

/* ------------------------- empty state ---------------------------- */
.empty-state { text-align: center; padding: 56px 24px; color: var(--muted); }
.empty-state svg { width: 66px; height: 66px; color: #cfcabb; margin-inline: auto; margin-bottom: 14px; }
.empty-state h3 { color: var(--navy); font-size: 1.15rem; margin-bottom: 6px; }
.empty-state p { margin-bottom: 18px; }

/* --------------------------- pagination note ---------------------- */
.load-note { text-align: center; color: var(--muted); font-size: .88rem; margin-top: 16px; }

/* ------------------------------ footer ---------------------------- */
.footer {
  background: linear-gradient(160deg, #081729 0%, var(--navy) 55%, var(--navy-2) 100%);
  color: #a9b5c9; padding: 70px 0 0; position: relative; overflow: hidden;
}
.footer::before {
  content: ""; position: absolute; inset-inline-start: -80px; top: -80px;
  width: 300px; height: 300px; border-radius: 50%;
  background: radial-gradient(circle, rgba(201, 162, 39, .22), transparent 70%);
}
.footer .container { position: relative; z-index: 2; }
.footer-grid { display: grid; grid-template-columns: 1.5fr 1fr 1fr 1.4fr; gap: 40px; }
.footer h4 { color: #fff; font-size: 1.04rem; margin-bottom: 18px; position: relative; padding-bottom: 12px; }
.footer h4::after { content: ""; position: absolute; inset-inline-start: 0; bottom: 0; width: 38px; height: 3px; background: var(--gold); border-radius: 3px; }
.footer p { font-size: .93rem; line-height: 1.9; }
.footer-links li { margin-bottom: 11px; }
.footer-links a { display: inline-flex; align-items: center; gap: 9px; font-size: .93rem; transition: .22s; }
.footer-links a::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: rgba(201, 162, 39, .55); transition: .22s; }
.footer-links a:hover { color: var(--gold-2); transform: translateX(-5px); }
.footer-links a:hover::before { background: var(--gold); }
.footer-contact li { display: flex; gap: 12px; align-items: flex-start; margin-bottom: 14px; font-size: .93rem; }
.footer-contact svg { width: 19px; height: 19px; color: var(--gold); flex: none; margin-top: 4px; }
.footer-bottom {
  margin-top: 52px; padding: 22px 0; border-top: 1px solid rgba(255, 255, 255, .1);
  display: flex; justify-content: space-between; align-items: center; gap: 16px; flex-wrap: wrap;
  font-size: .87rem;
}
.footer-bottom a:hover { color: var(--gold-2); }
.footer-social { display: flex; gap: 9px; }
.footer-social a {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center;
  background: rgba(255, 255, 255, .07); color: #a9b5c9; transition: .25s var(--ease);
}
.footer-social a:hover { background: var(--gold); color: var(--navy); transform: translateY(-4px); }
.footer-social svg { width: 17px; height: 17px; }

/* --------------------------- toast / flash ------------------------ */
.toast-holder { position: fixed; inset-inline-start: 50%; top: 22px; transform: translateX(50%); z-index: 2000; display: grid; gap: 10px; width: min(92vw, 520px); }
.toast-msg {
  background: var(--navy); color: #fff; padding: 14px 22px;
  border-radius: 14px; box-shadow: var(--shadow-lg);
  font-weight: 700; font-size: .95rem; text-align: center;
  border-inline-start: 5px solid var(--gold);
  animation: drop .45s var(--ease);
}
.toast-success { background: #0f6b43; border-color: #7ee0b3; }
.toast-error { background: #8f231a; border-color: #ffb3a8; }
@keyframes drop { from { opacity: 0; transform: translateY(-24px); } to { opacity: 1; transform: none; } }

/* ------------------------- auth / cta box ------------------------- */
.auth-wrap { min-height: calc(100vh - var(--nav-h)); display: grid; grid-template-columns: 1fr 1fr; }
.auth-aside {
  background:
    radial-gradient(700px 500px at 80% 20%, rgba(201, 162, 39, .3), transparent 60%),
    linear-gradient(150deg, var(--navy) 0%, var(--navy-3) 100%);
  color: #fff; padding: 70px 56px; display: flex; flex-direction: column; justify-content: center; position: relative; overflow: hidden;
}
.auth-aside::after {
  content: ""; position: absolute; inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, .05) 1px, transparent 1px), linear-gradient(90deg, rgba(255, 255, 255, .05) 1px, transparent 1px);
  background-size: 54px 54px; opacity: .6;
}
.auth-aside > * { position: relative; z-index: 2; }
.auth-aside h2 { color: #fff; font-size: clamp(1.6rem, 3vw, 2.3rem); }
.auth-aside p { color: #bcc7da; }
.auth-aside .hero-list { margin-top: 26px; }
.auth-main { display: grid; place-items: center; padding: 60px 28px; background: var(--ivory); }
.auth-card { width: 100%; max-width: 460px; background: #fff; border: 1px solid var(--line); border-radius: 22px; padding: 40px 34px; box-shadow: var(--shadow); }
.auth-card h1 { font-size: 1.6rem; margin-bottom: 6px; }
.auth-card > p.sub { color: var(--muted); margin-bottom: 26px; font-size: .95rem; }
.auth-alt { text-align: center; margin-top: 22px; font-size: .93rem; color: var(--muted); }
.auth-alt a { color: var(--gold-ink); font-weight: 800; }

.cta-band {
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-2) 100%);
  color: #2c2103; border-radius: var(--radius-lg); padding: 46px 44px;
  display: flex; align-items: center; justify-content: space-between; gap: 30px; flex-wrap: wrap;
  position: relative; overflow: hidden; box-shadow: 0 24px 50px rgba(201, 162, 39, .32);
}
.cta-band::after {
  content: ""; position: absolute; inset-inline-end: -50px; top: -50px;
  width: 220px; height: 220px; border-radius: 50%; background: rgba(255, 255, 255, .22);
}
.cta-band h2 { color: #2c2103; margin: 0 0 6px; font-size: clamp(1.4rem, 3vw, 2rem); position: relative; z-index: 2; }
.cta-band p { margin: 0; color: #4a3a09; position: relative; z-index: 2; }
.cta-band .btn { position: relative; z-index: 2; --btn-bg: var(--navy); --btn-fg: #fff; }

/* -------------------------- article body -------------------------- */
.prose { font-size: 1.03rem; line-height: 2.1; color: #2a3547; }
.prose h2 { font-size: 1.45rem; margin-top: 1.7em; margin-bottom: .5em; color: var(--navy); }
.prose h3 { font-size: 1.2rem; margin-top: 1.5em; }
.prose p { margin-bottom: 1.15em; }
.prose ul, .prose ol { padding-inline-start: 26px; margin-bottom: 1.15em; }
.prose ul { list-style: disc; }
.prose ol { list-style: decimal; }
.prose li { margin-bottom: .5em; }
.prose a { color: var(--gold-ink); text-decoration: underline; }
.prose blockquote {
  margin: 1.6em 0; padding: 18px 24px; background: #fff;
  border-inline-start: 4px solid var(--gold); border-radius: 0 14px 14px 0;
  color: var(--navy); font-weight: 600; box-shadow: var(--shadow-sm);
}
.prose img { border-radius: var(--radius); margin: 1.4em 0; }
.prose table { width: 100%; border-collapse: collapse; margin: 1.4em 0; }
.prose table th, .prose table td { border: 1px solid var(--line); padding: 10px 14px; }
.prose table th { background: #f5f3ee; }

.article-layout { display: grid; grid-template-columns: 1fr 330px; gap: 40px; align-items: start; }
.article-cover { border-radius: var(--radius); overflow: hidden; margin-bottom: 28px; box-shadow: var(--shadow); }
.article-cover img { width: 100%; aspect-ratio: 16 / 8; object-fit: cover; }
.article-meta {
  display: flex; gap: 18px; flex-wrap: wrap; align-items: center;
  padding: 16px 0 22px; margin-bottom: 24px; border-bottom: 1px solid var(--line);
  color: var(--muted); font-size: .9rem;
}
.article-meta span { display: inline-flex; align-items: center; gap: 7px; }
.article-meta svg { width: 16px; height: 16px; color: var(--gold-ink); }

.side-card { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; margin-bottom: 22px; }
.side-card h4 { font-size: 1.04rem; padding-bottom: 12px; margin-bottom: 16px; border-bottom: 2px solid var(--line); }
.side-list li { padding: 12px 0; border-bottom: 1px dashed var(--line); font-size: .93rem; }
.side-list li:last-child { border-bottom: none; }
.side-list a { display: flex; gap: 12px; align-items: flex-start; transition: .2s; }
.side-list a:hover { color: var(--gold-ink); }
.side-list .num { color: var(--gold); font-weight: 900; font-size: 1.05rem; line-height: 1.3; }

.tag-cloud { display: flex; flex-wrap: wrap; gap: 8px; }
.tag-cloud a {
  padding: 6px 15px; background: #f4f2ec; border: 1px solid var(--line);
  border-radius: 999px; font-size: .84rem; font-weight: 700; transition: .2s;
}
.tag-cloud a:hover { background: var(--navy); color: #fff; border-color: var(--navy); }

/* --------------------------- video player ------------------------- */
.player-shell {
  background: #000; border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow-lg); aspect-ratio: 16 / 9; position: relative;
}
.player-shell video { width: 100%; height: 100%; object-fit: contain; background: #000; }

/* --------------------------- payment ------------------------------ */
.pay-summary {
  background: linear-gradient(150deg, var(--navy), var(--navy-3));
  color: #fff; border-radius: var(--radius); padding: 28px; position: sticky; top: 96px;
}
.pay-summary h3 { color: #fff; font-size: 1.08rem; }
.pay-row { display: flex; justify-content: space-between; gap: 14px; padding: 11px 0; border-bottom: 1px dashed rgba(255, 255, 255, .16); font-size: .94rem; }
.pay-row:last-of-type { border-bottom: none; }
.pay-row span:first-child { color: #b6c2d6; }
.pay-total {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: 14px; padding-top: 16px; border-top: 2px solid rgba(201, 162, 39, .55);
  font-size: 1.35rem; font-weight: 900; color: var(--gold-2);
}
.pay-methods { display: grid; gap: 14px; }
.pay-method {
  display: flex; align-items: center; gap: 16px; cursor: pointer;
  background: #fff; border: 2px solid var(--line); border-radius: var(--radius);
  padding: 20px 22px; transition: .25s var(--ease);
}
.pay-method:hover { border-color: #cfcabb; transform: translateY(-2px); }
.pay-method.is-active { border-color: var(--gold); box-shadow: 0 0 0 4px rgba(201, 162, 39, .15); background: rgba(201, 162, 39, .04); }
.pay-method input { accent-color: var(--gold); width: 20px; height: 20px; }
.pay-method .pm-icon {
  width: 50px; height: 50px; border-radius: 14px; flex: none;
  background: rgba(11, 31, 58, .07); color: var(--navy);
  display: grid; place-items: center;
}
.pay-method.is-active .pm-icon { background: var(--navy); color: var(--gold-2); }
.pay-method .pm-icon svg { width: 24px; height: 24px; }
.pay-method strong { display: block; color: var(--navy); }
.pay-method small { color: var(--muted); }

.card-visual {
  background: linear-gradient(135deg, var(--navy) 0%, var(--navy-3) 70%, #24507f 100%);
  border-radius: 20px; padding: 26px 28px; color: #fff;
  box-shadow: var(--shadow); position: relative; overflow: hidden; margin-bottom: 24px;
}
.card-visual::after {
  content: ""; position: absolute; inset-inline-end: -40px; bottom: -70px;
  width: 190px; height: 190px; border-radius: 50%; background: rgba(201, 162, 39, .3);
}
.card-visual .cv-number {
  font-size: clamp(1.1rem, 3vw, 1.5rem); letter-spacing: .14em;
  font-variant-numeric: tabular-nums; margin: 24px 0 16px; direction: ltr; text-align: left;
}
.card-visual .cv-foot { display: flex; justify-content: space-between; font-size: .82rem; color: #c3ccdb; }
.card-visual .cv-chip {
  width: 44px; height: 32px; border-radius: 7px;
  background: linear-gradient(140deg, var(--gold-2), var(--gold));
}

.result-wrap { max-width: 640px; margin: 0 auto; text-align: center; }
.result-icon {
  width: 106px; height: 106px; border-radius: 50%; margin: 0 auto 24px;
  display: grid; place-items: center; font-size: 3rem; color: #fff;
  box-shadow: 0 20px 40px rgba(23, 145, 91, .32);
  background: linear-gradient(140deg, var(--ok), #0d7a4e);
}
.result-icon.is-fail { background: linear-gradient(140deg, var(--danger), #8f231a); box-shadow: 0 20px 40px rgba(192, 57, 43, .3); }
.result-icon svg { width: 52px; height: 52px; }
.result-box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 36px; box-shadow: var(--shadow); }

/* ------------------------- dashboard bits ------------------------- */
.dash-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(215px, 1fr)); gap: 18px; }
.dash-card {
  background: #fff; border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; display: flex; gap: 16px; align-items: center;
  transition: .3s var(--ease);
}
.dash-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.dash-card .dc-icon {
  width: 54px; height: 54px; flex: none; border-radius: 16px;
  display: grid; place-items: center; color: #fff;
  background: linear-gradient(140deg, var(--navy), var(--navy-3));
}
.dash-card .dc-icon.gold { background: linear-gradient(140deg, var(--gold), var(--gold-2)); color: #2c2103; }
.dash-card .dc-icon.green { background: linear-gradient(140deg, var(--ok), #0d7a4e); }
.dash-card .dc-icon.red { background: linear-gradient(140deg, var(--danger), #8f231a); }
.dash-card .dc-icon svg { width: 26px; height: 26px; }
.dash-card strong { display: block; font-size: 1.6rem; font-weight: 900; color: var(--navy); line-height: 1.25; }
.dash-card span { font-size: .87rem; color: var(--muted); }

.notif {
  display: flex; gap: 14px; padding: 15px 18px; border-radius: 14px;
  background: #fff; border: 1px solid var(--line); border-inline-start: 4px solid var(--line);
  margin-bottom: 12px;
}
.notif.is-unread { border-inline-start-color: var(--gold); background: rgba(201, 162, 39, .05); }
.notif strong { display: block; color: var(--navy); font-size: .96rem; }
.notif p { margin: 3px 0 0; color: var(--muted); font-size: .89rem; }
.notif time { font-size: .78rem; color: var(--muted); }

/* ------------------------------ misc ------------------------------ */
.divider { height: 1px; background: var(--line); margin: 26px 0; }
.kv { display: grid; grid-template-columns: 150px 1fr; gap: 10px 18px; font-size: .95rem; }
.kv dt { color: var(--muted); }
.kv dd { margin: 0; font-weight: 700; color: var(--navy); }

.protected-note {
  background: #fff; border: 1px dashed var(--line); border-radius: var(--radius);
  padding: 16px 20px; font-size: .9rem; color: var(--muted);
}

.scroll-top {
  position: fixed; inset-inline-end: 22px; bottom: 22px; z-index: 800;
  width: 48px; height: 48px; border-radius: 50%; border: none; cursor: pointer;
  background: var(--navy); color: var(--gold-2);
  display: grid; place-items: center; box-shadow: var(--shadow);
  opacity: 0; visibility: hidden; transform: translateY(14px); transition: .3s var(--ease);
}
.scroll-top.is-visible { opacity: 1; visibility: visible; transform: none; }
.scroll-top:hover { background: var(--gold); color: var(--navy); }
.scroll-top svg { width: 20px; height: 20px; }

.progress { height: 8px; background: #ece9e1; border-radius: 999px; overflow: hidden; }
.progress > span { display: block; height: 100%; background: linear-gradient(90deg, var(--gold), var(--gold-2)); border-radius: 999px; }

/* ============================ responsive =========================== */
@media (max-width: 1100px) {
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .article-layout { grid-template-columns: 1fr; }
  .steps { grid-template-columns: repeat(2, 1fr); }
  .step::after { display: none; }
}

@media (max-width: 992px) {
  .hero { padding: 74px 0 88px; }
  .hero .container { grid-template-columns: 1fr; gap: 40px; }
  .hero-badge { inset-inline-start: auto; inset-inline-end: 16px; }
  .grid-4 { grid-template-columns: repeat(2, 1fr); }
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .auth-wrap { grid-template-columns: 1fr; }
  .auth-aside { padding: 54px 32px; }
  .section { padding: 64px 0; }
}

@media (max-width: 860px) {
  .nav-toggle { display: flex; }
  .nav-menu {
    position: fixed; inset-inline: 0; top: calc(var(--nav-h) + 38px);
    background: #fff; flex-direction: column; align-items: stretch;
    padding: 14px 18px 24px; gap: 4px;
    border-bottom: 1px solid var(--line); box-shadow: var(--shadow-lg);
    transform: translateY(-140%); transition: transform .38s var(--ease);
    max-height: calc(100vh - var(--nav-h) - 40px); overflow-y: auto;
    z-index: 950;
  }
  .nav-menu.is-open { transform: translateY(0); }
  .nav-menu a { padding: 14px 16px; border-radius: 12px; font-size: 1rem; border-bottom: 1px solid #f1efe9; }
  .nav-menu a::after { display: none; }
  .nav-menu a.is-active { background: rgba(201, 162, 39, .12); }
  .nav-actions .btn-nav-cta { display: none; }
  .user-chip span.uname { display: none; }
  .topbar-info span.hide-sm { display: none; }
}

@media (max-width: 768px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
  .form-grid { grid-template-columns: 1fr; }
  .stats { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: 1fr; }
  .cta-band { padding: 34px 26px; text-align: center; }
  .footer-grid { grid-template-columns: 1fr; gap: 30px; }
  .kv { grid-template-columns: 1fr; gap: 3px; }
  .kv dd { margin-bottom: 10px; }
  .bubble { max-width: 92%; }
  .section { padding: 52px 0; }
  .hero-facts { gap: 22px; }
  .hero-facts div strong { font-size: 1.5rem; }
}

@media (max-width: 560px) {
  body { font-size: 15.5px; }
  .container { padding-inline: 16px; }
  .stats { grid-template-columns: 1fr; }
  .brand-text small { display: none; }
  .topbar { font-size: .8rem; }
  .topbar-social { display: none; }
  .auth-card { padding: 30px 22px; }
  .panel-body { padding: 18px; }
  .list-item { padding: 16px; gap: 14px; }
  .btn { padding: 12px 22px; }
  .btn-lg { padding: 14px 26px; }
  .hero-cta .btn { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; transition-duration: .01ms !important; }
  html { scroll-behavior: auto; }
}

.plans-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 18px; }
.plan-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 22px; display: flex; flex-direction: column; gap: 10px; transition: .22s;
}
.plan-card:hover { border-color: var(--navy); box-shadow: var(--shadow-sm); transform: translateY(-2px); }
.plan-card h3 { margin: 0; font-size: 1.1rem; color: var(--navy); }
.plan-card .plan-desc { margin: 0; color: var(--muted, #667085); font-size: .92rem; min-height: 2.6em; }
.plan-card .plan-meta { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: 4px; }
.plan-card .plan-count { font-size: .9rem; color: var(--ink); background: rgba(201,162,39,.14); border-radius: 999px; padding: 4px 12px; }
.plan-card .plan-price { font-size: 1.25rem; color: var(--gold-ink); }
.plan-card .btn-block { margin-top: auto; text-align: center; }

.terms-doc { line-height: 2; color: var(--ink); }
.terms-doc-title { font-size: 1.5rem; font-weight: 800; color: var(--navy); text-align: center; margin: 6px 0 4px; }
.terms-doc-sub { text-align: center; color: var(--muted, #667085); font-size: .95rem; margin-bottom: 10px; }
.terms-doc-platform { text-align: center; font-weight: 700; color: var(--ink); margin-bottom: 2px; }
.terms-doc-date { text-align: center; color: var(--muted, #667085); font-size: .85rem; margin-bottom: 18px; }
.terms-doc h2.term-article {
  font-size: 1.15rem; color: var(--navy); margin: 26px 0 10px; padding: 8px 14px;
  background: rgba(201,162,39,.12); border-right: 4px solid var(--gold-ink); border-radius: var(--radius-sm);
}
.terms-doc h3.term-item { font-size: 1rem; color: var(--ink); margin: 16px 0 6px; font-weight: 700; }
.terms-doc p { margin: 8px 0; }
.terms-doc ul { margin: 6px 0 12px; padding-right: 22px; }
.terms-doc ul.term-sublist li { margin: 5px 0; }
.terms-doc ul.term-bullet li { margin: 5px 0; }
.terms-notice-label { font-weight: 800; color: #b4232a; margin: 14px 0 4px; }
.terms-notice {
  background: #fdf3f3; border: 1px solid #f0caca; border-right: 4px solid #b4232a;
  border-radius: var(--radius-sm); padding: 14px 18px; margin: 6px 0 12px;
}

.countries-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.country-card {
  background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 26px 18px; text-align: center; display: flex; flex-direction: column;
  align-items: center; gap: 12px; transition: .22s;
}
.country-card:hover { border-color: var(--navy); box-shadow: var(--shadow-sm); transform: translateY(-3px); }
.country-flag-img { width: 120px; height: 80px; object-fit: cover; border-radius: 8px; box-shadow: 0 2px 10px rgba(2,20,45,.18); display: block; background: #fff; }
.country-card strong { color: var(--navy); font-size: 1.08rem; }
@media (max-width: 760px) { .countries-grid { grid-template-columns: repeat(2, 1fr); } }

.brand-logo { height: 44px; width: auto; display: block; }
.brand-logo-lg { height: 76px; }

.hero-visual { display: flex; flex-direction: column; align-items: center; }
.hero-visual .hero-card { width: 100%; max-width: 450px; }
.hero-doctor {
  height: 420px; width: auto; display: block; margin-top: -24px;
  filter: drop-shadow(0 22px 44px rgba(0, 0, 0, .5));
}
@media (max-width: 1100px) { .hero-doctor { height: 360px; } }
@media (max-width: 760px) { .hero-doctor { height: 290px; margin-top: -12px; } }

.hero-doctor-wrap { display: flex; align-items: center; justify-content: center; min-height: 500px; width: 100%; }
@media (max-width: 1100px) { .hero-doctor-wrap { min-height: 420px; } }
@media (max-width: 760px) { .hero-doctor-wrap { min-height: 360px; } }
