* { box-sizing: border-box; }
@property --wave-offset {
  syntax: "<length>";
  initial-value: 0px;
  inherits: false;
}
:root {
  --bg: #efe7db;
  --card: #ffffff;
  --ink: #111827;
  --muted: #667085;
  --line: #e5e7eb;
  --accent: #111827;
  --soft: #eef2f6;
  --good: #177245;
  --warn: #b45309;
  --bad: #b42318;
  --radius: 22px;
}
html { min-height: 100%; background: var(--bg); }
body {
  margin: 0;
  min-height: 100%;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  background:
    radial-gradient(circle at top left, rgba(212,175,55,.10), transparent 28rem),
    #efe7db;
}

.guest-page::before {
  content: "";
  position: fixed;
  left: 50%;
  bottom: -125px;
  width: min(920px, 130vw);
  height: 310px;
  transform: translateX(-50%);
  background: repeating-radial-gradient(
    ellipse at 50% 100%,
    transparent var(--wave-offset) calc(var(--wave-offset) + 30px),
    rgba(174,126,24,.28) calc(var(--wave-offset) + 31px) calc(var(--wave-offset) + 32px),
    transparent calc(var(--wave-offset) + 33px) calc(var(--wave-offset) + 56px)
  );
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 42%);
  mask-image: linear-gradient(to bottom, transparent, #000 42%);
  animation: waterRipple 3.4s linear infinite;
  pointer-events: none;
}

.guest-page::after {
  content: "";
  position: fixed;
  left: 50%;
  bottom: -150px;
  width: 520px;
  height: 260px;
  transform: translateX(-50%);
  border-radius: 50%;
  background: radial-gradient(ellipse, rgba(212,175,55,.22), transparent 68%);
  filter: blur(18px);
  animation: goldenGlow 4.5s ease-in-out infinite alternate;
  pointer-events: none;
}

@keyframes waterRipple {
  from { --wave-offset: 0px; }
  to { --wave-offset: 56px; }
}

@keyframes goldenGlow {
  from { opacity: .55; transform: translateX(-50%) scale(.92); }
  to { opacity: 1; transform: translateX(-50%) scale(1.08); }
}

@media (prefers-reduced-motion: reduce) {
  .guest-page::before,
  .guest-page::after { animation: none; }
}

.guest-page .app-shell {
  position: relative;
  z-index: 1;
}
button, input, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
a { color: inherit; text-decoration: none; }

.app-shell {
  width: min(100%, 560px);
  min-height: 100vh;
  margin: 0 auto;
  padding: 24px 18px 28px;
  display: flex;
  flex-direction: column;
}
.brand-row { display: flex; align-items: center; gap: 12px; }
.brand-mark {
  width: 52px;
  height: 52px;
  border-radius: 14px;

  display: flex;
  align-items: center;
  justify-content: center;

  background: #000;
  border: 2px solid #c89b2b;

  color: #d4af37;
  font-size: 34px;
  font-weight: 800;
  font-family: Georgia, "Times New Roman", serif;

  box-shadow:
    0 0 12px rgba(212,175,55,.35),
    inset 0 0 8px rgba(212,175,55,.15);
}
.brand-name { font-weight: 800; font-size: 18px; letter-spacing: -.02em; }
.brand-subtitle { font-size: 12px; color: var(--muted); }

.context-card {
  margin-top: 42px;
  display: flex; flex-wrap: wrap; justify-content: center; gap: 6px;
  padding: 12px 14px;
  background: transparent;
  border: 0;
  border-radius: 0;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}
.context-card strong { color: var(--ink); }

.screen {
  display: none;
  flex: 1;
  padding: 42px 0 12px;
  animation: fadeIn .25s ease;
}
.screen.active { display: flex; flex-direction: column; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

.celebration {
  position: fixed;
  inset: 0;
  z-index: 1000;
  overflow: hidden;
  pointer-events: none;
}

.celebration span {
  position: absolute;
  top: -18px;
  left: var(--x);
  width: 9px;
  height: 16px;
  border-radius: 2px;
  background: var(--color);
  box-shadow: 0 1px 3px rgba(17,24,39,.18);
  animation: confettiFall 2.4s cubic-bezier(.15,.7,.35,1) var(--delay) forwards;
}

.celebration span:nth-child(3n) {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

.celebration span:nth-child(4n) {
  width: 6px;
  height: 20px;
}

@keyframes confettiFall {
  to {
    transform: translate3d(var(--drift), 105vh, 0) rotate(var(--turn));
    opacity: .15;
  }
}

@media (prefers-reduced-motion: reduce) {
  .celebration { display: none; }
  .welcome-gold-line::after { animation: none; }
}

.hero-icon {
  width: 64px; height: 64px; border-radius: 20px;
  display: grid; place-items: center;
  background: var(--accent); color: white; font-size: 28px;
  margin-bottom: 22px;
}
.hero-icon.success { background: var(--good); }
h1, h2 { margin: 0; letter-spacing: -.035em; line-height: 1.08; }
h1 { font-size: clamp(36px, 9vw, 52px); }
h2 { font-size: clamp(28px, 7vw, 38px); }
h3 { margin: 0 0 12px; font-size: 15px; }
.welcome-title-end {
  display: flex;
  width: 100%;
  align-items: center;
  white-space: nowrap;
}
.welcome-gold-line {
  position: relative;
  overflow: hidden;
  flex: 1;
  height: 2px;
  margin-left: 20px;
  transform: translateY(5px);
  border-radius: 999px;
  background: linear-gradient(90deg, #c89b2b, rgba(212,175,55,.12));
  box-shadow: 0 1px 8px rgba(212,175,55,.18);
}
.welcome-gold-line::after {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 32%;
  border-radius: inherit;
  background: linear-gradient(90deg, transparent, #fff0a6, transparent);
  transform: translateX(-130%);
  animation: lineShimmer 6s ease-in-out infinite;
}
@keyframes lineShimmer {
  0%, 18% { transform: translateX(-130%); }
  72%, 100% { transform: translateX(420%); }
}
.lead { font-size: 18px; line-height: 1.5; color: var(--muted); margin: 16px 0 30px; }
.muted { color: var(--muted); line-height: 1.5; }
.step, .eyebrow {
  text-transform: uppercase; letter-spacing: .12em; font-size: 11px;
  font-weight: 800; color: var(--muted); margin-bottom: 12px;
}

.primary-btn, .secondary-btn, .danger-btn {
  border: 0; border-radius: 15px; padding: 15px 18px;
  font-weight: 750; cursor: pointer; text-align: center;
  transition: transform .15s ease, opacity .15s ease;
}
.primary-btn { background: var(--accent); color: white; }
.secondary-btn { background: var(--soft); color: var(--ink); }
.danger-btn { background: #fee4e2; color: var(--bad); }
.primary-btn:active, .secondary-btn:active, .danger-btn:active { transform: scale(.985); }
.compact { padding: 10px 13px; border-radius: 12px; font-size: 13px; }
.full-width { width: 100%; display: block; }
.link-btn {
  margin-top: 16px; border: 0; background: transparent;
  color: var(--muted); cursor: pointer; padding: 10px;
}
.button-row { display: grid; grid-template-columns: 1fr 1.4fr; gap: 12px; margin-top: auto; padding-top: 28px; }

.rating-grid {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}

.rating-btn {
  border: 1px solid var(--line);
  background: white;
  border-radius: 16px;

  display: grid;
  grid-template-columns: 28px auto 1fr;
  align-items: center;
  gap: 10px;

  padding: 17px 18px;
  cursor: pointer;
}

.rating-number {
  font-size: 22px;
  font-weight: 850;
  color: var(--ink);
}

.rating-stars {
  color: #d4af37;
  font-size: 16px;
  letter-spacing: 2px;
  white-space: nowrap;
}

.rating-label {
  font-size: 14px;
  color: var(--muted);
  font-weight: 650;
  justify-self: end;
text-align: right;
}

.rating-btn.selected {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent);
}

.chip-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 22px; }
.chip-grid label { position: relative; }
.chip-grid input { position: absolute; opacity: 0; }
.chip-grid span {
  min-height: 60px; display: flex; align-items: center;
  border: 1px solid var(--line); background: white; border-radius: 15px;
  padding: 14px; font-size: 14px; font-weight: 700; cursor: pointer;
}
.chip-grid input:checked + span { background: var(--ink); color: white; border-color: var(--ink); }

.employee-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 18px;
}

.employee-card {
  width: 100%;
  min-width: 0;
  border: 1px solid var(--line);
  background: white;
  border-radius: 13px;

  padding: 9px;
  display: flex;
  align-items: center;
  gap: 8px;

  text-align: left;
  cursor: pointer;
}

.employee-card.selected {
  background: var(--ink);
  border-color: var(--accent);
}

.employee-card.selected strong,
.employee-card.selected small {
  color: white;
}

.employee-card.selected .avatar {
  background: rgba(255,255,255,.16);
  color: white;
}

.avatar {
  width: 28px;
  height: 28px;
  min-width: 28px;
  border-radius: 50%;

  background: var(--soft);
  display: grid;
  place-items: center;

  font-size: 12px;
  font-weight: 800;
}

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

.employee-card strong {
  font-size: 13px;
  line-height: 1.15;
  color: var(--ink);
}

.employee-card small {
  margin-top: 2px;
  font-size: 10px;
  line-height: 1.1;
  color: var(--ink);
}

textarea, input[type="text"], input[inputmode="numeric"] {
  width: 100%; border: 1px solid var(--line); border-radius: 16px;
  background: white; padding: 15px; color: var(--ink); outline: none;
}
textarea { min-height: 145px; resize: vertical; margin-top: 22px; }
textarea:focus, input:focus { border-color: var(--ink); box-shadow: 0 0 0 2px rgba(17,24,39,.1); }
.optional-block { margin-top: 16px; padding: 16px; background: white; border: 1px solid var(--line); border-radius: 16px; }
.optional-block label { display: block; font-size: 13px; font-weight: 700; margin-bottom: 8px; }
.consent-row { display: flex !important; gap: 9px; align-items: flex-start; margin-top: 13px; font-weight: 500 !important; color: var(--muted); }
.hidden { display: none !important; }
.error-text { min-height: 22px; color: var(--bad); font-size: 13px; }
footer {
  padding-top: 22px;
  color: var(--muted);
  font-size: 11px;

  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 6px;

  width: 100%;
  text-align: center;
}

/* Dashboard */
.dashboard-shell { width: min(1440px, 100%); margin: 0 auto; padding: 22px; }
.dashboard-header, .dashboard-title {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
}
.dashboard-header { padding: 4px 0 28px; }
.header-actions { display: flex; flex-wrap: wrap; gap: 8px; justify-content: flex-end; }
.dashboard-title { margin-bottom: 20px; }
.dashboard-title h1 { font-size: clamp(30px, 4vw, 48px); }
.dashboard-title .eyebrow { margin: 0 0 8px; }
.date-pill { background: white; border: 1px solid var(--line); padding: 11px 14px; border-radius: 999px; font-size: 13px; color: var(--muted); }

.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 14px; }
.kpi-card, .panel {
  background: rgba(255,255,255,.94); border: 1px solid rgba(255,255,255,.95);
  border-radius: var(--radius); box-shadow: 0 12px 40px rgba(17,24,39,.06);
}

.insight-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 12px;
}

.insight-badge.good {
  background: #dcfce7;
  color: #166534;
}

.insight-badge.warning {
  background: #fef3c7;
  color: #92400e;
}

.insight-badge.critical {
  background: #fee2e2;
  color: #991b1b;
}
.kpi-card { padding: 20px; }
.kpi-card span { color: var(--muted); font-size: 13px; display: block; }
.kpi-card strong { display: block; font-size: 34px; margin: 10px 0 2px; letter-spacing: -.04em; }
.kpi-card small { color: var(--muted); }
.kpi-card.warning strong { color: var(--bad); }

.dashboard-grid { display: grid; gap: 14px; margin-bottom: 14px; }
.two-columns { grid-template-columns: 1.1fr .9fr; }
.panel { padding: 20px; }
.panel-heading { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 18px; }
.panel h2 { font-size: 22px; }
.panel .eyebrow { margin: 0 0 7px; }

.bar-list { display: grid; gap: 14px; }
.bar-row { display: grid; grid-template-columns: 110px 1fr 42px; align-items: center; gap: 10px; }
.bar-track { height: 10px; background: var(--soft); border-radius: 999px; overflow: hidden; }
.bar-fill { height: 100%; background: var(--ink); border-radius: inherit; }
.bar-row strong { text-align: right; }

.rating-row {
  display: grid;
  grid-template-columns: 45px 1fr 45px;
  align-items: center;
  gap: 12px;
  margin: 12px 0;
}

.rating-row strong {
  font-size: 15px;
}

.rating-row span {
  text-align: right;
  color: var(--muted);
  font-weight: 600;
}

.rating-track {
  height: 10px;
  background: #eef1f5;
  border-radius: 999px;
  overflow: hidden;
}

.rating-fill {
  height: 100%;
  background: #111827;
  border-radius: inherit;
}

.insight-columns { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; }
.insight-list { margin: 0; padding-left: 20px; display: grid; gap: 11px; }
.insight-list li { padding-left: 2px; line-height: 1.35; }
.insight-list small { display: block; color: var(--muted); margin-top: 3px; }
.insight-list.positive li::marker { color: var(--good); }
.insight-list.negative li::marker { color: var(--bad); }

.heatmap { display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; }
.heat-cell {
  min-height: 70px; border-radius: 14px; padding: 10px;
  display: flex; flex-direction: column; justify-content: space-between;
  border: 1px solid var(--line);
}
.heat-cell strong { font-size: 18px; }
.heat-cell small { color: var(--muted); }
.heat-good { background: #eaf7ef; }
.heat-mid { background: #fff4e5; }
.heat-bad { background: #feeceb; }

.employee-stats { display: grid; gap: 10px; }
.employee-stat {
  display: flex; justify-content: space-between; gap: 12px; align-items: center;
  padding: 12px; background: var(--soft); border-radius: 14px;
}
.employee-stat span { color: var(--muted); font-size: 13px; }

.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 760px; }
th, td { padding: 13px 12px; border-bottom: 1px solid var(--line); text-align: left; font-size: 13px; }
th { color: var(--muted); font-size: 11px; text-transform: uppercase; letter-spacing: .08em; }
.badge { display: inline-flex; padding: 5px 8px; border-radius: 999px; font-size: 11px; font-weight: 800; }
.badge.good { background: #eaf7ef; color: var(--good); }
.badge.mid { background: #fff4e5; color: var(--warn); }
.badge.bad { background: #feeceb; color: var(--bad); }
.empty-state { color: var(--muted); padding: 28px 0; text-align: center; }

@media (max-width: 980px) {
  .kpi-grid { grid-template-columns: 1fr 1fr; }
  .two-columns { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .chip-grid { grid-template-columns: 1fr; }
  .dashboard-shell { padding: 14px; }
  .dashboard-header, .dashboard-title { align-items: flex-start; flex-direction: column; }
  .header-actions { justify-content: flex-start; }
  .kpi-grid { grid-template-columns: 1fr; }
  .insight-columns { grid-template-columns: 1fr; }
  .heatmap { grid-template-columns: repeat(3, 1fr); }
  .bar-row { grid-template-columns: 90px 1fr 38px; }
}


/* Cloud v3 */
button:disabled {
  opacity: .62;
  cursor: not-allowed;
}

.honeypot {
  position: absolute !important;
  left: -10000px !important;
  width: 1px !important;
  height: 1px !important;
  overflow: hidden !important;
}

.auth-shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.auth-card {
  width: min(100%, 480px);
  background: rgba(255,255,255,.96);
  border: 1px solid rgba(255,255,255,.98);
  border-radius: 28px;
  padding: 28px;
  box-shadow: 0 24px 70px rgba(17,24,39,.12);
}

.auth-copy {
  margin-top: 38px;
}

.auth-copy h1 {
  font-size: clamp(34px, 8vw, 48px);
}

.auth-form {
  display: grid;
  gap: 10px;
  margin-top: 24px;
}

.auth-form label {
  margin-top: 6px;
  font-size: 13px;
  font-weight: 750;
}

.auth-form input {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 15px;
  padding: 14px 15px;
  background: white;
  color: var(--ink);
  outline: none;
}

.auth-form input:focus {
  border-color: var(--ink);
  box-shadow: 0 0 0 2px rgba(17,24,39,.1);
}

.auth-form .primary-btn {
  margin-top: 10px;
}

.manager-pill {
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  padding: 8px 12px;
  border-radius: 999px;
  background: white;
  border: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}

.status-text {
  min-height: 24px;
  margin: -6px 0 12px;
  color: var(--muted);
  font-size: 13px;
}

#guestVoice {
  height: 180px;
  position: relative;
  overflow: hidden;
}


.guest-comment {

  position:absolute;
  width:100%;

  padding:18px;
  box-sizing:border-box;

  background:#f8fafc;
  border-radius:18px;

  opacity:0;

  transform:translateX(-120%);

  transition:
    transform .7s ease,
    opacity .7s ease;

}


.guest-comment.show {

  opacity:1;
  transform:translateX(0);

}


.guest-comment.leave {

  opacity:0;

  transform:translateX(120%);

}



.guest-header {

  display:flex;
  justify-content:space-between;
  align-items:center;

  margin-bottom:12px;

}


.guest-comment p {

  margin:0;

  font-size:16px;

  line-height:1.5;

}



.guest-comment.good {
  border-left:5px solid #22c55e;
}


.guest-comment.mid {
  border-left:5px solid #f59e0b;
}


.guest-comment.bad {
  border-left:5px solid #ef4444;
}

.rating-star {
  display: inline-block;
  color: #d4af37;
  font-size: 14px;
  margin-left: 4px;
  vertical-align: middle;
}

.rating-btn {
  white-space: nowrap;
}

.employee-card strong,
.employee-card small {
  color: var(--ink);
}
