:root {
  --navy: #0f1b3d;
  --navy-2: #172858;
  --gold: #f5a623;
  --gold-soft: #fff0cf;
  --cream: #fbf3ea;
  --cream-2: #f7efe4;
  --admin-bg: #fbf8f2;
  --surface: #fffdf8;
  --line: #e8dcc8;
  --text: #2b2b2e;
  --muted: #8a8578;
  --green: #3e7b4f;
  --green-soft: #e8f3eb;
  --red: #c64b3c;
  --red-soft: #fde8e3;
  --shadow: 0 24px 70px rgba(15, 27, 61, 0.14);
  --shadow-soft: 0 12px 34px rgba(15, 27, 61, 0.1);
  --radius: 10px;
  color-scheme: light;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  color: var(--text);
  background: var(--cream);
}

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

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

button,
a,
label {
  -webkit-tap-highlight-color: transparent;
}

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

h1,
h2,
h3,
p {
  margin-top: 0;
}

.material-symbols-outlined {
  font-size: 20px;
  line-height: 1;
  vertical-align: -0.2em;
}

.hidden {
  display: none !important;
}

.eyebrow {
  margin: 0 0 7px;
  color: var(--gold);
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.brand-logo {
  width: 66px;
  height: 66px;
  flex: 0 0 66px;
  object-fit: cover;
  border: 1px solid rgba(245, 166, 35, 0.64);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: 0 14px 30px rgba(15, 27, 61, 0.18);
}

.portal-mark {
  width: 58px;
  height: 58px;
  flex: 0 0 58px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(245, 166, 35, 0.72);
  border-radius: 999px;
  color: var(--gold);
  background: var(--navy);
  box-shadow: 0 14px 30px rgba(15, 27, 61, 0.18);
  font-family: Fraunces, Georgia, serif;
  font-size: 23px;
  font-style: italic;
  font-weight: 700;
}

.primary-button,
.secondary-button,
.danger-button,
.text-button {
  border-radius: var(--radius);
  border: 1px solid transparent;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 0 16px;
  font-weight: 800;
  cursor: pointer;
  white-space: nowrap;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease, border-color 160ms ease;
}

.primary-button {
  color: #1d1406;
  background: linear-gradient(135deg, #ffd16f, var(--gold));
  border-color: #d78d12;
  box-shadow: 0 14px 28px rgba(245, 166, 35, 0.28);
}

.secondary-button {
  color: var(--navy);
  background: var(--surface);
  border-color: var(--line);
}

.danger-button {
  color: #fff;
  background: var(--red);
  border-color: var(--red);
}

.text-button {
  min-height: 34px;
  padding: 0;
  color: var(--gold);
  background: transparent;
}

.primary-button:hover,
.secondary-button:hover,
.danger-button:hover {
  transform: translateY(-1px);
}

.primary-button:focus-visible,
.secondary-button:focus-visible,
.danger-button:focus-visible,
.text-button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
.branch-card:focus-within,
.chip-button:focus-visible,
.star-row button:focus-visible,
.segment button:focus-visible {
  outline: 3px solid rgba(245, 166, 35, 0.35);
  outline-offset: 2px;
}

.primary-button:disabled,
.danger-button:disabled {
  opacity: 0.62;
  cursor: not-allowed;
}

.primary-button.compact,
.secondary-button.compact,
.danger-button.compact {
  min-height: 38px;
  padding: 0 12px;
}

input,
select,
textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  min-height: 46px;
  padding: 12px 13px;
  color: var(--text);
  background: #fffefb;
  outline: none;
  transition: border-color 160ms ease, box-shadow 160ms ease, background 160ms ease;
}

input:focus,
select:focus,
textarea:focus {
  border-color: var(--gold);
  box-shadow: 0 0 0 4px rgba(245, 166, 35, 0.16);
  background: #fff;
}

textarea {
  min-height: 82px;
  resize: vertical;
}

.password-control {
  position: relative;
}

.password-control input {
  padding-right: 48px;
}

.password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 0;
  border-radius: 8px;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
}

.password-toggle:hover {
  color: var(--navy);
  background: rgba(15, 27, 61, 0.06);
}

.password-toggle .material-symbols-outlined {
  font-size: 20px;
}

.field {
  display: grid;
  gap: 8px;
}

.field label,
.control-label,
.rating-label,
.checkbox-row {
  color: #433b32;
  font-size: 13px;
  font-weight: 800;
}

.field label span,
.optional-label {
  color: var(--muted);
  font-size: 12px;
  font-weight: 700;
}

.guest-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 10% 4%, rgba(245, 166, 35, 0.22), transparent 28rem),
    linear-gradient(180deg, var(--cream), var(--cream-2));
}

.guest-shell {
  width: min(1180px, calc(100% - 36px));
  min-height: 100vh;
  margin: 0 auto;
}

.branch-screen {
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(320px, 0.88fr) minmax(420px, 1.12fr);
  gap: 44px;
  align-items: center;
  padding: 42px 0;
}

.branch-hero {
  display: grid;
  gap: 16px;
  color: var(--navy);
}

.brand-lockup,
.rail-brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand-lockup strong {
  display: block;
  font-family: Fraunces, Georgia, serif;
  font-size: 28px;
  line-height: 1.05;
}

.branch-hero h1 {
  max-width: 560px;
  margin: 0;
  color: var(--navy);
  font-family: Fraunces, Georgia, serif;
  font-size: 52px;
  line-height: 1;
}

.lead {
  max-width: 520px;
  margin: 0;
  color: #51483e;
  font-size: 18px;
  line-height: 1.6;
}

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

.branch-card {
  position: relative;
  display: flex;
  min-height: 84px;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 17px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.92);
  box-shadow: 0 10px 30px rgba(15, 27, 61, 0.06);
  cursor: pointer;
  transition: border-color 160ms ease, transform 160ms ease, box-shadow 160ms ease;
}

.branch-card:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-soft);
}

.branch-card input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.branch-card:has(input:checked) {
  border-color: var(--gold);
  background: linear-gradient(135deg, #fff8e9, #fffdf8);
  box-shadow: 0 18px 42px rgba(245, 166, 35, 0.18);
}

.branch-card-main {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.branch-dot {
  width: 12px;
  height: 12px;
  flex: 0 0 12px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 0 5px rgba(62, 123, 79, 0.12);
}

.branch-card strong,
.branch-card small {
  display: block;
}

.branch-card strong {
  color: var(--navy);
  font-size: 17px;
}

.branch-card small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.35;
}

.branch-status {
  flex: 0 0 auto;
  border-radius: 999px;
  padding: 7px 10px;
  color: #745017;
  background: var(--gold-soft);
  font-size: 11px;
  font-weight: 900;
  text-transform: uppercase;
}

.bill-token-card {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 13px 14px;
  border: 1px dashed rgba(15, 27, 61, 0.2);
  border-radius: var(--radius);
  color: var(--muted);
  background: rgba(255, 253, 248, 0.64);
  font-size: 13px;
  font-weight: 700;
}

.bill-token-card .material-symbols-outlined {
  color: var(--gold);
}

.branch-submit {
  width: 100%;
  margin-top: 6px;
}

.branch-login-card {
  width: min(460px, 100%);
  justify-self: end;
  display: grid;
  gap: 16px;
  padding: 22px;
  border: 1px solid rgba(232, 220, 200, 0.96);
  border-top: 4px solid var(--gold);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.94);
  box-shadow: var(--shadow);
}

.branch-login-card h2 {
  margin: 0;
  color: var(--navy);
  font-family: Fraunces, Georgia, serif;
  font-size: 27px;
  line-height: 1.1;
}

.branch-login-card p {
  margin: 7px 0 0;
  color: var(--muted);
  line-height: 1.5;
}

.branch-login-card p strong {
  color: var(--navy);
}

.feedback-screen {
  min-height: 100vh;
  padding: 18px 0;
}

.feedback-shell {
  min-height: calc(100vh - 36px);
  display: grid;
  grid-template-columns: 1fr;
  overflow: hidden;
  border: 1px solid rgba(232, 220, 200, 0.9);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.invitation-rail {
  position: relative;
  min-height: auto;
  display: grid;
  grid-template-columns: auto minmax(260px, 1fr) 154px;
  align-items: center;
  gap: 18px;
  overflow: hidden;
  padding: 14px 16px;
  color: #fff;
  background:
    radial-gradient(circle at 18% 10%, rgba(245, 166, 35, 0.26), transparent 16rem),
    linear-gradient(180deg, var(--navy-2), var(--navy));
}

.invitation-rail::after {
  display: none;
}

.rail-brand {
  position: relative;
  z-index: 1;
}

.rail-logo {
  width: 44px;
  height: 44px;
  flex-basis: 44px;
  box-shadow: 0 14px 26px rgba(0, 0, 0, 0.22);
}

.rail-brand strong,
.rail-brand small {
  display: block;
}

.rail-brand strong {
  font-family: Fraunces, Georgia, serif;
  color: #fff;
  font-size: 22px;
  line-height: 1;
}

.rail-brand small {
  margin-top: 3px;
  color: var(--gold);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.invitation-copy {
  position: relative;
  z-index: 1;
  max-width: none;
}

.invitation-copy h2 {
  margin: 0;
  color: #fff;
  font-family: Fraunces, Georgia, serif;
  font-size: 24px;
  line-height: 1.08;
}

.invitation-copy p {
  margin: 6px 0 0;
  color: #e9dfd2;
  font-size: 13px;
  font-style: italic;
  line-height: 1.45;
}

.invitation-copy span {
  display: none;
  margin-top: 0;
  color: var(--gold);
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.rail-photo {
  position: relative;
  z-index: 1;
  width: 100%;
  height: 82px;
  object-fit: cover;
  border: 1px solid rgba(245, 166, 35, 0.32);
  border-radius: var(--radius);
}

.feedback-panel {
  min-width: 0;
  padding: 16px;
  background: linear-gradient(180deg, var(--cream), var(--cream-2));
}

.feedback-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 10px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.8);
}

.context-badge {
  display: grid;
  gap: 4px;
}

.context-badge span,
.progress-copy span {
  color: var(--muted);
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.context-badge strong {
  color: var(--navy);
  font-size: 15px;
}

.progress-wrap {
  display: grid;
  gap: 8px;
  margin-bottom: 12px;
}

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

.progress-copy strong {
  color: var(--navy);
}

.progress-track {
  height: 9px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(15, 27, 61, 0.1);
}

.progress-track span {
  display: block;
  width: 34%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--gold), var(--green));
  transition: width 180ms ease;
}

.feedback-form {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  gap: 12px;
}

.form-section {
  display: grid;
  gap: 10px;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.92);
}

.feedback-form .form-section:nth-of-type(1) {
  grid-column: 1;
  grid-row: 1;
}

.feedback-form .form-section:nth-of-type(2) {
  grid-column: 1;
  grid-row: 2;
}

.feedback-form .form-section:nth-of-type(3) {
  grid-column: 2;
  grid-row: 1 / span 2;
}

.section-head h3 {
  margin: 0;
  color: var(--navy);
  font-family: Fraunces, Georgia, serif;
  font-size: 20px;
  line-height: 1.12;
}

.inline-head,
.submit-row,
.rating-group,
.feedback-card header,
.feedback-row,
.panel-heading,
.admin-topbar {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
}

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

.rating-group {
  align-items: center;
}

.rating-label {
  min-width: 76px;
}

.star-row {
  display: flex;
  flex-wrap: nowrap;
  gap: 6px;
}

.star-row button {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(245, 166, 35, 0.35);
  border-radius: 999px;
  color: rgba(138, 133, 120, 0.7);
  background: #fff;
  cursor: pointer;
}

.star-row button .material-symbols-outlined {
  font-size: 22px;
  font-variation-settings: "FILL" 0;
}

.star-row button.active {
  color: var(--gold);
  border-color: var(--gold);
  background: #fff8e7;
}

.star-row button.active .material-symbols-outlined {
  font-variation-settings: "FILL" 1;
}

.chip-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
}

.chip-button {
  min-height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  border: 1px solid rgba(15, 27, 61, 0.22);
  border-radius: 999px;
  color: var(--navy);
  background: #fffefb;
  cursor: pointer;
  font-size: 13px;
  font-weight: 800;
}

.chip-button .material-symbols-outlined {
  color: var(--gold);
}

.chip-button.active {
  color: var(--navy);
  border-color: var(--gold);
  background: var(--gold-soft);
}

.chip-button.attention.active {
  color: var(--red);
  border-color: rgba(198, 75, 60, 0.45);
  background: var(--red-soft);
}

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

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

.segment {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 5px;
  margin-top: 8px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--cream-2);
}

.segment:has(button:nth-child(3)) {
  grid-template-columns: repeat(3, 1fr);
}

.segment button {
  min-height: 34px;
  border: 0;
  border-radius: 7px;
  color: #645c51;
  background: transparent;
  cursor: pointer;
  font-weight: 800;
}

.segment button.active {
  color: #fff;
  background: var(--navy);
}

.checkbox-row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  line-height: 1.45;
}

.checkbox-row input {
  width: 18px;
  height: 18px;
  min-height: 0;
  margin-top: 1px;
  accent-color: var(--green);
}

.submit-row {
  grid-column: 1 / -1;
  align-items: center;
  padding-top: 0;
}

.submit-row p {
  max-width: 420px;
  margin: 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.48;
}

.submit-row strong {
  color: var(--navy);
}

.toast {
  grid-column: 1 / -1;
  display: none;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: var(--green-soft);
  color: #27663b;
  font-weight: 750;
}

.toast.error {
  color: var(--red);
  background: var(--red-soft);
}

.toast.show {
  display: block;
}

.thanks-panel {
  min-height: 420px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 12px;
  padding: 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-align: center;
  background: var(--surface);
}

.thanks-panel > .material-symbols-outlined {
  color: var(--green);
  font-size: 48px;
  font-variation-settings: "FILL" 1;
}

.thanks-panel h3 {
  max-width: 520px;
  margin: 0;
  color: var(--navy);
  font-family: Fraunces, Georgia, serif;
  font-size: 32px;
  line-height: 1.14;
}

.thanks-panel p:not(.eyebrow) {
  max-width: 470px;
  margin: 0 0 10px;
  color: var(--muted);
  line-height: 1.6;
}

.admin-page {
  min-height: 100vh;
  background:
    radial-gradient(circle at 52% -10%, rgba(245, 166, 35, 0.24), transparent 30rem),
    var(--admin-bg);
}

.admin-login-view {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
  color: #fff;
  background:
    radial-gradient(circle at 50% 20%, rgba(245, 166, 35, 0.2), transparent 20rem),
    linear-gradient(180deg, var(--navy-2), var(--navy));
}

.login-card {
  width: min(390px, 100%);
  display: grid;
  gap: 16px;
  padding: 28px;
  border: 1px solid rgba(245, 166, 35, 0.24);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.97);
  box-shadow: var(--shadow);
}

.login-card .brand-lockup {
  align-items: flex-start;
}

.login-card .brand-logo {
  width: 58px;
  height: 58px;
  flex-basis: 58px;
}

.login-card h1 {
  margin: 0;
  color: var(--navy);
  font-family: Fraunces, Georgia, serif;
  font-size: 30px;
  line-height: 1.08;
}

.login-card p {
  margin: 0;
  color: var(--muted);
  line-height: 1.55;
}

.gold-rule {
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
}

.trust-copy {
  color: var(--muted);
  font-size: 12px;
  font-weight: 800;
  text-align: center;
}

.admin-shell {
  min-height: 100vh;
  display: grid;
  grid-template-columns: 248px minmax(0, 1fr);
}

.admin-rail {
  position: sticky;
  top: 0;
  height: 100vh;
  padding: 22px 16px;
  color: #fff;
  background: linear-gradient(180deg, var(--navy-2), var(--navy));
}

.admin-rail .rail-brand {
  margin-bottom: 26px;
}

.rail-status {
  display: grid;
  gap: 5px;
  margin-bottom: 22px;
  padding: 13px;
  border: 1px solid rgba(245, 166, 35, 0.22);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.07);
}

.rail-status span {
  color: #d7c6a7;
  font-size: 11px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.rail-status strong {
  color: #fff;
  font-size: 14px;
}

.admin-rail nav {
  display: grid;
  gap: 7px;
}

.admin-rail nav a {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 42px;
  padding: 0 12px;
  border-radius: var(--radius);
  color: #ded6ca;
  font-weight: 800;
}

.admin-rail nav a .material-symbols-outlined {
  color: var(--gold);
}

.admin-rail nav a.active,
.admin-rail nav a:hover {
  color: #fff;
  background: rgba(245, 166, 35, 0.18);
}

.admin-main {
  min-width: 0;
  padding: 26px;
}

.admin-topbar {
  align-items: center;
  margin-bottom: 18px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.86);
}

.admin-topbar h1 {
  margin: 0;
  color: var(--navy);
  font-family: Fraunces, Georgia, serif;
  font-size: 36px;
  line-height: 1.08;
}

.admin-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.branch-filter {
  width: auto;
  min-width: 190px;
  min-height: 38px;
  background: #fff;
}

.dashboard {
  display: grid;
  gap: 18px;
}

.dashboard-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 22px;
  padding: 22px;
  border-radius: var(--radius);
  color: #fff;
  background:
    radial-gradient(circle at 85% 0%, rgba(245, 166, 35, 0.2), transparent 18rem),
    linear-gradient(135deg, var(--navy), var(--navy-2));
  box-shadow: 0 18px 42px rgba(15, 27, 61, 0.18);
}

.dashboard-hero h2 {
  margin: 0;
  color: #fff;
  font-family: Fraunces, Georgia, serif;
  font-size: 34px;
  line-height: 1.1;
}

.dashboard-hero p {
  max-width: 720px;
  margin: 10px 0 0;
  color: #e9dfd3;
  line-height: 1.55;
}

.hero-stat {
  min-width: 166px;
  display: grid;
  align-content: center;
  gap: 7px;
  padding: 16px;
  border: 1px solid rgba(245, 166, 35, 0.24);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.08);
}

.hero-stat span {
  color: #e9dfd3;
  font-size: 12px;
  font-weight: 850;
}

.hero-stat strong {
  color: var(--gold);
  font-size: 34px;
}

.filter-panel,
.data-panel,
.kpi-card {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 253, 248, 0.94);
}

.filter-panel {
  display: grid;
  gap: 12px;
  padding: 14px;
}

.sentiment-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.sentiment-filters button {
  min-height: 34px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0 12px;
  color: var(--navy);
  background: #fff;
  cursor: pointer;
  font-size: 12px;
  font-weight: 850;
}

.sentiment-filters button::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--gold);
}

.sentiment-filters button[data-sentiment="commendations"]::before {
  background: var(--green);
}

.sentiment-filters button[data-sentiment="constructive"]::before {
  background: var(--gold);
}

.sentiment-filters button[data-sentiment="urgent"]::before {
  background: var(--red);
}

.sentiment-filters button.active {
  color: #fff;
  border-color: var(--navy);
  background: var(--navy);
}

.kpi-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(150px, 1fr));
  gap: 14px;
}

.kpi-card {
  min-height: 112px;
  position: relative;
  overflow: hidden;
  padding: 16px;
  box-shadow: none;
}

.kpi-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 4px;
  background: var(--gold);
}

.kpi-card.green::before {
  background: var(--green);
}

.kpi-card.alert::before {
  background: var(--red);
}

.kpi-card span {
  display: block;
  color: var(--muted);
  font-size: 12px;
  font-weight: 850;
  margin-bottom: 12px;
  text-transform: uppercase;
}

.kpi-card strong {
  color: var(--navy);
  font-size: 31px;
  line-height: 1;
}

.kpi-card small {
  display: block;
  margin-top: 6px;
  color: var(--muted);
  font-weight: 800;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(280px, 0.85fr);
  gap: 18px;
}

.table-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 18px;
}

.data-panel {
  min-width: 0;
  padding: 18px;
  box-shadow: none;
}

.panel-heading {
  align-items: center;
  margin-bottom: 16px;
}

.panel-heading h2 {
  margin: 0;
  color: var(--navy);
  font-family: Fraunces, Georgia, serif;
  font-size: 23px;
  line-height: 1.12;
}

.status-chip {
  border: 1px solid rgba(245, 166, 35, 0.24);
  border-radius: 999px;
  background: var(--gold-soft);
  color: #7b5317;
  padding: 7px 10px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

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

.branch-row {
  width: 100%;
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 12px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  background: var(--surface);
  cursor: pointer;
  text-align: left;
}

.branch-row strong,
.branch-row small {
  display: block;
}

.branch-row small {
  margin-top: 3px;
  color: var(--muted);
}

.score-bars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.score-card {
  min-height: 168px;
  display: grid;
  align-content: end;
  gap: 10px;
  padding: 14px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, #fff9ec, #f8e6c2);
}

.score-card i {
  width: 44px;
  min-height: 12px;
  border-radius: 7px 7px 0 0;
  background: linear-gradient(180deg, var(--gold), var(--navy));
}

.score-card strong {
  color: var(--navy);
  font-size: 26px;
}

.score-card span {
  color: var(--muted);
  font-weight: 850;
}

.bars {
  min-height: 184px;
  display: flex;
  align-items: end;
  gap: 10px;
  overflow-x: auto;
  border-bottom: 1px solid var(--line);
  padding: 8px 2px 18px;
}

.compact-bars {
  min-height: 160px;
}

.bar {
  flex: 1 0 38px;
  display: grid;
  align-items: end;
  gap: 8px;
  text-align: center;
  color: var(--muted);
  font-size: 12px;
}

.bar i {
  display: block;
  width: 100%;
  min-height: 7px;
  border-radius: 6px 6px 0 0;
  background: linear-gradient(180deg, var(--gold), var(--green));
}

.bar.violet i {
  background: linear-gradient(180deg, var(--navy-2), var(--gold));
}

.bar b {
  color: #4b433a;
  font-size: 12px;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  min-width: 560px;
  border-collapse: collapse;
  font-size: 13px;
}

th,
td {
  text-align: left;
  padding: 12px 10px;
  border-bottom: 1px solid #f0dfc7;
}

th {
  color: var(--muted);
  font-size: 12px;
  font-weight: 900;
}

.pill {
  display: inline-flex;
  align-items: center;
  border-radius: 999px;
  padding: 5px 9px;
  font-size: 12px;
  font-weight: 900;
  white-space: nowrap;
}

.Strong {
  color: #28683c;
  background: var(--green-soft);
}

.Steady {
  color: #745017;
  background: var(--gold-soft);
}

.Watch,
.Urgent {
  color: var(--red);
  background: var(--red-soft);
}

.Neutral {
  color: #485064;
  background: #eef1f5;
}

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

.recent-list {
  display: grid;
  gap: 10px;
}

.feedback-row {
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 13px;
  background: var(--surface);
}

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

.select-feedback {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.select-feedback input {
  width: 18px;
  height: 18px;
  min-height: 0;
  margin-top: 2px;
  accent-color: var(--navy);
}

.guest-avatar {
  width: 38px;
  height: 38px;
  flex: 0 0 38px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  color: #fff8ec;
  background: linear-gradient(145deg, var(--navy-2), var(--navy));
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.06em;
}

.guest-identity {
  min-width: 0;
}

.feedback-row strong {
  display: block;
  color: var(--navy);
  overflow-wrap: anywhere;
}

.feedback-comment {
  margin: 0;
  color: #4b433a;
  line-height: 1.45;
}

.feedback-row small,
.muted {
  color: var(--muted);
}

.rating-stars {
  color: var(--gold);
  font-size: 13px;
  font-weight: 900;
}

.feedback-card-footer {
  display: flex;
  justify-content: flex-end;
}

.details-toggle {
  min-height: 32px;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  border: 1px solid rgba(101, 127, 190, 0.18);
  border-radius: 999px;
  padding: 0 10px 0 12px;
  color: #14234d;
  background: rgba(239, 245, 255, 0.8);
  cursor: pointer;
  font-size: 12px;
  font-weight: 900;
}

.details-toggle:hover {
  border-color: rgba(15, 27, 61, 0.24);
  background: #eaf2ff;
}

.details-toggle .material-symbols-outlined {
  font-size: 18px;
}

.feedback-expanded {
  display: grid;
  gap: 10px;
}

.feedback-expanded[hidden] {
  display: none;
}

.feedback-details {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(128px, 1fr));
  gap: 8px;
}

.detail-chip,
.score-chip {
  min-width: 0;
  display: grid;
  gap: 4px;
  border: 1px solid rgba(101, 127, 190, 0.14);
  border-radius: 10px;
  padding: 9px 10px;
  background: rgba(239, 245, 255, 0.56);
}

.detail-chip small,
.score-chip small {
  color: #6f7891;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.detail-chip strong,
.score-chip strong {
  color: #14234d;
  font-size: 13px;
  line-height: 1.25;
}

.score-strip {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

.score-chip {
  border-color: rgba(245, 166, 35, 0.18);
  background: rgba(255, 240, 207, 0.45);
}

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

.empty-state {
  color: var(--muted);
  margin: 0;
}

.admin-login-view {
  align-items: start;
  place-items: start center;
  padding-top: min(24vh, 210px);
  background:
    radial-gradient(circle at 50% 20%, rgba(245, 166, 35, 0.06), transparent 16rem),
    linear-gradient(180deg, #0f1737, var(--navy));
}

.admin-login-card {
  width: min(380px, calc(100vw - 40px));
  display: grid;
  gap: 16px;
  color: #eef2ff;
}

.login-mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  justify-self: center;
  border: 1px solid var(--gold);
  border-radius: 999px;
  color: var(--gold);
  font-family: Fraunces, Georgia, serif;
  font-size: 20px;
  font-style: italic;
  font-weight: 700;
}

.admin-login-card h1 {
  margin: 4px 0 -8px;
  color: #fff7ec;
  font-family: Fraunces, Georgia, serif;
  font-size: 26px;
  line-height: 1.1;
  text-align: center;
}

.login-rule {
  width: 38px;
  height: 1px;
  justify-self: center;
  margin-bottom: 2px;
  background: var(--gold);
}

.admin-field {
  gap: 7px;
}

.admin-field label {
  color: #f2efe8;
  font-size: 13px;
  font-weight: 500;
}

.admin-field input,
.admin-field select {
  min-height: 44px;
  border-color: rgba(159, 181, 226, 0.64);
  color: #08142f;
  background: #eaf2ff;
}

.admin-field input::placeholder {
  color: #7d8aa6;
}

.admin-field input:focus,
.admin-field select:focus {
  border-color: rgba(245, 166, 35, 0.74);
  box-shadow: 0 0 0 4px rgba(245, 166, 35, 0.1);
  background: #f4f8ff;
}

.admin-password-control .password-toggle {
  color: #7582a0;
}

.admin-password-control .password-toggle:hover {
  color: var(--navy);
  background: rgba(15, 27, 61, 0.08);
}

.admin-field select option {
  color: #fff;
  background: var(--navy);
}

.login-submit {
  width: 100%;
  margin-top: 8px;
  color: #070b16;
  font-weight: 800;
  box-shadow: none;
}

.login-trust {
  margin: 10px 0 0;
  color: rgba(185, 198, 232, 0.72);
  font-size: 12px;
  text-align: center;
}

.admin-login-card .toast {
  color: #ffd5cd;
  background: rgba(198, 75, 60, 0.16);
  border: 1px solid rgba(198, 75, 60, 0.26);
}

.admin-console {
  min-height: 100vh;
  padding: 24px;
  background:
    radial-gradient(circle at 80% -10%, rgba(245, 166, 35, 0.2), transparent 26rem),
    linear-gradient(180deg, #0f1737 0, var(--navy) 250px, #eef3fb 250px, #f8f5ee 100%);
}

.console-topbar {
  width: min(1180px, 100%);
  margin: 0 auto 18px;
  display: grid;
  grid-template-columns: auto minmax(220px, 1fr) auto;
  align-items: center;
  gap: 18px;
  padding: 14px 16px;
  border: 1px solid rgba(245, 166, 35, 0.18);
  border-radius: 14px;
  background:
    radial-gradient(circle at 10% 0, rgba(245, 166, 35, 0.16), transparent 18rem),
    rgba(20, 35, 77, 0.9);
  box-shadow: 0 18px 44px rgba(15, 27, 61, 0.22);
  backdrop-filter: blur(14px);
}

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

.console-brand strong,
.console-brand small {
  display: block;
}

.console-brand strong {
  color: #fff8ec;
  font-family: Fraunces, Georgia, serif;
  font-size: 22px;
  line-height: 1;
}

.console-brand small {
  margin-top: 3px;
  color: #f4c46e;
  font-size: 10px;
  font-weight: 900;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.console-title {
  min-width: 0;
}

.console-title h1 {
  margin: 0;
  color: #fff8ec;
  font-family: Fraunces, Georgia, serif;
  font-size: 30px;
  line-height: 1.05;
}

.console-topbar .rail-logo {
  width: 42px;
  height: 42px;
  flex-basis: 42px;
}

.console-topbar .admin-actions {
  align-items: center;
}

.console-topbar .eyebrow {
  color: #f4c46e;
}

.console-topbar .branch-filter {
  border-color: rgba(255, 255, 255, 0.16);
  color: #fff8ec;
  background: rgba(255, 255, 255, 0.1);
}

.console-topbar .branch-filter option {
  color: var(--navy);
  background: #fff;
}

.console-topbar .secondary-button {
  border-color: rgba(255, 255, 255, 0.16);
  color: #fff8ec;
  background: rgba(255, 255, 255, 0.08);
}

.console-topbar .secondary-button:hover {
  background: rgba(255, 255, 255, 0.14);
}

.icon-button {
  width: 38px;
  padding: 0;
}

.simple-dashboard {
  width: min(1180px, 100%);
  margin: 0 auto;
  gap: 14px;
}

.simple-kpis {
  grid-template-columns: repeat(2, minmax(180px, 1fr));
}

.simple-kpis .kpi-card {
  min-height: 96px;
  border-color: rgba(101, 127, 190, 0.18);
  background: rgba(255, 253, 248, 0.98);
  box-shadow: 0 14px 34px rgba(15, 27, 61, 0.08);
}

.simple-kpis .kpi-card::before {
  width: 3px;
  background: var(--navy-2);
}

.simple-kpis .kpi-card.green::before {
  background: var(--green);
}

.simple-kpis .kpi-card.alert::before {
  background: var(--red);
}

.simple-kpis .kpi-card span {
  margin-bottom: 10px;
  color: #827b70;
}

.simple-kpis .kpi-card strong {
  font-size: 30px;
}

.console-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(300px, 0.65fr);
  gap: 14px;
  align-items: start;
}

.side-stack {
  display: grid;
  gap: 14px;
}

.console-grid .data-panel {
  border-color: rgba(101, 127, 190, 0.16);
  border-radius: 14px;
  background: rgba(255, 253, 248, 0.96);
  box-shadow: 0 14px 34px rgba(15, 27, 61, 0.08);
}

.recent-panel {
  min-height: 520px;
}

.inline-filter {
  margin-bottom: 12px;
  padding: 0;
  border: 0;
  background: transparent;
}

.simple-score-bars {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.score-line {
  display: grid;
  gap: 8px;
}

.score-line div {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--navy);
  font-size: 13px;
}

.score-line div span {
  color: var(--muted);
  font-weight: 800;
}

.score-line i {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: #ece5da;
}

.score-line i b {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #c7bda9, var(--gold));
}

.simple-dashboard .branch-row {
  min-height: 56px;
  border-color: rgba(101, 127, 190, 0.16);
  background: #fffefb;
  box-shadow: none;
}

.simple-dashboard .feedback-row {
  display: grid;
  gap: 12px;
  padding: 14px;
  border-color: rgba(101, 127, 190, 0.16);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(255, 253, 248, 0.98));
  box-shadow: 0 10px 26px rgba(15, 27, 61, 0.06);
}

.simple-dashboard .feedback-comment {
  display: -webkit-box;
  overflow: hidden;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.simple-dashboard .feedback-row.expanded .feedback-comment {
  display: block;
  overflow: visible;
}

@media (max-width: 1120px) {
  .branch-screen,
  .dashboard-grid,
  .table-grid,
  .console-grid {
    grid-template-columns: 1fr;
  }

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

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

@media (max-width: 820px) {
  .guest-shell {
    width: 100%;
  }

  .branch-screen {
    min-height: 100vh;
    gap: 22px;
    padding: 24px 16px;
  }

  .branch-login-card {
    width: 100%;
    justify-self: stretch;
  }

  .branch-hero h1 {
    font-size: 40px;
  }

  .feedback-screen {
    padding: 0;
  }

  .feedback-shell {
    min-height: 100vh;
    border-width: 0;
    border-radius: 0;
  }

  .invitation-rail {
    grid-template-columns: auto 1fr;
    padding: 12px 14px;
  }

  .invitation-copy h2 {
    font-size: 21px;
  }

  .invitation-copy p {
    display: none;
  }

  .rail-photo {
    display: none;
  }

  .feedback-panel {
    padding: 12px;
  }

  .feedback-form {
    grid-template-columns: 1fr;
  }

  .feedback-form .form-section:nth-of-type(1),
  .feedback-form .form-section:nth-of-type(2),
  .feedback-form .form-section:nth-of-type(3) {
    grid-column: auto;
    grid-row: auto;
  }

  .admin-shell {
    grid-template-columns: 1fr;
  }

  .admin-rail {
    position: static;
    height: auto;
    padding: 14px 16px;
  }

  .admin-rail .rail-brand {
    margin-bottom: 14px;
  }

  .admin-rail nav {
    display: flex;
    overflow-x: auto;
    padding-bottom: 4px;
  }

  .admin-rail nav a {
    flex: 0 0 auto;
  }

  .admin-main {
    padding: 18px 14px 30px;
  }

  .admin-topbar,
  .dashboard-hero {
    align-items: stretch;
    grid-template-columns: 1fr;
    flex-direction: column;
  }

  .admin-actions {
    justify-content: flex-start;
  }

  .branch-filter {
    width: 100%;
  }

  .admin-console {
    padding: 14px;
  }

  .console-topbar {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .console-topbar .admin-actions {
    justify-content: flex-start;
  }

  .simple-kpis {
    grid-template-columns: 1fr;
  }

  .recent-panel {
    min-height: auto;
  }
}

@media (max-width: 640px) {
  .brand-logo {
    width: 56px;
    height: 56px;
    flex-basis: 56px;
  }

  .brand-lockup strong {
    font-size: 23px;
  }

  .branch-hero h1 {
    font-size: 34px;
  }

  .lead {
    font-size: 16px;
  }

  .branch-card {
    align-items: flex-start;
    flex-direction: column;
    gap: 10px;
  }

  .feedback-toolbar,
  .inline-head,
  .submit-row,
  .rating-group,
  .feedback-card-head,
  .panel-heading,
  .admin-topbar {
    flex-direction: column;
    align-items: stretch;
  }

  .chip-grid,
  .form-grid,
  .choice-row,
  .score-strip,
  .score-bars,
  .kpi-grid {
    grid-template-columns: 1fr;
  }

  .star-row {
    justify-content: space-between;
  }

  .star-row button {
    width: 42px;
    height: 42px;
  }

  .primary-button,
  .secondary-button,
  .danger-button {
    width: 100%;
  }

  .form-section,
  .data-panel,
  .login-card {
    padding: 16px;
  }

  .row-actions,
  .bulk-actions {
    justify-content: flex-start;
  }
}
