/* =====================================================================
   Ask Shein — Ultra Premium Visual Skin
   ---------------------------------------------------------------------
   Presentation-only upgrade. This file keeps the existing PHP routes,
   form names, IDs, data attributes, sessions, storage and JS hooks intact.
   ===================================================================== */

/* 01. Design system */
:root {
  color-scheme: light;
  --white: #ffffff;
  --black: #07182f;
  --ink: #07182f;
  --ink-2: #0d2747;
  --text: #12243a;
  --muted: #617188;
  --muted-2: #7c8a9c;
  --page-bg: #f3f8fb;
  --surface: rgba(255, 255, 255, 0.82);
  --surface-strong: rgba(255, 255, 255, 0.96);
  --surface-soft: rgba(255, 255, 255, 0.62);
  --soft: #eef7fb;
  --soft-strong: #e0f0f7;
  --border: rgba(12, 45, 78, 0.12);
  --border-strong: rgba(12, 45, 78, 0.22);
  --cyan: #05a8c8;
  --cyan-deep: #087ea4;
  --teal: #12b8a6;
  --teal-deep: #0f766e;
  --blue: #2463eb;
  --indigo: #4f46e5;
  --violet: #7357f6;
  --success-bg: #e9fbf4;
  --success-border: #9fe9ca;
  --success-text: #057a55;
  --warning-bg: #fff4e8;
  --warning-border: #ffd0a3;
  --warning-text: #b45309;
  --danger-bg: #fff0f0;
  --danger-border: #ffb9b9;
  --danger-text: #b4232d;
  --shadow-soft: 0 14px 34px rgba(11, 56, 88, 0.08);
  --shadow: 0 28px 90px rgba(11, 56, 88, 0.15);
  --shadow-medium: 0 22px 58px rgba(11, 56, 88, 0.16);
  --shadow-strong: 0 36px 120px rgba(7, 24, 47, 0.23);
  --ring: 0 0 0 4px rgba(5, 168, 200, 0.16);
  --radius-card: 34px;
  --radius-panel: 26px;
  --radius-control: 18px;
  --radius-pill: 999px;
  --container: min(1180px, 92%);
  --font: system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", Tahoma, Arial, sans-serif;
}

/* 02. Reset and base */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  overflow-x: hidden;
  background:
    radial-gradient(circle at 8% -8%, rgba(18, 184, 166, 0.24), transparent 28rem),
    radial-gradient(circle at 94% 6%, rgba(79, 70, 229, 0.18), transparent 30rem),
    radial-gradient(circle at 52% 105%, rgba(5, 168, 200, 0.2), transparent 34rem),
    linear-gradient(135deg, #f7fbff 0%, #eef8fb 44%, #f8fbff 100%);
  color: var(--text);
  font-family: var(--font);
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body::before,
body::after {
  content: "";
  position: fixed;
  pointer-events: none;
  z-index: -3;
}

body::before {
  inset: 0;
  background-image:
    linear-gradient(rgba(7, 24, 47, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(7, 24, 47, 0.035) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: linear-gradient(to bottom, rgba(0, 0, 0, 0.86), transparent 88%);
}

body::after {
  width: 520px;
  height: 520px;
  inset-block-start: 16%;
  inset-inline-end: -220px;
  border-radius: 42% 58% 61% 39%;
  background: linear-gradient(135deg, rgba(5, 168, 200, 0.18), rgba(115, 87, 246, 0.12));
  filter: blur(8px);
  opacity: 0.8;
  transform: rotate(18deg);
}

button,
input,
select,
textarea {
  font: inherit;
}

button,
summary {
  cursor: pointer;
}

svg {
  display: block;
}

a {
  color: inherit;
}

:focus-visible {
  outline: none;
  box-shadow: var(--ring);
}

::selection {
  background: rgba(18, 184, 166, 0.22);
  color: var(--ink);
}

::-webkit-scrollbar {
  width: 10px;
  height: 10px;
}

::-webkit-scrollbar-track {
  background: rgba(224, 240, 247, 0.65);
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, rgba(5, 168, 200, 0.74), rgba(79, 70, 229, 0.66));
  border: 2px solid rgba(255, 255, 255, 0.78);
  border-radius: 999px;
}

/* 03. Shell, header, footer */
.page {
  position: relative;
  isolation: isolate;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page::before,
.page::after {
  content: "";
  position: fixed;
  z-index: -2;
  pointer-events: none;
  border-radius: 999px;
  filter: blur(1px);
}

.page::before {
  width: 340px;
  height: 340px;
  inset-block-start: 120px;
  inset-inline-start: -130px;
  background: radial-gradient(circle, rgba(18, 184, 166, 0.18), transparent 70%);
}

.page::after {
  width: 260px;
  height: 260px;
  inset-block-end: 90px;
  inset-inline-end: 7%;
  background: radial-gradient(circle, rgba(36, 99, 235, 0.13), transparent 72%);
}

.header,
.footer {
  width: 100%;
  background: rgba(255, 255, 255, 0.72);
  border-color: rgba(12, 45, 78, 0.1);
  backdrop-filter: blur(22px) saturate(150%);
  -webkit-backdrop-filter: blur(22px) saturate(150%);
}

.header {
  position: sticky;
  inset-block-start: 0;
  z-index: 40;
  border-bottom: 1px solid var(--border);
  box-shadow: 0 12px 42px rgba(11, 56, 88, 0.07);
}

.header-inner {
  width: var(--container);
  min-height: 78px;
  margin: auto;
  padding: 12px 0;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  direction: ltr;
}

.header-inner-between {
  justify-content: space-between;
  gap: 16px;
}

.logo {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 11px;
  color: var(--ink);
  text-decoration: none;
  direction: ltr;
  transition: transform 0.22s ease, opacity 0.22s ease;
}

.logo:hover,
.logo:focus-visible {
  transform: translateY(-2px);
}

.logo-mark {
  position: relative;
  overflow: hidden;
  width: auto;
  min-width: 126px;
  height: 42px;
  padding: 0 18px;
  border: 1px solid rgba(255, 255, 255, 0.46);
  border-radius: 16px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 30% 20%, rgba(255, 255, 255, 0.38), transparent 25%),
    linear-gradient(135deg, var(--teal) 0%, var(--cyan) 44%, var(--indigo) 100%);
  color: var(--white);
  box-shadow: 0 16px 36px rgba(5, 168, 200, 0.28), inset 0 1px 0 rgba(255, 255, 255, 0.2);
  font-size: 0.92rem;
  font-weight: 950;
  letter-spacing: -0.035em;
  white-space: nowrap;
}

.logo-mark::before {
  content: "";
  position: absolute;
  inset: -38% auto auto -38%;
  width: 68%;
  height: 68%;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.34);
}

.logo-mark::after {
  content: "";
  position: absolute;
  inset-inline-end: 7px;
  inset-block-end: 7px;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 0 4px rgba(255, 255, 255, 0.18);
}

.logo-text {
  color: var(--ink);
  font-size: 1.08rem;
  font-weight: 950;
  letter-spacing: -0.055em;
  display: none;
}

.header-actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 8px;
}

.header-link,
.lang-btn,
.filter-tab,
.inline-action-btn,
.technical-details-btn {
  min-height: 42px;
  border: 1px solid rgba(12, 45, 78, 0.12);
  border-radius: var(--radius-pill);
  padding: 0 16px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--ink);
  box-shadow: 0 9px 24px rgba(11, 56, 88, 0.065);
  text-decoration: none;
  font-size: 0.86rem;
  font-weight: 900;
  line-height: 1.2;
  white-space: nowrap;
  transition: transform 0.22s ease, box-shadow 0.22s ease, background 0.22s ease, color 0.22s ease, border-color 0.22s ease;
}

.header-link:hover,
.header-link:focus-visible,
.lang-btn:hover,
.lang-btn:focus-visible,
.lang-btn.active,
.filter-tab:hover,
.filter-tab:focus-visible,
.filter-tab.active,
.inline-action-btn:hover,
.inline-action-btn:focus-visible,
.technical-details-btn:hover,
.technical-details-btn:focus-visible {
  transform: translateY(-2px);
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--teal));
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.3);
  box-shadow: 0 18px 38px rgba(5, 168, 200, 0.22);
}

.header-button-link {
  cursor: pointer;
}

.inline-logout-form {
  display: inline-flex;
  margin: 0;
}

.admin-role-pill {
  cursor: default;
  background: linear-gradient(135deg, rgba(7, 24, 47, 0.96), rgba(12, 39, 71, 0.92));
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.18);
  box-shadow: 0 14px 30px rgba(7, 24, 47, 0.16);
}

.footer {
  margin-top: auto;
  border-top: 1px solid var(--border);
}

.footer-inner {
  width: var(--container);
  min-height: 74px;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  direction: ltr;
}

.lang-btn {
  min-width: 88px;
}

/* 04. Page layout and cards */
.main {
  flex: 1;
  width: var(--container);
  margin: auto;
  padding: clamp(34px, 7vw, 90px) 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.pro-main,
.dashboard-main {
  align-items: flex-start;
}

.main-card,
.registration-card {
  position: relative;
  overflow: hidden;
  width: min(1040px, 100%);
  border: 1px solid rgba(255, 255, 255, 0.64);
  border-radius: var(--radius-card);
  padding: clamp(24px, 5vw, 44px);
  background:
    linear-gradient(var(--surface-strong), var(--surface-strong)) padding-box,
    linear-gradient(135deg, rgba(18, 184, 166, 0.54), rgba(36, 99, 235, 0.36), rgba(115, 87, 246, 0.28)) border-box;
  box-shadow: var(--shadow);
  backdrop-filter: blur(20px) saturate(150%);
  -webkit-backdrop-filter: blur(20px) saturate(150%);
}

.main-card::before,
.registration-card::before,
.main-card::after,
.registration-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
}

.main-card::before,
.registration-card::before {
  inset-inline: clamp(18px, 4vw, 42px);
  inset-block-start: 0;
  height: 5px;
  border-radius: 0 0 999px 999px;
  background: linear-gradient(90deg, transparent, var(--teal), var(--cyan), var(--indigo), transparent);
  opacity: 0.86;
}

.main-card::after,
.registration-card::after {
  width: 220px;
  height: 220px;
  inset-block-start: -88px;
  inset-inline-end: -64px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(18, 184, 166, 0.22), transparent 68%);
}

.registration-card {
  width: min(780px, 100%);
}

.dashboard-stack,
.admin-stack {
  width: min(1060px, 100%);
  display: grid;
  gap: 20px;
}

.dashboard-stack .registration-card,
.dashboard-card {
  width: 100%;
}

.registration-head {
  position: relative;
  z-index: 1;
  margin-bottom: 26px;
  text-align: center;
}

.registration-head h1,
.registration-head h2,
.admin-stats-head h2,
.section-divider-title h2,
.email-details-section h2,
.chat-title-row h1 {
  color: var(--ink);
  font-size: clamp(1.38rem, 3vw, 2.32rem);
  font-weight: 950;
  letter-spacing: -0.055em;
  line-height: 1.15;
}

.registration-head h1::after,
.registration-head h2::after,
.admin-stats-head h2::after,
.section-divider-title h2::after,
.email-details-section h2::after {
  content: "";
  width: 72px;
  height: 4px;
  margin: 12px auto 0;
  border-radius: 999px;
  display: block;
  background: linear-gradient(90deg, var(--teal), var(--cyan), var(--indigo));
}

.registration-head h2,
.admin-stats-head h2,
.section-divider-title h2,
.email-details-section h2 {
  font-size: clamp(1.14rem, 2.25vw, 1.62rem);
}

.registration-head p,
.admin-stats-head p,
.section-divider-title p {
  max-width: 720px;
  margin: 10px auto 0;
  color: var(--muted);
  font-size: 0.96rem;
  font-weight: 760;
  line-height: 1.86;
}

.section-divider-title {
  margin: 18px 0 16px;
  padding-top: 18px;
  border-top: 1px solid var(--border);
}

/* 05. Home actions */
.actions {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  align-items: stretch;
  gap: 16px;
}

.action-btn {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 144px;
  border: 1px solid rgba(12, 45, 78, 0.12);
  border-radius: 30px;
  padding: 19px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 13px;
  background:
    radial-gradient(circle at 50% -10%, rgba(18, 184, 166, 0.13), transparent 38%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(247, 251, 255, 0.86));
  color: var(--ink);
  box-shadow: var(--shadow-soft);
  text-align: center;
  text-decoration: none;
  font-size: 0.94rem;
  font-weight: 940;
  line-height: 1.35;
  letter-spacing: -0.02em;
  transition: transform 0.25s ease, box-shadow 0.25s ease, color 0.25s ease, border-color 0.25s ease;
}

.action-btn::before,
.action-btn::after {
  content: "";
  position: absolute;
  pointer-events: none;
  z-index: -1;
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.action-btn::before {
  inset: 0;
  opacity: 0;
  background:
    radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.22), transparent 44%),
    linear-gradient(135deg, var(--blue), var(--cyan), var(--teal));
}

.action-btn::after {
  width: 96px;
  height: 96px;
  inset-block-end: -48px;
  inset-inline-start: -28px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.28);
  opacity: 0.7;
}

.action-btn:hover,
.action-btn:focus-visible {
  transform: translateY(-8px) scale(1.012);
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.42);
  box-shadow: 0 26px 58px rgba(5, 168, 200, 0.22);
}

.action-btn:hover::before,
.action-btn:focus-visible::before {
  opacity: 1;
}

.action-btn:hover::after,
.action-btn:focus-visible::after {
  transform: scale(1.2) rotate(16deg);
}

.action-btn.primary {
  background:
    radial-gradient(circle at 34% 0%, rgba(255, 255, 255, 0.22), transparent 38%),
    linear-gradient(135deg, var(--blue), var(--cyan), var(--teal));
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.34);
  box-shadow: 0 20px 46px rgba(5, 168, 200, 0.26);
}

.action-btn > span:not(.icon) {
  position: relative;
  z-index: 1;
}

.icon {
  position: relative;
  z-index: 1;
  width: 50px;
  height: 50px;
  border: 1px solid rgba(255, 255, 255, 0.66);
  border-radius: 19px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(229, 247, 250, 0.78));
  color: var(--cyan-deep);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7), 0 12px 26px rgba(11, 56, 88, 0.1);
  transition: transform 0.25s ease, background 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
}

.icon svg {
  width: 23px;
  height: 23px;
  stroke-width: 2;
}

.action-btn.primary .icon,
.action-btn:hover .icon,
.action-btn:focus-visible .icon {
  transform: translateY(-2px) rotate(-2deg);
  background: rgba(255, 255, 255, 0.18);
  color: var(--white);
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.22), 0 14px 28px rgba(7, 24, 47, 0.12);
}

/* 06. Forms and controls */
.pro-form,
.modal-box form:not(.chat-form) {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 16px;
}

.form-row,
.admin-form-row,
.wide-admin-form-row {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.wide-admin-form-row {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.form-group {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.country-field {
  min-width: 0;
}

.phone-field {
  min-width: 0;
}

.form-group label,
.admin-emails-box label {
  color: var(--ink);
  font-size: 0.83rem;
  font-weight: 940;
}

.form-group input,
.form-group select,
.form-group textarea,
.admin-emails-box textarea,
.chat-form input,
.chat-search-form input,
.chat-transfer-form select,
.chat-send-form textarea {
  width: 100%;
  min-height: 52px;
  border: 1px solid rgba(12, 45, 78, 0.14);
  border-radius: var(--radius-control);
  padding: 0 15px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--text);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78), 0 8px 18px rgba(11, 56, 88, 0.035);
  font-size: 0.95rem;
  transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, transform 0.2s ease;
}

.form-group textarea,
.admin-emails-box textarea,
.chat-send-form textarea {
  min-height: 98px;
  padding-block: 13px;
  line-height: 1.75;
  resize: vertical;
}

.form-group select {
  color: var(--text);
}

.form-group small,
.form-help {
  display: block;
  color: var(--muted);
  font-size: 0.76rem;
  line-height: 1.65;
  font-weight: 820;
}

.form-group input:hover,
.form-group select:hover,
.form-group textarea:hover,
.admin-emails-box textarea:hover,
.chat-form input:hover,
.chat-search-form input:hover,
.chat-transfer-form select:hover,
.chat-send-form textarea:hover {
  border-color: rgba(5, 168, 200, 0.38);
  background: rgba(255, 255, 255, 0.95);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus,
.admin-emails-box textarea:focus,
.chat-form input:focus,
.chat-search-form input:focus,
.chat-transfer-form select:focus,
.chat-send-form textarea:focus {
  border-color: rgba(5, 168, 200, 0.72);
  box-shadow: var(--ring), inset 0 1px 0 rgba(255, 255, 255, 0.78);
  outline: none;
}

.submit-btn,
.chat-form button,
.chat-search-form button,
.chat-transfer-form button,
.chat-send-form > div:not(.chat-shortcuts) > button {
  position: relative;
  overflow: hidden;
  min-height: 53px;
  border: 0;
  border-radius: var(--radius-control);
  padding: 0 21px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--teal));
  color: var(--white);
  box-shadow: 0 16px 34px rgba(5, 168, 200, 0.22);
  text-decoration: none;
  font-size: 0.93rem;
  font-weight: 950;
  letter-spacing: -0.01em;
  white-space: nowrap;
  transition: transform 0.22s ease, box-shadow 0.22s ease, opacity 0.22s ease, filter 0.22s ease;
}

.submit-btn::before,
.chat-form button::before,
.chat-search-form button::before,
.chat-transfer-form button::before,
.chat-send-form > div:not(.chat-shortcuts) > button::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  background: radial-gradient(circle at 50% 0%, rgba(255, 255, 255, 0.32), transparent 52%);
  transition: opacity 0.22s ease;
}

.submit-btn:hover::before,
.submit-btn:focus-visible::before,
.chat-form button:hover::before,
.chat-form button:focus-visible::before,
.chat-search-form button:hover::before,
.chat-search-form button:focus-visible::before,
.chat-transfer-form button:hover::before,
.chat-transfer-form button:focus-visible::before,
.chat-send-form > div:not(.chat-shortcuts) > button:hover::before,
.chat-send-form > div:not(.chat-shortcuts) > button:focus-visible::before {
  opacity: 1;
}

.submit-btn:hover,
.submit-btn:focus-visible,
.chat-form button:hover,
.chat-form button:focus-visible,
.chat-search-form button:hover,
.chat-search-form button:focus-visible,
.chat-transfer-form button:hover,
.chat-transfer-form button:focus-visible,
.chat-send-form > div:not(.chat-shortcuts) > button:hover,
.chat-send-form > div:not(.chat-shortcuts) > button:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 22px 48px rgba(5, 168, 200, 0.26);
  filter: saturate(1.08);
}

.submit-btn:disabled,
.form-group input:disabled,
.form-group select:disabled,
.form-group textarea:disabled {
  cursor: not-allowed;
  opacity: 0.58;
}

.submit-btn:disabled:hover,
.submit-btn:disabled:focus-visible {
  transform: none;
}

.secondary-submit {
  border: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.85);
  color: var(--ink);
  box-shadow: 0 10px 24px rgba(11, 56, 88, 0.07);
}

.compact-submit {
  min-height: 44px;
  border-radius: 15px;
  padding-inline: 16px;
}

.form-actions-row,
.dashboard-actions,
.card-actions,
.request-summary-actions,
.request-card-actions,
.details-actions-row,
.admin-card-utilities,
.admin-profile-actions {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  flex-wrap: wrap;
  gap: 10px;
}

.form-actions-row,
.card-actions,
.request-card-actions,
.details-actions-row,
.admin-card-utilities {
  margin-top: 14px;
}

.dashboard-actions {
  margin-top: 20px;
}

.dashboard-actions-top {
  margin-bottom: 18px;
}

.form-actions-row .submit-btn {
  flex: 1 1 170px;
}

.checkbox-group {
  min-height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.checkbox-label {
  min-height: 50px;
  border: 1px solid var(--border);
  border-radius: 17px;
  padding: 0 13px;
  display: flex;
  align-items: center;
  gap: 9px;
  background: rgba(255, 255, 255, 0.84);
  color: var(--ink);
  font-weight: 900;
  cursor: pointer;
  box-shadow: 0 8px 20px rgba(11, 56, 88, 0.05);
}

.checkbox-label input {
  width: auto;
  min-height: auto;
  box-shadow: none;
  accent-color: var(--cyan-deep);
}

/* 07. Alerts, empty states, data tiles */
.alert,
.empty-state,
.uid-box,
.dashboard-grid div,
.registration-meta div,
.admin-stat-card,
.request-card,
.request-meta-grid div,
.admin-note-box,
.emails-details,
.admin-profile-box > div,
.details-modal-item {
  border: 1px solid rgba(12, 45, 78, 0.11);
  box-shadow: 0 12px 30px rgba(11, 56, 88, 0.06);
}

.alert {
  position: relative;
  overflow: hidden;
  border-radius: 19px;
  padding: 15px 17px;
  display: grid;
  gap: 6px;
  line-height: 1.68;
}

.alert::before {
  content: "";
  position: absolute;
  inset-block: 10px;
  inset-inline-start: 0;
  width: 4px;
  border-radius: 999px;
  background: currentColor;
  opacity: 0.38;
}

.alert strong {
  font-size: 0.9rem;
  font-weight: 950;
}

.alert span,
.alert li {
  font-size: 0.88rem;
  font-weight: 740;
}

.alert ul {
  padding-inline-start: 18px;
}

.alert-success {
  border-color: var(--success-border);
  background: var(--success-bg);
  color: var(--success-text);
}

.alert-error {
  border-color: var(--danger-border);
  background: var(--danger-bg);
  color: var(--danger-text);
}

.alert-warning {
  border-color: var(--warning-border);
  background: var(--warning-bg);
  color: var(--warning-text);
}

.empty-state {
  border-radius: 22px;
  padding: 19px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--muted);
  text-align: center;
  font-weight: 850;
  line-height: 1.78;
}

.empty-state strong,
.empty-state span {
  display: block;
}

.empty-state strong {
  color: var(--ink);
  margin-bottom: 5px;
  font-weight: 950;
}

.uid-box {
  border-style: solid;
  border-radius: 21px;
  padding: 16px;
  display: grid;
  gap: 6px;
  background:
    radial-gradient(circle at 100% 0%, rgba(18, 184, 166, 0.12), transparent 38%),
    rgba(255, 255, 255, 0.78);
}

.uid-box span,
.registration-meta span,
.dashboard-grid span,
.request-card-head span:first-child,
.request-meta-grid span,
.admin-note-box span,
.admin-emails-box label,
.admin-profile-box span,
.details-modal-item span {
  display: block;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  margin-bottom: 6px;
}

.uid-box strong,
.registration-meta strong,
.dashboard-grid strong,
.request-card-head strong,
.request-meta-grid strong,
.admin-profile-box strong,
.details-modal-item strong {
  display: block;
  color: var(--ink);
  font-size: 0.95rem;
  font-weight: 950;
  line-height: 1.55;
  overflow-wrap: anywhere;
}

.registration-meta,
.dashboard-grid,
.request-meta-grid,
.admin-meta-grid,
.admin-profile-box {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.registration-meta div,
.dashboard-grid div,
.request-meta-grid div,
.admin-profile-box > div {
  min-width: 0;
  border-radius: 20px;
  padding: 14px 15px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.86), rgba(247, 251, 255, 0.72));
}

.dashboard-grid,
.admin-profile-box {
  margin: 16px 0 18px;
}

/* 08. Modals */
.modal {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  place-items: center;
  padding: 18px;
  background: rgba(7, 24, 47, 0.55);
  backdrop-filter: blur(12px) saturate(145%);
  -webkit-backdrop-filter: blur(12px) saturate(145%);
}

.modal.active {
  display: grid;
}

.modal-box,
.details-modal-box,
.chat-panel {
  border: 1px solid rgba(255, 255, 255, 0.48);
  background: rgba(255, 255, 255, 0.96);
  box-shadow: var(--shadow-strong);
}

.modal-box {
  position: relative;
  overflow: auto;
  width: min(540px, 100%);
  max-height: min(86vh, 720px);
  border-radius: 30px;
  padding: 25px;
  animation: modalShow 0.25s ease both;
}

.details-modal-box {
  width: min(780px, 100%);
}

@keyframes modalShow {
  from {
    opacity: 0;
    transform: translateY(14px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.modal-head,
.details-modal-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 18px;
}

.modal-head h2 {
  color: var(--ink);
  font-size: 1.2rem;
  font-weight: 950;
  letter-spacing: -0.03em;
}

.close-btn,
.chat-close {
  flex: 0 0 auto;
  width: 39px;
  height: 39px;
  border: 1px solid var(--border);
  border-radius: 15px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(238, 247, 251, 0.9);
  color: var(--ink);
  font-size: 1.35rem;
  font-weight: 840;
  line-height: 1;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.close-btn:hover,
.close-btn:focus-visible,
.chat-close:hover,
.chat-close:focus-visible {
  transform: translateY(-1px) rotate(4deg);
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.35);
}

.modal-kicker {
  display: block;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  margin-bottom: 5px;
}

.details-modal-subtitle {
  margin: -8px 0 16px;
  color: var(--muted);
  font-size: 0.9rem;
  line-height: 1.8;
  font-weight: 760;
}

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

.details-modal-item {
  min-width: 0;
  border-radius: 19px;
  padding: 14px 15px;
  background: rgba(255, 255, 255, 0.78);
}

.technical-details-btn {
  min-height: 42px;
  padding-inline: 16px;
  border-style: dashed;
}

/* 09. Articles and floating chat */
.articles-list {
  display: grid;
  gap: 10px;
}

.article-item {
  position: relative;
  overflow: hidden;
  width: 100%;
  min-height: 64px;
  border: 1px solid var(--border);
  border-radius: 19px;
  padding: 12px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: rgba(255, 255, 255, 0.82);
  color: var(--ink);
  text-align: start;
  font-weight: 900;
  transition: transform 0.22s ease, background 0.22s ease, color 0.22s ease, border-color 0.22s ease, box-shadow 0.22s ease;
}

.article-item span:first-child {
  flex: 0 0 auto;
  width: 38px;
  height: 38px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, rgba(18, 184, 166, 0.14), rgba(36, 99, 235, 0.12));
  color: var(--cyan-deep);
}

.article-item:hover,
.article-item:focus-visible {
  transform: translateY(-2px);
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--teal));
  color: var(--white);
  border-color: rgba(255, 255, 255, 0.35);
  box-shadow: 0 18px 38px rgba(5, 168, 200, 0.18);
}

.article-item:hover span:first-child,
.article-item:focus-visible span:first-child {
  background: rgba(255, 255, 255, 0.18);
  color: var(--white);
}

.chat-panel {
  position: fixed;
  left: 24px;
  bottom: 94px;
  z-index: 90;
  overflow: hidden;
  width: min(400px, calc(100vw - 32px));
  border-radius: 30px;
  opacity: 0;
  visibility: hidden;
  transform: translateY(14px) scale(0.98);
  transition: opacity 0.24s ease, visibility 0.24s ease, transform 0.24s ease;
}

[dir="rtl"] .chat-panel {
  left: auto;
  right: 24px;
}

.chat-panel.active {
  opacity: 1;
  visibility: visible;
  transform: translateY(0) scale(1);
}

.chat-head {
  min-height: 60px;
  padding: 12px 15px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--teal));
  color: var(--white);
}

.chat-head strong {
  font-weight: 950;
}

.chat-close {
  width: 35px;
  height: 35px;
  border-color: rgba(255, 255, 255, 0.2);
  background: rgba(255, 255, 255, 0.14);
  color: var(--white);
}

.chat-body {
  max-height: 292px;
  overflow: auto;
  padding: 16px;
  display: grid;
  gap: 10px;
  background: linear-gradient(180deg, rgba(238, 247, 251, 0.58), rgba(255, 255, 255, 0.78));
}

.message {
  width: fit-content;
  max-width: 85%;
  border-radius: 17px;
  padding: 10px 12px;
  box-shadow: 0 9px 22px rgba(11, 56, 88, 0.065);
  line-height: 1.58;
  font-size: 0.9rem;
  font-weight: 760;
}

.message.bot {
  justify-self: start;
  background: rgba(255, 255, 255, 0.9);
  color: var(--ink);
  border: 1px solid var(--border);
}

.message.user {
  justify-self: end;
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: var(--white);
}

.chat-form {
  border-top: 1px solid var(--border);
  padding: 12px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 8px;
  background: rgba(255, 255, 255, 0.9);
}

.chat-form input,
.chat-form button {
  min-height: 45px;
  border-radius: 15px;
}

.chat-form button {
  padding-inline: 16px;
}

/* 10. Requests, statuses, dashboard */
.requests-list,
.admin-requests-list {
  display: grid;
  gap: 14px;
}

.request-card {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-panel);
  padding: 18px;
  background:
    radial-gradient(circle at 100% 0%, rgba(5, 168, 200, 0.11), transparent 38%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.93), rgba(248, 252, 255, 0.84));
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease;
}

.request-card::before,
.admin-stat-card::before {
  content: "";
  position: absolute;
  inset-inline: 0;
  top: 0;
  height: 4px;
  background: linear-gradient(90deg, rgba(12, 45, 78, 0.18), rgba(12, 45, 78, 0.05));
}

.request-card.status-pending::before,
.admin-stat-card.status-pending::before {
  background: linear-gradient(90deg, #f97316, #fb923c);
}

.request-card.status-completed::before,
.admin-stat-card.status-completed::before {
  background: linear-gradient(90deg, #10b981, #2dd4bf);
}

.request-card.status-cancelled::before,
.admin-stat-card.status-cancelled::before {
  background: linear-gradient(90deg, #ef4444, #f87171);
}

.request-card:hover,
.admin-request-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-medium);
}

.request-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.status-badge {
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
  padding: 8px 12px;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.44), 0 8px 18px rgba(11, 56, 88, 0.05);
  font-size: 0.78rem;
  font-weight: 950;
  line-height: 1;
}

.status-badge.status-pending {
  background: var(--warning-bg);
  color: var(--warning-text);
}

.status-badge.status-completed {
  background: var(--success-bg);
  color: var(--success-text);
}

.status-badge.status-cancelled {
  background: var(--danger-bg);
  color: var(--danger-text);
}

.request-status-message {
  margin-top: 12px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 760;
  line-height: 1.78;
}

.request-meta-grid,
.admin-meta-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-top: 14px;
}

.admin-note-box,
.admin-emails-box,
.emails-details {
  margin-top: 14px;
  border-radius: 19px;
  padding: 14px;
  background: rgba(255, 255, 255, 0.74);
}

.admin-note-box p {
  color: var(--text);
  font-weight: 760;
  line-height: 1.78;
}

.admin-emails-box textarea {
  margin-top: 7px;
}

.copy-value-row,
.admin-emails-box-head {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.copy-value-row strong {
  min-width: 0;
  flex: 1 1 auto;
}

.admin-emails-box-head label {
  margin-bottom: 0;
}

.copy-email-btn {
  flex: 0 0 auto;
  min-height: 35px;
  border: 1px solid var(--border);
  border-radius: var(--radius-pill);
  padding: 7px 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95), rgba(238, 247, 251, 0.9));
  color: var(--ink);
  font-size: 0.76rem;
  font-weight: 950;
  line-height: 1;
  white-space: nowrap;
  box-shadow: 0 8px 18px rgba(11, 56, 88, 0.06);
  transition: transform 0.18s ease, border-color 0.18s ease, background 0.18s ease, color 0.18s ease, box-shadow 0.18s ease;
}

.copy-email-btn:hover,
.copy-email-btn:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(5, 168, 200, 0.54);
  box-shadow: 0 12px 26px rgba(5, 168, 200, 0.12);
}

.copy-email-btn.copied {
  border-color: var(--success-border);
  background: var(--success-bg);
  color: var(--success-text);
}

.copy-email-btn.copy-error {
  border-color: var(--danger-border);
  background: var(--danger-bg);
  color: var(--danger-text);
}

.copy-email-icon {
  font-size: 0.92rem;
  line-height: 1;
}

.status-form {
  margin-top: 16px;
  display: grid;
  gap: 12px;
}

.request-summary-actions {
  margin-top: 16px;
}

.request-details-link {
  width: fit-content;
}

.email-details-card {
  margin-top: 6px;
}

.email-details-section {
  margin-top: 20px;
}

.emails-details summary {
  border-radius: 15px;
  padding: 10px 12px;
  color: var(--ink);
  font-weight: 900;
  list-style-position: inside;
}

.emails-details summary:hover {
  background: rgba(238, 247, 251, 0.8);
}

.emails-details pre {
  margin-top: 10px;
  overflow: auto;
  border-radius: 15px;
  padding: 12px;
  background: rgba(238, 247, 251, 0.86);
  color: var(--text);
  font-size: 0.84rem;
  line-height: 1.66;
}

.admin-stats-head {
  margin: 2px 0 16px;
  text-align: center;
}

.admin-stats-grid,
.dashboard-email-stats-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.admin-stat-card {
  position: relative;
  overflow: hidden;
  min-height: 134px;
  border-radius: 24px;
  padding: 17px;
  display: grid;
  align-content: center;
  gap: 6px;
  background:
    radial-gradient(circle at 100% 0%, rgba(18, 184, 166, 0.12), transparent 38%),
    rgba(255, 255, 255, 0.76);
  color: var(--ink);
  text-decoration: none;
  transition: transform 0.22s ease, box-shadow 0.22s ease, border-color 0.22s ease, background 0.22s ease;
}

.admin-stat-card:hover,
.admin-stat-card:focus-visible,
.admin-stat-card.active {
  transform: translateY(-4px);
  border-color: rgba(5, 168, 200, 0.46);
  box-shadow: var(--shadow-medium);
  background: rgba(255, 255, 255, 0.92);
}

.admin-stat-card span,
.admin-stat-card small {
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 900;
  line-height: 1.56;
}

.admin-stat-card strong {
  color: var(--ink);
  font-size: clamp(1.86rem, 4vw, 2.9rem);
  font-weight: 950;
  line-height: 1;
}

/* 11. Admin navigation and profile */
.filter-tabs {
  width: fit-content;
  max-width: 100%;
  border: 1px solid rgba(12, 45, 78, 0.1);
  border-radius: var(--radius-pill);
  padding: 8px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 10px 26px rgba(11, 56, 88, 0.05);
}

.admin-main-tabs {
  margin-top: 12px;
}

.supervisor-note {
  margin-top: 14px;
}

.admin-profile-actions .technical-details-btn {
  width: 100%;
}

.account-card .status-form {
  margin-top: 16px;
}

/* 12. Live chat workspace */
.chat-main {
  align-items: stretch;
}

.chat-workspace {
  width: min(1180px, 100%);
  display: grid;
  grid-template-columns: minmax(270px, 340px) minmax(0, 1fr);
  gap: 18px;
  align-items: stretch;
}

.chat-workspace.no-sidebar {
  grid-template-columns: minmax(0, 1fr);
}

.chat-sidebar,
.chat-card {
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(12, 45, 78, 0.14);
  background: rgba(255, 255, 255, 0.88);
  box-shadow: 0 26px 78px rgba(11, 56, 88, 0.14);
  border-radius: 30px;
  backdrop-filter: blur(20px) saturate(148%);
  -webkit-backdrop-filter: blur(20px) saturate(148%);
}

.chat-sidebar::before,
.chat-card::before {
  content: "";
  position: absolute;
  inset-inline: 22px;
  top: 0;
  height: 4px;
  border-radius: 0 0 999px 999px;
  background: linear-gradient(90deg, var(--teal), var(--cyan), var(--indigo));
}

.chat-sidebar {
  padding: 18px;
  max-height: 760px;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.chat-sidebar-head,
.chat-title-row,
.chat-participants {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.chat-sidebar-head span,
.chat-participants span,
.chat-search-form label,
.chat-transfer-form label,
.chat-send-form label,
.chat-shortcuts-head small {
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 860;
}

.chat-sidebar-head strong,
.chat-status-pill {
  border-radius: 999px;
  padding: 8px 12px;
  background: rgba(18, 184, 166, 0.13);
  color: var(--teal-deep);
  font-size: 0.85rem;
  font-weight: 950;
}

.chat-search-form,
.chat-transfer-form,
.chat-send-form {
  display: grid;
  gap: 9px;
}

.chat-search-form > div,
.chat-transfer-form > div,
.chat-send-form > div:not(.chat-shortcuts) {
  display: flex;
  gap: 8px;
}

.chat-search-form button,
.chat-transfer-form button,
.chat-send-form > div:not(.chat-shortcuts) > button {
  border-radius: 18px;
  padding: 0 18px;
  cursor: pointer;
}

.chat-transfer-form {
  padding: 15px 16px;
  border-radius: 24px;
  background: linear-gradient(135deg, rgba(18, 184, 166, 0.08), rgba(36, 99, 235, 0.08));
  border: 1px solid rgba(12, 45, 78, 0.11);
}

.chat-transfer-form small {
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.7;
  font-weight: 820;
}

.chat-transfer-form select {
  cursor: pointer;
}

.chat-shortcuts {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 42px;
  padding: 7px 9px;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.62);
  border: 1px solid rgba(12, 45, 78, 0.08);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78), 0 8px 20px rgba(11, 56, 88, 0.045);
  overflow: hidden;
}

.chat-shortcuts-head {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding-inline-end: 2px;
  white-space: nowrap;
}

.chat-shortcuts-head span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--ink-2);
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: -0.01em;
}

.chat-shortcuts-head span::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--teal), var(--cyan));
  box-shadow: 0 0 0 4px rgba(18, 184, 166, 0.1);
}

.chat-shortcuts-head small {
  display: none;
}

.chat-shortcuts-list {
  flex: 1 1 auto;
  min-width: 0;
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  max-height: none;
  overflow-x: auto;
  overflow-y: hidden;
  padding: 1px 1px 3px;
  scrollbar-width: thin;
  scrollbar-color: rgba(5, 168, 200, 0.35) transparent;
}

.chat-shortcuts-list::-webkit-scrollbar {
  height: 5px;
}

.chat-shortcuts-list::-webkit-scrollbar-track {
  background: transparent;
}

.chat-shortcuts-list::-webkit-scrollbar-thumb {
  border-radius: 999px;
  background: rgba(5, 168, 200, 0.3);
}

.chat-shortcut-btn {
  appearance: none;
  flex: 0 0 auto;
  min-height: 28px;
  border: 1px solid rgba(12, 45, 78, 0.1);
  border-radius: 999px;
  background: rgba(248, 252, 255, 0.86);
  color: var(--ink-2);
  cursor: pointer;
  font: inherit;
  font-size: 0.74rem;
  font-weight: 900;
  line-height: 1.2;
  padding: 5px 10px;
  white-space: nowrap;
  box-shadow: 0 4px 12px rgba(11, 56, 88, 0.04);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, background 0.18s ease, color 0.18s ease;
}

.chat-shortcut-btn:hover,
.chat-shortcut-btn:focus-visible {
  transform: translateY(-1px);
  border-color: rgba(5, 168, 200, 0.35);
  background: rgba(255, 255, 255, 0.98);
  color: var(--teal-deep);
  box-shadow: 0 8px 18px rgba(5, 168, 200, 0.11);
  outline: none;
}

.chat-conversation-list {
  overflow: auto;
  display: grid;
  gap: 10px;
  padding-inline-end: 2px;
}

.chat-conversation-link {
  position: relative;
  display: grid;
  gap: 5px;
  padding: 14px 15px;
  border-radius: 21px;
  text-decoration: none;
  color: var(--text);
  background: rgba(238, 247, 251, 0.7);
  border: 1px solid rgba(12, 45, 78, 0.1);
  transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.chat-conversation-link.active,
.chat-conversation-link:hover,
.chat-conversation-link:focus-visible {
  transform: translateY(-2px);
  background: rgba(255, 255, 255, 0.94);
  border-color: rgba(5, 168, 200, 0.32);
  box-shadow: 0 14px 32px rgba(5, 168, 200, 0.1);
}

.chat-conversation-link span {
  font-weight: 950;
  color: var(--ink);
}

.chat-conversation-link small,
.chat-conversation-link em {
  color: var(--muted);
  font-style: normal;
  font-size: 0.78rem;
}

.chat-conversation-link b {
  position: absolute;
  top: 12px;
  inset-inline-end: 12px;
  min-width: 24px;
  height: 24px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--cyan), var(--teal));
  color: #fff;
  font-size: 0.78rem;
  box-shadow: 0 8px 18px rgba(5, 168, 200, 0.18);
}

.chat-card {
  padding: 23px;
  min-height: 680px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.chat-title-row h1 {
  margin: 4px 0 0;
}

.chat-participants {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.chat-participants > div {
  display: grid;
  gap: 5px;
  padding: 15px 16px;
  border-radius: 23px;
  background: linear-gradient(135deg, rgba(36, 99, 235, 0.08), rgba(18, 184, 166, 0.1));
  border: 1px solid rgba(12, 45, 78, 0.11);
}

.chat-participants strong {
  color: var(--ink);
  font-size: 1.02rem;
  overflow-wrap: anywhere;
}

.chat-participants small {
  color: var(--muted);
  font-size: 0.8rem;
  overflow-wrap: anywhere;
}

.chat-thread {
  flex: 1;
  min-height: 360px;
  max-height: 520px;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  gap: 11px;
  padding: 16px;
  border-radius: 25px;
  background:
    radial-gradient(circle at 4% 0%, rgba(18, 184, 166, 0.13), transparent 36%),
    linear-gradient(180deg, rgba(229, 247, 250, 0.78), rgba(239, 246, 255, 0.56));
  border: 1px solid rgba(12, 45, 78, 0.12);
}

.chat-message {
  display: flex;
}

.chat-message.mine {
  justify-content: flex-end;
}

.chat-message.theirs {
  justify-content: flex-start;
}

.chat-message-bubble {
  max-width: min(74%, 620px);
  border-radius: 23px;
  padding: 12px 14px 10px;
  box-shadow: 0 11px 28px rgba(11, 56, 88, 0.09);
}

.chat-message.mine .chat-message-bubble {
  background: linear-gradient(135deg, var(--blue), var(--cyan));
  color: #fff;
  border-bottom-inline-end-radius: 8px;
}

.chat-message.theirs .chat-message-bubble {
  background: rgba(255, 255, 255, 0.96);
  color: var(--text);
  border: 1px solid rgba(12, 45, 78, 0.1);
  border-bottom-inline-start-radius: 8px;
}

.chat-message-bubble p {
  margin: 0;
  line-height: 1.82;
  overflow-wrap: anywhere;
}

.chat-message-bubble footer {
  margin-top: 8px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  opacity: 0.82;
  font-size: 0.75rem;
}

.chat-message-bubble small {
  display: block;
  margin-top: 5px;
  opacity: 0.58;
  font-size: 0.68rem;
  overflow-wrap: anywhere;
}

.chat-read-mark {
  letter-spacing: -2px;
  font-weight: 950;
}

.chat-send-form textarea {
  min-height: 60px;
}

.chat-empty-state,
.chat-empty-small {
  padding: 18px;
  border-radius: 23px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px dashed rgba(5, 168, 200, 0.3);
  color: var(--muted);
  text-align: center;
  line-height: 1.7;
}

.chat-empty-state strong {
  display: block;
  color: var(--ink);
  margin-bottom: 6px;
}

.chat-empty-state.compact {
  margin: auto;
  width: min(420px, 100%);
}

/* 13. Responsive polish */
@media (max-width: 1100px) {
  .actions {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .main-card {
    width: min(820px, 100%);
  }
}

@media (max-width: 980px) {
  .wide-admin-form-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 860px) {
  .chat-workspace {
    grid-template-columns: 1fr;
  }

  .chat-card {
    min-height: auto;
  }

  .chat-participants,
  .chat-title-row {
    grid-template-columns: 1fr;
    display: grid;
  }

  .chat-message-bubble {
    max-width: 92%;
  }

  .chat-search-form > div,
  .chat-transfer-form > div,
  .chat-send-form > div:not(.chat-shortcuts) {
    flex-direction: column;
  }

  .chat-shortcuts {
    align-items: stretch;
    flex-direction: column;
    gap: 7px;
    padding: 8px 9px;
  }

  .chat-shortcuts-head {
    justify-content: space-between;
  }

  .chat-shortcuts-list {
    padding-bottom: 2px;
  }

  .chat-shortcut-btn {
    min-height: 27px;
    font-size: 0.72rem;
    padding: 5px 9px;
  }

  .chat-search-form button,
  .chat-transfer-form button,
  .chat-send-form > div:not(.chat-shortcuts) > button {
    min-height: 48px;
  }
}

@media (max-width: 850px) {
  .registration-meta,
  .dashboard-grid,
  .admin-profile-box,
  .request-meta-grid,
  .admin-meta-grid,
  .admin-stats-grid,
  .dashboard-email-stats-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .header-inner-between {
    align-items: flex-start;
    flex-direction: column;
    gap: 12px;
  }

  .header-actions {
    width: 100%;
    justify-content: flex-start;
  }

  [dir="rtl"] .header-actions {
    justify-content: flex-end;
  }

  .header-link {
    flex: 1 1 auto;
  }

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

  .registration-card,
  .main-card {
    border-radius: 29px;
  }

  .request-card-head {
    align-items: stretch;
    flex-direction: column;
  }
}

@media (max-width: 680px) {
  .form-row,
  .admin-form-row,
  .wide-admin-form-row,
  .details-modal-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  body::before {
    background-size: 32px 32px;
  }

  body::after {
    width: 300px;
    height: 300px;
    inset-inline-end: -170px;
  }

  .header-inner {
    min-height: 68px;
    padding: 10px 0;
  }

  .header-inner-between {
    align-items: stretch;
  }

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

  .header-link,
  .lang-btn,
  .filter-tab,
  .inline-action-btn,
  .technical-details-btn {
    width: 100%;
    padding-inline: 10px;
    text-align: center;
    white-space: normal;
  }

  .footer-inner {
    padding: 14px 0;
  }

  .main {
    width: min(100% - 24px, 1180px);
    padding: 28px 0;
  }

  .main-card,
  .registration-card {
    padding: 22px;
  }

  .actions {
    grid-template-columns: 1fr;
  }

  .action-btn {
    min-height: 78px;
    padding: 14px;
    border-radius: 22px;
    flex-direction: row;
    justify-content: flex-start;
    text-align: start;
  }

  .icon {
    flex: 0 0 auto;
    width: 45px;
    height: 45px;
    border-radius: 16px;
  }

  .filter-tabs {
    width: 100%;
    border-radius: 23px;
  }

  .filter-tab {
    flex: 1 1 auto;
  }

  .modal {
    padding: 12px;
  }

  .modal-box {
    padding: 18px;
    border-radius: 24px;
  }

  .chat-panel,
  [dir="rtl"] .chat-panel {
    left: 12px;
    right: 12px;
    bottom: 82px;
    width: auto;
    max-width: none;
  }
}


/* 15. Home exclusive trend products */
.home-trends {
  position: relative;
  z-index: 1;
  margin-top: 24px;
  padding-top: 24px;
  border-top: 1px solid rgba(12, 45, 78, 0.11);
}

.home-trends-head {
  margin-bottom: 14px;
  display: grid;
  place-items: center;
  gap: 5px;
  text-align: center;
}

.home-trends-head span {
  border: 1px solid rgba(5, 168, 200, 0.2);
  border-radius: var(--radius-pill);
  padding: 6px 12px;
  background: rgba(238, 247, 251, 0.72);
  color: var(--cyan-deep);
  font-size: 0.72rem;
  font-weight: 950;
  line-height: 1;
}

.home-trends-head strong {
  color: var(--ink);
  font-size: clamp(1rem, 2vw, 1.28rem);
  font-weight: 950;
  letter-spacing: -0.03em;
}

.home-trends-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 14px;
}

.trend-product-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 190px;
  aspect-ratio: 4 / 5;
  border: 1px solid rgba(12, 45, 78, 0.12);
  border-radius: 24px;
  display: block;
  background:
    radial-gradient(circle at 50% -10%, rgba(18, 184, 166, 0.18), transparent 46%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.96), rgba(229, 247, 250, 0.84));
  box-shadow: 0 16px 36px rgba(11, 56, 88, 0.11);
  color: var(--white);
  text-decoration: none;
  transform: translateZ(0);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.trend-product-card::before,
.trend-product-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
  z-index: 1;
}

.trend-product-card::before {
  inset: 0;
  background: linear-gradient(180deg, rgba(7, 24, 47, 0.02) 0%, rgba(7, 24, 47, 0.06) 48%, rgba(7, 24, 47, 0.62) 100%);
}

.trend-product-card::after {
  width: 86px;
  height: 86px;
  inset-block-start: -40px;
  inset-inline-end: -32px;
  border-radius: 999px;
  background: rgba(5, 168, 200, 0.32);
  filter: blur(1px);
}

.trend-product-card img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
  transition: transform 0.32s ease, filter 0.32s ease;
}

.trend-product-card:hover,
.trend-product-card:focus-visible {
  transform: translateY(-6px);
  border-color: rgba(5, 168, 200, 0.42);
  box-shadow: 0 26px 62px rgba(5, 168, 200, 0.2);
}

.trend-product-card:hover img,
.trend-product-card:focus-visible img {
  transform: scale(1.06);
  filter: saturate(1.08);
}

.trend-product-badge,
.trend-product-stars {
  position: absolute;
  z-index: 2;
  pointer-events: none;
}

.trend-product-badge {
  inset-block-start: 10px;
  inset-inline-start: 10px;
  border: 1px solid rgba(255, 255, 255, 0.36);
  border-radius: var(--radius-pill);
  padding: 7px 10px;
  background: linear-gradient(135deg, rgba(36, 99, 235, 0.94), rgba(5, 168, 200, 0.92), rgba(18, 184, 166, 0.9));
  color: var(--white);
  font-size: 0.68rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  line-height: 1;
  box-shadow: 0 10px 24px rgba(7, 24, 47, 0.18);
}

.trend-product-stars {
  inset-inline: 10px;
  inset-block-end: 10px;
  border: 1px solid rgba(255, 255, 255, 0.24);
  border-radius: 16px;
  padding: 8px 9px;
  background: rgba(7, 24, 47, 0.48);
  color: var(--white);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.16), 0 12px 22px rgba(7, 24, 47, 0.16);
  font-size: clamp(0.82rem, 1.7vw, 1.02rem);
  font-weight: 950;
  letter-spacing: 0.08em;
  line-height: 1;
  text-align: center;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.trend-product-card.mini {
  width: min(210px, 100%);
  min-height: 240px;
}

.trend-admin-preview {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.trend-product-form-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.trend-admin-meta {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.trend-delete-form {
  margin-top: 12px;
  display: flex;
  justify-content: flex-start;
}

.trend-info-note {
  margin-bottom: 14px;
}

@media (max-width: 980px) {
  .home-trends-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .trend-product-form-row {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .home-trends-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .trend-product-card {
    min-height: 170px;
    border-radius: 20px;
  }

  .trend-product-card.mini {
    width: 100%;
    min-height: 220px;
  }

  .trend-product-form-row,
  .trend-admin-meta {
    grid-template-columns: 1fr;
  }
}


/* 16. Home smart coupon strip */
.home-coupons {
  position: relative;
  z-index: 1;
  margin-top: 26px;
  padding: 26px 18px 18px;
  overflow: hidden;
  border: 1px solid rgba(12, 45, 78, 0.11);
  border-radius: 30px;
  background:
    radial-gradient(circle at 10% 0%, rgba(36, 99, 235, 0.13), transparent 25rem),
    radial-gradient(circle at 90% 8%, rgba(18, 184, 166, 0.15), transparent 24rem),
    linear-gradient(135deg, rgba(255, 255, 255, 0.94), rgba(238, 247, 251, 0.82));
  box-shadow: 0 18px 46px rgba(11, 56, 88, 0.09);
}

.home-coupons::before,
.home-coupons::after {
  content: "";
  position: absolute;
  pointer-events: none;
  z-index: -1;
  border-radius: 999px;
}

.home-coupons::before {
  width: 190px;
  height: 190px;
  inset-block-start: -92px;
  inset-inline-start: -70px;
  background: rgba(5, 168, 200, 0.15);
}

.home-coupons::after {
  width: 260px;
  height: 260px;
  inset-block-end: -145px;
  inset-inline-end: -105px;
  background: rgba(79, 70, 229, 0.1);
}

.home-coupons-head small {
  max-width: 680px;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 780;
  line-height: 1.75;
}

.home-coupons-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  align-items: stretch;
}

.home-coupon-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 122px;
  border: 1px solid rgba(12, 45, 78, 0.12);
  border-radius: 26px;
  padding: 13px;
  display: grid;
  grid-template-columns: minmax(104px, 142px) minmax(0, 1fr) minmax(150px, 194px);
  grid-template-areas: "discount code actions";
  align-items: stretch;
  gap: 12px;
  direction: ltr;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.98), rgba(229, 247, 250, 0.9)),
    radial-gradient(circle at 50% 0%, rgba(5, 168, 200, 0.14), transparent 60%);
  color: var(--ink);
  box-shadow: 0 16px 38px rgba(11, 56, 88, 0.1);
  transform: translateZ(0);
  transition: transform 0.24s ease, box-shadow 0.24s ease, border-color 0.24s ease;
}

.home-coupon-card::before,
.home-coupon-card::after {
  content: "";
  position: absolute;
  pointer-events: none;
  z-index: 0;
}

.home-coupon-card::before {
  inset: 9px;
  border: 1px dashed rgba(5, 168, 200, 0.2);
  border-radius: 21px;
  opacity: 0.72;
}

.home-coupon-card::after {
  width: 82px;
  height: 82px;
  inset-block-start: -40px;
  inset-inline-end: -30px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(36, 99, 235, 0.2), rgba(18, 184, 166, 0.16));
}

.home-coupon-card:hover,
.home-coupon-card:focus-within {
  transform: translateY(-4px);
  border-color: rgba(5, 168, 200, 0.36);
  box-shadow: 0 26px 64px rgba(5, 168, 200, 0.16);
}

.home-coupon-glow {
  position: absolute;
  inset: auto auto -46px -44px;
  width: 126px;
  height: 126px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(18, 184, 166, 0.2), transparent 68%);
  pointer-events: none;
  z-index: -1;
}

.home-coupon-top,
.home-coupon-code-box,
.home-coupon-actions {
  position: relative;
  z-index: 1;
}

.home-coupon-top {
  grid-area: discount;
  min-width: 0;
  border: 1px solid rgba(5, 168, 200, 0.18);
  border-radius: 20px;
  padding: 12px 10px;
  display: grid;
  align-content: center;
  justify-items: center;
  gap: 8px;
  direction: rtl;
  background:
    radial-gradient(circle at 50% 0%, rgba(18, 184, 166, 0.16), transparent 62%),
    linear-gradient(135deg, rgba(238, 247, 251, 0.94), rgba(255, 255, 255, 0.72));
}

.home-coupon-kicker {
  width: fit-content;
  border: 1px solid rgba(5, 168, 200, 0.2);
  border-radius: var(--radius-pill);
  padding: 6px 9px;
  background: rgba(255, 255, 255, 0.78);
  color: var(--cyan-deep);
  font-size: 0.66rem;
  font-weight: 950;
  line-height: 1;
  text-align: center;
}

.home-coupon-top strong {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 4px;
  color: var(--ink);
  font-size: clamp(2.15rem, 4vw, 3.05rem);
  font-weight: 1000;
  letter-spacing: -0.09em;
  line-height: 0.95;
}

.home-coupon-top strong span {
  color: var(--cyan-deep);
  font-size: 0.45em;
  letter-spacing: -0.04em;
}

.home-coupon-code-box {
  grid-area: code;
  min-width: 0;
  border: 1px solid rgba(12, 45, 78, 0.1);
  border-radius: 19px;
  padding: 12px 16px;
  display: grid;
  align-content: center;
  gap: 7px;
  direction: rtl;
  background: rgba(255, 255, 255, 0.76);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.78);
}

.home-coupon-code-box span {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 920;
}

.home-coupon-code-box code {
  width: 100%;
  overflow-wrap: anywhere;
  color: var(--ink-2);
  font-size: clamp(1.08rem, 2vw, 1.48rem);
  font-weight: 1000;
  letter-spacing: 0.06em;
  line-height: 1.2;
}

.home-coupon-actions {
  grid-area: actions;
  min-width: 0;
  border-left: 1px dashed rgba(5, 168, 200, 0.24);
  padding-left: 12px;
  display: grid;
  grid-template-columns: 1fr;
  gap: 7px;
  align-self: stretch;
  direction: rtl;
}

.coupon-btn {
  min-height: 32px;
  border: 1px solid rgba(12, 45, 78, 0.12);
  border-radius: 14px;
  padding: 8px 10px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.84);
  color: var(--ink);
  box-shadow: 0 10px 20px rgba(11, 56, 88, 0.07);
  text-align: center;
  text-decoration: none;
  font-size: 0.72rem;
  font-weight: 940;
  line-height: 1.25;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.coupon-btn:hover,
.coupon-btn:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(5, 168, 200, 0.34);
  background: var(--white);
  box-shadow: 0 14px 28px rgba(5, 168, 200, 0.12);
}

.coupon-btn-app,
.coupon-btn-copy.copied {
  border-color: rgba(5, 168, 200, 0.32);
  background: linear-gradient(135deg, var(--blue), var(--cyan), var(--teal));
  color: var(--white);
}

.coupon-btn-copy {
  width: 100%;
}

.coupon-btn-copy.copy-error {
  border-color: var(--danger-border);
  background: var(--danger-bg);
  color: var(--danger-text);
}

.home-coupon-card.mini {
  width: min(520px, 100%);
  min-height: 112px;
  padding: 12px;
  grid-template-columns: minmax(88px, 112px) minmax(0, 1fr);
  grid-template-areas: "discount code";
}

.home-coupon-card.mini .home-coupon-actions {
  display: none;
}

.home-coupon-card.mini .home-coupon-top strong {
  font-size: 2.35rem;
}

.coupon-admin-preview {
  margin-top: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.coupon-form-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.coupon-admin-meta {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.coupon-delete-form {
  margin-top: 12px;
  display: flex;
  justify-content: flex-start;
}

.coupon-info-note {
  margin-bottom: 14px;
}

.coupon-admin-card {
  overflow: hidden;
}

@media (min-width: 1120px) {
  .home-coupons-grid {
    gap: 13px;
  }

  .home-coupon-card:first-child {
    grid-template-columns: minmax(118px, 152px) minmax(0, 1fr) minmax(170px, 218px);
  }
}

@media (max-width: 760px) {
  .home-coupons {
    padding: 22px 12px 14px;
    border-radius: 24px;
  }

  .home-coupon-card {
    min-height: 126px;
    border-radius: 22px;
    padding: 11px;
    grid-template-columns: minmax(74px, 96px) minmax(0, 1fr) minmax(104px, 124px);
    gap: 9px;
  }

  .home-coupon-card::before {
    display: none;
  }

  .home-coupon-top {
    border-radius: 17px;
    padding: 9px 7px;
  }

  .home-coupon-kicker {
    font-size: 0.56rem;
    padding: 5px 6px;
  }

  .home-coupon-top strong {
    font-size: clamp(1.6rem, 7vw, 2.15rem);
  }

  .home-coupon-code-box {
    padding: 10px 11px;
  }

  .home-coupon-code-box span {
    font-size: 0.66rem;
  }

  .home-coupon-code-box code {
    font-size: clamp(0.95rem, 4.3vw, 1.16rem);
  }

  .home-coupon-actions {
    padding-left: 9px;
    gap: 6px;
  }

  .coupon-btn {
    min-height: 33px;
    border-radius: 12px;
    padding: 7px 6px;
    font-size: 0.62rem;
  }

  .coupon-form-row,
  .coupon-admin-meta {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 520px) {
  .home-coupon-card {
    grid-template-columns: minmax(0, 1fr) minmax(100px, 116px);
    grid-template-areas:
      "discount actions"
      "code actions";
    gap: 8px;
  }

  .home-coupon-top {
    min-height: 52px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
  }

  .home-coupon-top strong {
    font-size: 1.82rem;
  }

  .home-coupon-code-box {
    min-height: 56px;
  }

  .home-coupon-actions {
    padding-left: 8px;
  }
}

@media (max-width: 390px) {
  .home-coupon-card {
    grid-template-columns: minmax(0, 1fr) minmax(88px, 100px);
    padding: 9px;
  }

  .home-coupon-kicker {
    font-size: 0.52rem;
  }

  .home-coupon-code-box {
    padding: 9px;
  }

  .home-coupon-code-box span {
    font-size: 0.62rem;
  }

  .home-coupon-code-box code {
    font-size: 0.9rem;
  }

  .coupon-btn {
    min-height: 31px;
    padding: 6px 4px;
    font-size: 0.56rem;
  }
}



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