* {
  box-sizing: border-box;
}

:root {
  --bg: #06080d;
  --panel: rgba(10, 15, 24, 0.84);
  --panel-strong: rgba(10, 15, 24, 0.96);
  --border: rgba(255,255,255,0.13);
  --text: #f4f7fb;
  --muted: #9aa7b6;
  --accent: #8fd3ff;
  --accent-soft: rgba(143, 211, 255, 0.16);
}

html,
body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  background: var(--bg);
  color: var(--text);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button {
  font: inherit;
}

#app {
  position: relative;
  width: 100%;
  height: 100%;
  overflow: hidden;
}

#scene {
  display: block;
  width: 100%;
  height: 100%;
  cursor: crosshair;
}

.topbar {
  position: absolute;
  z-index: 20;
  top: 20px;
  left: 22px;
  right: 22px;
  display: flex;
  justify-content: flex-end;
  align-items: center;
  pointer-events: none;
}

.brand,
.language-switch {
  pointer-events: auto;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  padding: 9px 12px;
  border: 1px solid var(--border);
  background: rgba(7, 10, 16, 0.72);
  backdrop-filter: blur(12px);
  border-radius: 999px;
  letter-spacing: .08em;
  font-size: 12px;
}

.status-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #7ee29b;
  box-shadow: 0 0 14px rgba(126,226,155,.7);
}

.language-switch {
  display: flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--border);
  background: rgba(7, 10, 16, 0.72);
  backdrop-filter: blur(12px);
  border-radius: 999px;
}

.lang {
  border: 0;
  color: var(--muted);
  background: transparent;
  border-radius: 999px;
  min-width: 44px;
  height: 36px;
  cursor: pointer;
}

.lang.active {
  background: var(--accent-soft);
  color: var(--text);
}

.intro-hint {
  position: absolute;
  z-index: 25;
  left: 50%;
  bottom: 72px;
  transform: translateX(-50%);
  width: min(560px, calc(100% - 32px));
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 14px;
  align-items: center;
  padding: 14px 16px;
  border: 1px solid var(--border);
  border-radius: 16px;
  background: rgba(6, 10, 17, 0.88);
  backdrop-filter: blur(16px);
  box-shadow: 0 18px 55px rgba(0,0,0,.35);
  transition: opacity .3s ease, transform .3s ease;
}

.intro-hint.hidden {
  opacity: 0;
  transform: translate(-50%, 10px);
  pointer-events: none;
}

.intro-hint strong {
  font-size: 12px;
  letter-spacing: .12em;
}

.intro-hint p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.45;
}

#close-hint,
.panel-close {
  color: var(--muted);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.04);
  border-radius: 10px;
  width: 38px;
  height: 38px;
  cursor: pointer;
  font-size: 20px;
}

.mouse-icon {
  width: 30px;
  height: 43px;
  border: 1px solid rgba(255,255,255,.4);
  border-radius: 15px;
  position: relative;
}

.mouse-icon span {
  position: absolute;
  top: 7px;
  left: 50%;
  width: 3px;
  height: 8px;
  border-radius: 10px;
  background: var(--accent);
  transform: translateX(-50%);
  animation: mouseMove 1.5s ease-in-out infinite;
}

@keyframes mouseMove {
  0%,100% { transform: translate(-50%,0); opacity: .35; }
  50% { transform: translate(-50%,7px); opacity: 1; }
}


.enter-fps {
  position: absolute;
  z-index: 24;
  left: 50%;
  top: 50%;
  transform: translate(-50%, 48px);
  min-width: 146px;
  height: 44px;
  padding: 0 18px;
  border: 1px solid rgba(143,211,255,.45);
  border-radius: 999px;
  background: rgba(9,17,28,.86);
  color: var(--text);
  letter-spacing: .12em;
  font-size: 11px;
  font-weight: 800;
  cursor: pointer;
  backdrop-filter: blur(12px);
  box-shadow: 0 0 28px rgba(92,174,230,.15);
  transition: opacity .2s ease, transform .2s ease, background .2s ease;
}

.enter-fps:hover {
  background: rgba(30,55,78,.92);
}

.enter-fps.hidden {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 58px);
}

.fps-status {
  position: absolute;
  z-index: 16;
  left: 50%;
  top: 22px;
  transform: translateX(-50%);
  padding: 0;
  border: 0;
  background: none;
  color: rgba(255,255,255,.85);
  font-size: 14px;
  font-weight: 400;
  letter-spacing: normal;
  pointer-events: none;
}

.crosshair {
  position: absolute;
  z-index: 15;
  left: 50%;
  top: 50%;
  width: 20px;
  height: 20px;
  transform: translate(-50%, -50%);
  pointer-events: none;
  opacity: .72;
}

.crosshair::before,
.crosshair::after {
  content: "";
  position: absolute;
  background: rgba(255,255,255,.75);
}

.crosshair::before {
  width: 1px;
  height: 20px;
  left: 9.5px;
}

.crosshair::after {
  height: 1px;
  width: 20px;
  top: 9.5px;
}

.object-tooltip {
  position: absolute;
  z-index: 18;
  left: 50%;
  top: calc(50% + 24px);
  transform: translateX(-50%);
  min-width: 100px;
  text-align: center;
  padding: 7px 10px;
  border-radius: 9px;
  border: 1px solid var(--border);
  background: rgba(6, 10, 17, 0.82);
  color: var(--text);
  font-size: 12px;
  opacity: 0;
  transition: opacity .15s ease;
  pointer-events: none;
}

.object-tooltip.visible {
  opacity: 1;
}

.info-panel {
  position: absolute;
  z-index: 30;
  top: 50%;
  left: 50%;
  right: auto;
  width: min(720px, calc(100% - 44px));
  max-height: min(76vh, 720px);
  overflow: auto;
  padding: 28px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--panel-strong);
  backdrop-filter: blur(18px);
  box-shadow: 0 26px 70px rgba(0,0,0,.42);
  transform: translate(-50%,-46%) scale(.96);
  opacity: 0;
  pointer-events: none;
  transition: transform .3s ease, opacity .3s ease;
}

.info-panel.open {
  transform: translate(-50%,-50%) scale(1);
  opacity: 1;
  pointer-events: auto;
}

.panel-close {
  position: absolute;
  top: 14px;
  right: 14px;
}

.panel-kicker {
  margin: 0 45px 8px 0;
  color: var(--accent);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.info-panel h2 {
  margin: 0 42px 16px 0;
  font-size: clamp(26px, 4vw, 40px);
  line-height: 1;
}

.panel-body {
  color: #cbd4df;
  font-size: 14px;
  line-height: 1.7;
}

.panel-body p {
  margin: 0 0 14px;
}

.panel-body .tags {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.panel-body .tag {
  display: inline-flex;
  padding: 6px 9px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(255,255,255,.04);
  color: #dce5ef;
  font-size: 12px;
}

.bottom-hud {
  position: absolute;
  z-index: 18;
  left: 22px;
  right: 22px;
  bottom: 20px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  pointer-events: none;
}

.direction-label,
.control-label {
  padding: 8px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(7, 10, 16, 0.65);
  backdrop-filter: blur(10px);
  font-size: 11px;
  letter-spacing: .08em;
  color: #c8d2df;
}

@media (max-width: 700px) {
  .topbar {
    top: 12px;
    left: 12px;
    right: 12px;
  }

  .brand {
    font-size: 10px;
  }

  .info-panel {
    top: 50%;
    left: 50%;
    right: auto;
    bottom: auto;
    width: calc(100% - 24px);
    max-height: 72%;
    padding: 22px;
    transform: translate(-50%,-46%) scale(.96);
  }

  .info-panel.open {
    transform: translate(-50%,-50%) scale(1);
  }

  .bottom-hud {
    left: 12px;
    right: 12px;
    bottom: 12px;
  }

  .control-label {
    display: none;
  }

  .intro-hint {
    bottom: 58px;
  }
}

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


.device-modal,
.certificate-viewer {
  position: absolute;
  z-index: 40;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 24px;
  background: rgba(3,6,10,.52);
  backdrop-filter: blur(10px);
  opacity: 0;
  pointer-events: none;
  transition: opacity .25s ease;
}

.device-modal.open,
.certificate-viewer.open {
  opacity: 1;
  pointer-events: auto;
}

.device-shell {
  position: relative;
  width: min(880px, 94vw);
  max-height: 82vh;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: #0a0f18;
  box-shadow: 0 35px 100px rgba(0,0,0,.55);
  padding: 24px;
}

/* The AI is projected directly onto the physical 3D monitor screen. */
.device-modal.computer-mode {
  display: block;
  padding: 0;
  background: transparent;
  backdrop-filter: none;
  pointer-events: none;
}

.device-modal.computer-mode.open {
  pointer-events: none;
}

.device-modal.computer-mode .device-shell {
  position: fixed;
  max-height: none;
  overflow: hidden;
  padding: 2px;
  border: 0;
  border-radius: 2px;
  background: #03070b;
  box-shadow: inset 0 0 30px rgba(81,166,218,.08);
  pointer-events: auto;
}

.device-modal.computer-mode #device-content {
  height: 100%;
  overflow: hidden;
}

.device-modal.computer-mode .device-close {
  top: 7px;
  right: 7px;
  border-color: rgba(143,211,255,.25);
  background: #18212b;
}

.device-close {
  position: absolute;
  z-index: 3;
  right: 14px;
  top: 14px;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  border: 1px solid var(--border);
  color: var(--text);
  background: rgba(255,255,255,.05);
  cursor: pointer;
  font-size: 20px;
}

.project-desktop {
  display: grid;
  grid-template-columns: 190px minmax(0,1fr);
  min-height: 470px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(180deg,#101827,#09101a);
}

.project-sidebar {
  padding: 18px;
  border-right: 1px solid rgba(255,255,255,.1);
  background: rgba(255,255,255,.025);
}

.project-sidebar h3 {
  margin: 0 0 16px;
  font-size: 13px;
  letter-spacing: .12em;
}

.project-nav {
  display: grid;
  gap: 8px;
}

.project-nav button {
  text-align: left;
  border: 1px solid transparent;
  background: transparent;
  color: var(--muted);
  padding: 10px;
  border-radius: 10px;
  cursor: pointer;
}

.project-nav button.active {
  background: var(--accent-soft);
  color: var(--text);
  border-color: rgba(143,211,255,.22);
}

.project-window {
  padding: 26px;
}

.project-window .eyebrow,
.phone-screen .eyebrow {
  color: var(--accent);
  font-size: 11px;
  letter-spacing: .14em;
  text-transform: uppercase;
  font-weight: 700;
}

.project-window h2 {
  margin: 7px 0 10px;
  font-size: clamp(28px,4vw,48px);
}

.project-window p {
  color: #c5cfdb;
  line-height: 1.7;
}

.stack-row {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-top: 18px;
}

.stack-chip {
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  padding: 6px 9px;
  border-radius: 999px;
  font-size: 12px;
  color: #dce5ef;
}

.phone-wrap {
  width: min(360px, 86vw);
  margin: auto;
  padding: 12px;
  border-radius: 36px;
  background: #030507;
  border: 1px solid rgba(255,255,255,.16);
  box-shadow: inset 0 0 0 5px #11161e, 0 30px 70px rgba(0,0,0,.45);
}

.phone-notch {
  width: 90px;
  height: 24px;
  margin: 0 auto 14px;
  border-radius: 0 0 16px 16px;
  background: #000;
}

.phone-screen {
  min-height: 500px;
  border-radius: 26px;
  padding: 24px 18px;
  background: linear-gradient(180deg,#172238,#0a111d);
}

.contact-grid {
  display: grid;
  gap: 10px;
  margin-top: 20px;
}

.contact-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 13px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 14px;
  background: rgba(255,255,255,.04);
}

.contact-card > div { min-width: 0; }
.contact-card a { overflow-wrap: anywhere; white-space: normal; }
.cert-choice a { display: inline-block; margin-top: 14px; color: #233e55; }
.project-window li, .timeline-item li { line-height: 1.7; margin-bottom: 8px; }
.project-sidebar { min-width: 0; }

.contact-icon {
  width: 40px;
  height: 40px;
  display: grid;
  place-items: center;
  border-radius: 12px;
  background: rgba(255,255,255,.07);
  font-size: 18px;
}

.certificate-card {
  position: relative;
  width: min(780px, 92vw);
  padding: 28px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: #151515;
  box-shadow: 0 35px 100px rgba(0,0,0,.6);
}

.certificate-paper {
  min-height: 430px;
  display: grid;
  place-items: center;
  align-content: center;
  text-align: center;
  border: 10px solid #c2a978;
  outline: 1px solid #6d5a35;
  padding: 42px;
  background: #efe6cf;
  color: #2e2c27;
  font-family: Georgia, "Times New Roman", serif;
}

.certificate-seal {
  font-size: 42px;
  margin-bottom: 12px;
}

.certificate-kicker {
  letter-spacing: .28em;
  font-size: 12px;
}

.certificate-paper h3 {
  margin: 8px 0;
  font-size: clamp(38px,6vw,64px);
  font-weight: 500;
}

.door-toast {
  position: absolute;
  z-index: 21;
  left: 50%;
  bottom: 112px;
  transform: translateX(-50%);
  padding: 10px 14px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: rgba(7,10,16,.84);
  color: #d7e0ea;
  opacity: 0;
  pointer-events: none;
  transition: opacity .2s ease;
}

.door-toast.visible {
  opacity: 1;
}

@media (max-width: 700px) {
  .project-desktop {
    grid-template-columns: 1fr;
  }
  .project-sidebar {
    border-right: 0;
    border-bottom: 1px solid rgba(255,255,255,.1);
  }
  .project-nav {
    grid-template-columns: repeat(2,minmax(0,1fr));
  }
}


/* V5 EXPERIENCE */
.room-toast {
  position: absolute;
  z-index: 35;
  left: 50%;
  top: 86px;
  transform: translate(-50%, -10px);
  opacity: 0;
  pointer-events: none;
  padding: 9px 13px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: rgba(6,10,17,.88);
  backdrop-filter: blur(12px);
  color: #dbe7f1;
  font-size: 12px;
  transition: opacity .2s ease, transform .2s ease;
}
.room-toast.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.info-panel {
  border-top: 1px solid rgba(143,211,255,.22);
}

.section-hero {
  margin: -4px -4px 18px;
  padding: 18px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 15px;
  background: linear-gradient(145deg,rgba(143,211,255,.09),rgba(255,255,255,.02));
}

.section-hero strong {
  display: block;
  font-size: 18px;
  color: var(--text);
}

.section-hero span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 12px;
}

.skill-groups {
  display: grid;
  gap: 13px;
}

.skill-group {
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 14px;
  padding: 13px;
  background: rgba(255,255,255,.025);
}

.skill-group h4 {
  margin: 0 0 9px;
  font-size: 12px;
  color: #eef5fb;
  letter-spacing: .08em;
}

.timeline {
  display: grid;
  gap: 0;
}

.timeline-item {
  position: relative;
  padding: 0 0 22px 25px;
  border-left: 1px solid rgba(255,255,255,.13);
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-item::before {
  content: "";
  position: absolute;
  left: -5px;
  top: 4px;
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 15px rgba(143,211,255,.55);
}

.timeline-item strong {
  display: block;
  color: var(--text);
  margin-bottom: 4px;
}

.timeline-item span {
  color: var(--muted);
  font-size: 12px;
}

.cert-grid {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  gap: 12px;
  margin-top: 16px;
}

.cert-choice {
  min-height: 160px;
  padding: 14px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 16px;
  background: linear-gradient(145deg,#e9dfc7,#d8c9a5);
  color: #28241c;
  text-align: left;
  cursor: pointer;
  transition: transform .16s ease, box-shadow .16s ease;
}
.cert-choice:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 32px rgba(0,0,0,.2);
}
.cert-choice .seal {
  font-size: 28px;
}
.cert-choice strong {
  display: block;
  margin-top: 18px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 18px;
}
.cert-choice small {
  display: block;
  margin-top: 5px;
  color: #625a48;
}

.edu-card {
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 15px;
  padding: 15px;
  background: rgba(255,255,255,.03);
}
.edu-card .degree {
  font-size: 17px;
  color: var(--text);
  font-weight: 700;
}
.edu-card .school {
  margin-top: 4px;
  color: var(--accent);
}
.edu-card .meta {
  margin-top: 7px;
  color: var(--muted);
  font-size: 12px;
}

.about-profile {
  display: grid;
  grid-template-columns: 76px 1fr;
  gap: 14px;
  align-items: center;
}
.about-avatar {
  width: 76px;
  height: 76px;
  display: grid;
  place-items: center;
  border-radius: 18px;
  border: 1px solid rgba(255,255,255,.12);
  background: linear-gradient(145deg,#20344c,#111925);
  font-size: 28px;
  font-weight: 800;
  color: #dcecff;
}
.about-profile p {
  margin: 0;
}

.project-metrics {
  display: grid;
  grid-template-columns: repeat(3,minmax(0,1fr));
  gap: 9px;
  margin-top: 20px;
}
.metric {
  padding: 11px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 12px;
  background: rgba(255,255,255,.025);
}
.metric strong {
  display: block;
  font-size: 18px;
}
.metric span {
  font-size: 10px;
  letter-spacing: .08em;
  color: var(--muted);
  text-transform: uppercase;
}

.project-terminal {
  margin-top: 18px;
  padding: 14px;
  border-radius: 13px;
  background: #05080d;
  border: 1px solid rgba(255,255,255,.1);
  font: 12px/1.7 ui-monospace,SFMono-Regular,Menlo,monospace;
  color: #b8d0e4;
}
.project-terminal .prompt {
  color: #7ee29b;
}

.focus-ring {
  position: absolute;
  z-index: 14;
  left: 50%;
  top: 50%;
  width: 46px;
  height: 46px;
  transform: translate(-50%,-50%);
  border-radius: 50%;
  border: 1px solid transparent;
  pointer-events: none;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.focus-ring.active {
  border-color: rgba(143,211,255,.55);
  box-shadow: 0 0 25px rgba(143,211,255,.25), inset 0 0 20px rgba(143,211,255,.08);
  transform: translate(-50%,-50%) scale(1.08);
}

@media (max-width:700px){
  .cert-grid {
    grid-template-columns: 1fr;
  }
  .project-metrics {
    grid-template-columns: 1fr;
  }
}


/* V6 MODEL MODE */
.top-actions {
  display: flex;
  align-items: center;
  gap: 8px;
  pointer-events: auto;
}

.asset-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--border);
  background: rgba(7,10,16,.72);
  backdrop-filter: blur(12px);
  border-radius: 999px;
  color: var(--muted);
  font-size: 10px;
  letter-spacing: .08em;
}

.asset-badge span {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #e0a85a;
  box-shadow: 0 0 12px rgba(224,168,90,.35);
}

.asset-badge.loaded span {
  background: #7ee29b;
  box-shadow: 0 0 14px rgba(126,226,155,.65);
}

.asset-badge b {
  font-weight: 700;
}

.cinematic-bars::before,
.cinematic-bars::after {
  content: "";
  position: absolute;
  z-index: 26;
  left: 0;
  right: 0;
  height: 0;
  background: #020305;
  pointer-events: none;
  transition: height .3s ease;
}

.cinematic-bars::before { top: 0; }
.cinematic-bars::after { bottom: 0; }

.cinematic-bars.active::before,
.cinematic-bars.active::after {
  height: 5.5%;
}

.info-panel,
.device-shell,
.certificate-card {
  transition:
    transform .3s ease,
    opacity .3s ease,
    border-color .2s ease;
}

.model-label {
  position: absolute;
  z-index: 16;
  padding: 6px 9px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(4,8,13,.72);
  color: #9eabb9;
  font-size: 10px;
  pointer-events: none;
}

@media (max-width:700px) {
  .asset-badge {
    display: none;
  }
}


.architecture-strip {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 18px;
  overflow-x: auto;
  padding-bottom: 4px;
}
.arch-node {
  flex: 0 0 auto;
  padding: 8px 10px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 10px;
  background: rgba(255,255,255,.035);
  color: #dce5ef;
  font-size: 11px;
}
.arch-arrow {
  color: #677789;
  font-size: 13px;
}


/* V8 FIRST PERSON */
.view-mode-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 0 12px;
  border: 1px solid var(--border);
  background: rgba(7,10,16,.72);
  backdrop-filter: blur(12px);
  border-radius: 999px;
  color: #dce8f2;
  font-size: 10px;
  letter-spacing: .08em;
}

.view-mode-badge span {
  color: var(--accent);
  font-size: 11px;
  text-shadow: 0 0 12px rgba(143,211,255,.7);
}

.view-mode-badge b {
  font-weight: 700;
}

@media (max-width: 820px) {
  .view-mode-badge {
    display: none;
  }
}


/* V10 DAY NIGHT */
.cycle-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-height: 44px;
  padding: 0 11px;
  border: 1px solid var(--border);
  background: rgba(7,10,16,.72);
  backdrop-filter: blur(12px);
  border-radius: 999px;
  color: #dbe6ef;
  font-size: 10px;
  letter-spacing: .07em;
}

.cycle-badge span {
  width: 18px;
  text-align: center;
  font-size: 14px;
}

.cycle-badge b {
  font-weight: 700;
}

.cycle-badge small {
  color: var(--muted);
  font-size: 9px;
  letter-spacing: .02em;
}

@media (max-width: 960px) {
  .cycle-badge {
    display: none;
  }
}


/* V11 AI TERMINAL */
.ai-terminal {
  min-height: 560px;
  display: grid;
  grid-template-rows: auto 1fr auto;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 18px;
  overflow: hidden;
  background: #05090e;
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
}

.device-modal.computer-mode .ai-terminal {
  height: 100%;
  min-height: 0;
  border: 0;
  border-radius: 3px;
}

.device-modal.computer-mode .ai-chat-log {
  min-height: 0;
  max-height: none;
}

.ai-terminal-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 13px 16px;
  border-bottom: 1px solid rgba(255,255,255,.09);
  background: #0b121c;
}

.ai-terminal-title {
  display: flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.ai-terminal-title .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #7ee29b;
  box-shadow: 0 0 12px rgba(126,226,155,.55);
}

.ai-terminal-title strong {
  font-size: 12px;
  letter-spacing: .08em;
}

.ai-terminal-status {
  color: #81909e;
  font-size: 10px;
  white-space: nowrap;
}

.ai-chat-log {
  min-height: 340px;
  max-height: 56vh;
  overflow: auto;
  padding: 18px;
  scroll-behavior: smooth;
}

.ai-message {
  display: grid;
  grid-template-columns: 32px minmax(0,1fr);
  gap: 10px;
  margin-bottom: 16px;
  color: #cbd7e2;
  font-size: 13px;
  line-height: 1.65;
}

.ai-message .avatar {
  width: 32px;
  height: 32px;
  display: grid;
  place-items: center;
  border-radius: 9px;
  border: 1px solid rgba(255,255,255,.09);
  background: #101925;
  color: #8fd3ff;
  font-size: 10px;
  font-weight: 800;
}

.ai-message.user .avatar {
  color: #7ee29b;
}

.ai-message .bubble {
  min-width: 0;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.ai-message .meta {
  display: block;
  margin-bottom: 3px;
  color: #708091;
  font-size: 10px;
  letter-spacing: .07em;
  text-transform: uppercase;
}

.ai-terminal-bottom {
  padding: 13px;
  border-top: 1px solid rgba(255,255,255,.09);
  background: #080e16;
}

.ai-suggestions {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  margin-bottom: 10px;
}

.ai-suggestion {
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 999px;
  background: rgba(255,255,255,.035);
  color: #9fb0bf;
  padding: 7px 9px;
  cursor: pointer;
  font: inherit;
  font-size: 10px;
}

.ai-suggestion:hover {
  color: #e4edf5;
  border-color: rgba(143,211,255,.28);
}

.ai-form {
  display: grid;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 8px;
}

.ai-form input {
  width: 100%;
  min-width: 0;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 11px;
  outline: none;
  padding: 12px 13px;
  background: #04080d;
  color: #eaf2f8;
  font: inherit;
  font-size: 13px;
}

.ai-form input:focus {
  border-color: rgba(143,211,255,.45);
  box-shadow: 0 0 0 3px rgba(143,211,255,.08);
}

.ai-send {
  min-width: 88px;
  border: 1px solid rgba(143,211,255,.25);
  border-radius: 11px;
  background: rgba(143,211,255,.12);
  color: #e7f4ff;
  cursor: pointer;
  font: inherit;
  font-size: 12px;
  font-weight: 700;
}

.ai-send:disabled,
.ai-form input:disabled {
  opacity: .55;
  cursor: wait;
}

.ai-command-help {
  margin-top: 9px;
  color: #687888;
  font-size: 10px;
}

.ai-command-help code {
  color: #9dc8e5;
}

.project-wall-note {
  color: var(--muted);
  font-size: 12px;
}

@media (max-width:700px) {
  .device-modal.computer-mode .device-shell {
    padding: 1px;
  }
  .ai-terminal {
    min-height: 500px;
  }
  .ai-chat-log {
    max-height: 48vh;
  }
  .ai-form {
    grid-template-columns: 1fr;
  }
  .ai-send {
    min-height: 44px;
  }
}


/* V13 PANORAMA */
.panorama-badge {
  padding: 8px 11px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgba(7,10,16,.58);
  backdrop-filter: blur(10px);
  color: #9fb0bf;
  font-size: 10px;
  letter-spacing: .08em;
}

@media (max-width: 760px) {
  .panorama-badge {
    display: none;
  }
}
