/* Vistorio Executive Dashboard page — CEO Experience */

/* ─── Hero headline stack ─── */
.ed-hero-title {
  margin: 0 0 1.25rem;
  line-height: 1.05;
  letter-spacing: -0.045em;
}

.ed-hero-title span {
  display: block;
  font-weight: 800;
  color: var(--ink);
}

.ed-hero-title span:nth-child(1) { font-size: clamp(1.75rem, 3.5vw, 2.5rem); }
.ed-hero-title span:nth-child(2) { font-size: clamp(2.25rem, 5vw, 3.75rem); }
.ed-hero-title span:nth-child(3) {
  font-size: clamp(1.35rem, 2.5vw, 1.85rem);
  color: var(--red);
  font-weight: 700;
  margin-top: 0.35rem;
}

.ed-hero-tagline {
  font-size: 0.95rem;
  font-weight: 600;
  color: var(--muted);
  margin: 0 0 1.5rem;
  max-width: 28rem;
  line-height: 1.5;
}

.ed-hero-tagline em {
  font-style: normal;
  color: var(--ink);
  font-weight: 700;
}

/* Extended questions */
.ed-questions {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
}

.ed-answer-banner h3 {
  font-size: clamp(1.25rem, 2.5vw, 1.65rem);
}

.ed-answer-banner strong {
  color: var(--success);
}

/* ─── Mega dashboard ─── */
.ed-mega {
  position: relative;
  margin-top: 2rem;
}

.ed-mega__frame {
  background: var(--ink);
  border-radius: 24px;
  padding: clamp(1.25rem, 3vw, 2rem);
  box-shadow: var(--shadow-lg), 0 0 0 1px rgba(255,255,255,0.06);
  overflow: hidden;
}

.ed-mega__top {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.25rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}

.ed-mega__top h3 {
  margin: 0;
  font-size: 0.9rem;
  font-weight: 700;
  color: #fff;
}

.ed-mega__meta {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.7rem;
  color: rgba(255,255,255,0.45);
}

.ed-mega__live {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--success);
}

.ed-mega__live::before {
  content: '';
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--success);
  animation: hp-pulse 1.5s ease infinite;
}

.ed-mega__grid {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 0.6rem;
  margin-bottom: 1.25rem;
}

@media (max-width: 1100px) {
  .ed-mega__grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 600px) {
  .ed-mega__grid { grid-template-columns: repeat(2, 1fr); }
}

.ed-mega__kpi {
  background: rgba(255,255,255,0.05);
  backdrop-filter: blur(8px);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 14px;
  padding: 0.85rem 0.9rem;
  transition: transform 0.25s var(--ease), border-color 0.25s;
}

.ed-mega__kpi:hover {
  transform: translateY(-2px);
  border-color: rgba(177,18,38,0.35);
}

.ed-mega__kpi label {
  display: block;
  font-size: 0.58rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.42);
  margin-bottom: 0.3rem;
}

.ed-mega__kpi strong {
  font-size: clamp(0.95rem, 2vw, 1.2rem);
  font-weight: 800;
  color: #fff;
  letter-spacing: -0.02em;
}

.ed-mega__kpi.accent strong { color: var(--warn); }
.ed-mega__kpi.warn strong { color: var(--danger); }
.ed-mega__kpi.pos strong { color: var(--success); }

.ed-mega__charts {
  display: grid;
  gap: 1rem;
}

@media (min-width: 800px) {
  .ed-mega__charts { grid-template-columns: 1.4fr 1fr; }
}

.ed-mega__chart {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: 14px;
  padding: 1rem;
  min-height: 140px;
}

.ed-mega__chart h4 {
  margin: 0 0 0.75rem;
  font-size: 0.72rem;
  font-weight: 700;
  color: rgba(255,255,255,0.55);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.ed-line-chart {
  height: 80px;
  position: relative;
}

.ed-line-chart svg {
  width: 100%;
  height: 100%;
}

.ed-line-chart polyline {
  fill: none;
  stroke: var(--red);
  stroke-width: 2.5;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 400;
  animation: ed-draw 2s var(--ease) forwards;
}

@keyframes ed-draw {
  from { stroke-dashoffset: 400; }
  to { stroke-dashoffset: 0; }
}

.ed-donut {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.ed-donut__ring {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: conic-gradient(var(--red) 0 87%, rgba(255,255,255,0.1) 87% 100%);
  display: grid;
  place-items: center;
  flex-shrink: 0;
}

.ed-donut__ring span {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: var(--ink);
  display: grid;
  place-items: center;
  font-size: 0.85rem;
  font-weight: 800;
  color: #fff;
}

.ed-donut__legend {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.75rem;
  color: rgba(255,255,255,0.55);
}

.ed-donut__legend b { color: #fff; }

/* ─── Insight notifications ─── */
.ed-insights {
  display: grid;
  gap: 0.85rem;
  grid-template-columns: repeat(auto-fill, minmax(18rem, 1fr));
}

.ed-insight {
  display: flex;
  gap: 0.85rem;
  align-items: flex-start;
  padding: 1.15rem 1.25rem;
  background: rgba(255,255,255,0.72);
  backdrop-filter: blur(16px) saturate(1.3);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s var(--ease), box-shadow 0.25s;
}

.ed-insight:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
}

.ed-insight__dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 0.35rem;
  animation: hp-pulse 2s ease infinite;
}

.ed-insight__dot--up { background: var(--success); }
.ed-insight__dot--warn { background: #b45309; }
.ed-insight__dot--info { background: var(--red); }

.ed-insight p {
  margin: 0;
  font-size: 0.92rem;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.45;
}

.ed-insight time {
  display: block;
  font-size: 0.68rem;
  font-weight: 600;
  color: var(--muted);
  margin-top: 0.35rem;
}

/* ─── Command centre sections ─── */
.ed-command {
  background: var(--surface);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.ed-command--dark {
  background: var(--ink);
  color: #fff;
  border: none;
}

.ed-command--dark .hp-eyebrow { color: var(--danger); }
.ed-command--dark .hp-h2 { color: #fff; }
.ed-command--dark .hp-lede { color: rgba(255,255,255,0.65); }

.ed-cmd-grid {
  display: grid;
  gap: 0.75rem;
  grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr));
  margin-bottom: 2rem;
}

.ed-cmd-card {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.1);
  border-radius: 14px;
  padding: 1rem;
}

.ed-command:not(.ed-command--dark) .ed-cmd-card {
  background: var(--page);
  border-color: var(--line);
}

.ed-cmd-card label {
  display: block;
  font-size: 0.65rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: rgba(255,255,255,0.45);
  margin-bottom: 0.35rem;
}

.ed-command:not(.ed-command--dark) .ed-cmd-card label { color: var(--muted); }

.ed-cmd-card strong {
  font-size: 1.35rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  color: #fff;
}

.ed-command:not(.ed-command--dark) .ed-cmd-card strong { color: var(--ink); }

.ed-cmd-card small {
  display: block;
  font-size: 0.72rem;
  font-weight: 600;
  margin-top: 0.25rem;
  color: rgba(255,255,255,0.45);
}

.ed-command:not(.ed-command--dark) .ed-cmd-card small { color: var(--muted); }

.ed-cmd-card small.pos { color: var(--success); }
.ed-cmd-card small.warn { color: var(--warn); }

/* Workflow vertical */
.ed-workflow {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  align-items: center;
  justify-content: center;
  margin: 2rem 0;
}

.ed-workflow__step {
  padding: 0.7rem 1.1rem;
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 999px;
  font-size: 0.82rem;
  font-weight: 600;
  color: #fff;
}

.ed-command:not(.ed-command--dark) .ed-workflow__step {
  background: var(--surface);
  border-color: var(--line);
  color: var(--ink);
}

.ed-workflow__arrow {
  color: var(--red);
  font-weight: 800;
}

/* Revenue charts row */
.ed-revenue-charts {
  display: grid;
  gap: 1rem;
  margin-top: 1.5rem;
}

@media (min-width: 900px) {
  .ed-revenue-charts { grid-template-columns: 2fr 1fr 1fr; }
}

.ed-rev-panel {
  background: var(--page);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 1.25rem;
  box-shadow: var(--shadow-sm);
}

.ed-rev-panel h4 {
  margin: 0 0 1rem;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.ed-rev-bars {
  display: flex;
  align-items: flex-end;
  gap: 0.4rem;
  height: 120px;
}

.ed-rev-bar {
  flex: 1;
  background: var(--red);
  border-radius: 6px 6px 0 0;
  animation: hp-bar-grow 1s var(--ease) backwards;
}

.ed-rev-bar:nth-child(1) { height: 55%; animation-delay: 0.05s; }
.ed-rev-bar:nth-child(2) { height: 78%; animation-delay: 0.1s; }
.ed-rev-bar:nth-child(3) { height: 62%; animation-delay: 0.15s; }
.ed-rev-bar:nth-child(4) { height: 90%; animation-delay: 0.2s; }
.ed-rev-bar:nth-child(5) { height: 70%; animation-delay: 0.25s; }
.ed-rev-bar:nth-child(6) { height: 85%; animation-delay: 0.3s; }
.ed-rev-bar:nth-child(7) { height: 95%; animation-delay: 0.35s; }

.ed-rev-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.ed-rev-list div {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.85rem;
  font-weight: 600;
}

.ed-rev-list span:last-child { font-weight: 800; color: var(--ink); }

.ed-rev-list .bar-track {
  height: 6px;
  background: var(--line);
  border-radius: 999px;
  overflow: hidden;
  flex: 1;
  margin: 0 0.75rem;
}

.ed-rev-list .bar-fill {
  height: 100%;
  background: var(--red);
  border-radius: 999px;
}

/* ─── Operations room grid ─── */
.ed-ops-board {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
}

.ed-ops-stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.ed-ops-stat {
  font-size: 0.78rem;
  font-weight: 700;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: var(--page);
  border: 1px solid var(--line);
}

.ed-ops-stat--occ { border-color: rgba(13,122,78,0.3); color: var(--success); }
.ed-ops-stat--vac { border-color: rgba(15,20,25,0.15); color: var(--muted); }
.ed-ops-stat--dirty { border-color: rgba(180,83,9,0.3); color: #b45309; }
.ed-ops-stat--oos { border-color: rgba(177,18,38,0.3); color: var(--red); }
.ed-ops-stat--ready { border-color: rgba(13,122,78,0.3); color: var(--success); }
.ed-ops-stat--clean { border-color: rgba(59,130,246,0.3); color: #2563eb; }
.ed-ops-stat--insp { border-color: rgba(168,85,247,0.3); color: #9333ea; }

.ed-room-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(4.5rem, 1fr));
  gap: 0.5rem;
}

.ed-room {
  aspect-ratio: 1;
  border-radius: 10px;
  display: grid;
  place-items: center;
  font-size: 0.72rem;
  font-weight: 800;
  color: #fff;
  transition: transform 0.2s var(--ease);
}

.ed-room:hover { transform: scale(1.06); }

.ed-room--occ { background: var(--success); }
.ed-room--vac { background: #94a3b8; color: var(--ink); }
.ed-room--dirty { background: #b45309; }
.ed-room--oos { background: var(--red); }
.ed-room--ready { background: #059669; }
.ed-room--clean { background: #2563eb; }
.ed-room--insp { background: #9333ea; }

/* ─── Module dashboards (inventory, restaurant, HK) ─── */
.ed-module-dash {
  display: grid;
  gap: 2rem;
  align-items: start;
}

@media (min-width: 900px) {
  .ed-module-dash { grid-template-columns: 1fr 1.1fr; }
  .ed-module-dash--flip > div:first-child { order: 2; }
  .ed-module-dash--flip > div:last-child { order: 1; }
}

.ed-dash-panel {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 1.35rem;
  box-shadow: var(--shadow-md);
}

.ed-dash-panel__head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid var(--line);
}

.ed-dash-panel__head strong {
  font-size: 0.85rem;
  font-weight: 700;
}

.ed-dash-panel__head span {
  font-size: 0.65rem;
  font-weight: 700;
  color: var(--success);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.ed-dash-kpis {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.ed-dash-kpi {
  background: var(--page);
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.75rem;
}

.ed-dash-kpi label {
  display: block;
  font-size: 0.62rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
  margin-bottom: 0.2rem;
}

.ed-dash-kpi b {
  font-size: 1rem;
  font-weight: 800;
  color: var(--ink);
}

.ed-dash-kpi b.warn { color: #b45309; }
.ed-dash-kpi b.alert { color: var(--red); }

.ed-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
}

.ed-table th,
.ed-table td {
  padding: 0.55rem 0.5rem;
  text-align: left;
  border-bottom: 1px solid var(--line);
}

.ed-table th {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--muted);
}

.ed-table td:last-child { font-weight: 700; text-align: right; }

.ed-badge {
  display: inline-block;
  font-size: 0.65rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
}

.ed-badge--low { background: rgba(177,18,38,0.1); color: var(--red); }
.ed-badge--ok { background: rgba(13,122,78,0.1); color: var(--success); }
.ed-badge--wait { background: rgba(180,83,9,0.1); color: #b45309; }

/* POS mock */
.ed-pos-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
}

.ed-pos-tile {
  background: var(--page);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.65rem;
  font-size: 0.75rem;
  font-weight: 600;
}

.ed-pos-tile b {
  display: block;
  font-size: 0.95rem;
  margin-top: 0.15rem;
}

/* HK status rows */
.ed-hk-rows {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.ed-hk-row {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.6rem 0.75rem;
  background: var(--page);
  border-radius: 10px;
  font-size: 0.8rem;
  font-weight: 600;
}

.ed-hk-row span:first-child {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  flex-shrink: 0;
}

/* ─── Mobile experience ─── */
.ed-mobile {
  background: var(--page-muted);
}

.ed-mobile__layout {
  display: grid;
  gap: 3rem;
  align-items: center;
}

@media (min-width: 900px) {
  .ed-mobile__layout { grid-template-columns: 1fr 1fr; }
}

.ed-phones {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  align-items: flex-end;
  perspective: 800px;
}

.ed-phone {
  width: 200px;
  background: var(--ink);
  border-radius: 28px;
  padding: 0.65rem;
  box-shadow: 0 32px 64px rgba(15,20,25,0.25);
  transform: rotateY(-6deg);
  animation: ed-phone-float 6s ease-in-out infinite;
}

.ed-phone--2 {
  width: 220px;
  transform: rotateY(4deg) translateY(-20px);
  animation-delay: -2s;
  z-index: 1;
}

@keyframes ed-phone-float {
  0%, 100% { transform: rotateY(-6deg) translateY(0); }
  50% { transform: rotateY(-6deg) translateY(-10px); }
}

.ed-phone--2 {
  animation-name: ed-phone-float-2;
}

@keyframes ed-phone-float-2 {
  0%, 100% { transform: rotateY(4deg) translateY(-20px); }
  50% { transform: rotateY(4deg) translateY(-30px); }
}

.ed-phone__screen {
  background: #f8f9fb;
  border-radius: 22px;
  min-height: 360px;
  overflow: hidden;
}

.ed-phone__status {
  display: flex;
  justify-content: space-between;
  padding: 0.5rem 0.75rem;
  font-size: 0.55rem;
  font-weight: 700;
  color: var(--muted);
}

.ed-phone__header {
  padding: 0.5rem 0.85rem 0.75rem;
  background: var(--ink);
  color: #fff;
}

.ed-phone__header strong {
  display: block;
  font-size: 0.75rem;
}

.ed-phone__header span {
  font-size: 0.55rem;
  color: rgba(255,255,255,0.55);
}

.ed-phone__body { padding: 0.75rem; }

.ed-phone__kpi {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  margin-bottom: 0.45rem;
}

.ed-phone__kpi label {
  font-size: 0.5rem;
  font-weight: 600;
  text-transform: uppercase;
  color: var(--muted);
}

.ed-phone__kpi b {
  font-size: 0.85rem;
  font-weight: 800;
}

.ed-phone__alert {
  background: rgba(177,18,38,0.08);
  border: 1px solid rgba(177,18,38,0.15);
  border-radius: 10px;
  padding: 0.55rem 0.65rem;
  font-size: 0.65rem;
  font-weight: 600;
  color: var(--red);
  margin-top: 0.5rem;
}

.ed-mobile__features {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 1.25rem;
}

.ed-mobile__features span {
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.4rem 0.85rem;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
}

@media (max-width: 700px) {
  .ed-phones { flex-direction: column; align-items: center; }
  .ed-phone, .ed-phone--2 { transform: none; animation: none; width: min(240px, 100%); }
}

/* ─── Decision maker roles ─── */
.ed-roles {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr));
}

.ed-role {
  padding: 1.5rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s var(--ease), border-color 0.25s;
}

.ed-role:hover {
  transform: translateY(-4px);
  border-color: rgba(177,18,38,0.2);
}

.ed-role__title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--red);
  margin-bottom: 0.35rem;
}

.ed-role h3 {
  margin: 0 0 0.65rem;
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.ed-role p {
  margin: 0;
  font-size: 0.85rem;
  color: var(--muted);
  line-height: 1.55;
}

.ed-role ul {
  margin: 0.85rem 0 0;
  padding: 0;
  list-style: none;
}

.ed-role li {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--ink);
  padding: 0.3rem 0;
  padding-left: 1rem;
  position: relative;
}

.ed-role li::before {
  content: '';
  position: absolute;
  left: 0;
  top: 0.65rem;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--red);
}

/* ─── Outcomes grid ─── */
.ed-outcomes {
  display: grid;
  gap: 1rem;
  grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr));
}

.ed-outcome {
  text-align: center;
  padding: 1.75rem 1.25rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}

.ed-outcome__icon {
  font-size: 1.5rem;
  margin-bottom: 0.65rem;
}

.ed-outcome h3 {
  margin: 0 0 0.35rem;
  font-size: 0.95rem;
  font-weight: 700;
}

.ed-outcome p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--muted);
  line-height: 1.5;
}

/* ─── Dark band CTA variant ─── */
.ed-command .hp-proc__row {
  border-color: rgba(255,255,255,0.1);
}

.ed-final {
  background: var(--ink);
  color: #fff;
  padding: clamp(4rem, 8vw, 6rem) 0;
  text-align: center;
}

.ed-final .hp-h2 { color: #fff; }
.ed-final .hp-lede { color: rgba(255,255,255,0.7); }

.ed-final .mk-btn-xl--outline {
  border-color: rgba(255,255,255,0.35);
  color: #fff;
}

.ed-final .mk-btn-xl--outline:hover {
  background: rgba(255,255,255,0.08);
}
