/* ============================================================
   HOLLIBAE TWITCH EXPERIENCE
   Dedicated stylesheet for the Twitch section only.
   Load after styles.css and home-enhanced.css.
============================================================ */

.twitch-live-section {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  padding: 110px 0;
  background:
    radial-gradient(circle at 10% 14%, rgba(255,20,147,.12), transparent 30%),
    radial-gradient(circle at 90% 22%, rgba(0,217,255,.08), transparent 31%),
    radial-gradient(circle at 55% 92%, rgba(160,32,240,.10), transparent 34%),
    #050507;
}

.twitch-live-section::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  opacity: .18;
  background-image:
    linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: linear-gradient(to bottom, transparent, black 12%, black 86%, transparent);
}

.twitch-live-section::after {
  content: "";
  position: absolute;
  z-index: -1;
  width: 560px;
  height: 560px;
  right: -210px;
  top: 18%;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(160,32,240,.17), transparent 68%);
  filter: blur(28px);
  pointer-events: none;
}

.twitch-live-section .section-heading-row {
  margin-bottom: 44px;
}

.twitch-live-section .live-dot {
  animation: twitchLivePulse 1.7s ease-in-out infinite;
}

@keyframes twitchLivePulse {
  50% { opacity: .35; transform: scale(.72); }
}

/* MAIN CONSOLE */

.twitch-console {
  position: relative;
  overflow: hidden;
  width: 100%;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 30px;
  background:
    linear-gradient(180deg, rgba(255,255,255,.04), rgba(255,255,255,.012)),
    #09070d;
  box-shadow:
    0 50px 120px rgba(0,0,0,.50),
    0 0 65px rgba(160,32,240,.055),
    inset 0 1px 0 rgba(255,255,255,.035);
}

.twitch-console::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  box-shadow:
    inset 0 0 90px rgba(255,20,147,.024),
    inset 0 0 120px rgba(0,217,255,.016);
}

/* TOP BAR */

.twitch-console-header {
  position: relative;
  z-index: 5;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 0 22px;
  border-bottom: 1px solid rgba(255,255,255,.075);
  background:
    linear-gradient(
      90deg,
      rgba(255,20,147,.06),
      rgba(160,32,240,.025) 35%,
      rgba(255,255,255,.008) 60%,
      rgba(0,217,255,.045)
    );
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.console-left,
.console-right {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
}

.console-title {
  overflow: hidden;
  color: rgba(255,255,255,.62);
  font-size: .65rem;
  font-weight: 750;
  letter-spacing: .11em;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.console-channel {
  color: rgba(255,255,255,.35);
  font-size: .58rem;
  letter-spacing: .10em;
  white-space: nowrap;
}

.console-signal {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--hgreen);
  font-size: .58rem;
  font-weight: 900;
  letter-spacing: .09em;
  white-space: nowrap;
}

.console-signal i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--hgreen);
  box-shadow: 0 0 14px rgba(157,255,0,.90);
  animation: twitchSignalPulse 1.5s ease-in-out infinite;
}

@keyframes twitchSignalPulse {
  50% { opacity: .35; transform: scale(.75); }
}

.stream-dots {
  display: flex;
  gap: 6px;
  flex: 0 0 auto;
}

.stream-dots span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
}

.stream-dots span:nth-child(1) {
  background: var(--hpink);
  box-shadow: 0 0 12px rgba(255,20,147,.8);
}

.stream-dots span:nth-child(2) {
  background: var(--hpurple);
  box-shadow: 0 0 12px rgba(160,32,240,.8);
}

.stream-dots span:nth-child(3) {
  background: var(--hgreen);
  box-shadow: 0 0 12px rgba(157,255,0,.8);
}

/* MAIN GRID */

.twitch-layout {
  position: relative;
  z-index: 2;
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(340px, .55fr);
  align-items: stretch;
}

.twitch-video-column {
  min-width: 0;
  padding: 22px;
  border-right: 1px solid rgba(255,255,255,.075);
  background: radial-gradient(circle at 10% 10%, rgba(255,20,147,.035), transparent 32%);
}

/* PLAYER */

.twitch-video-frame {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  width: 100%;
  aspect-ratio: 16 / 9;
  min-height: 300px;
  border: 1px solid rgba(160,32,240,.25);
  border-radius: 22px;
  background:
    radial-gradient(circle at 50% 45%, rgba(160,32,240,.08), transparent 45%),
    #000;
  box-shadow:
    0 34px 90px rgba(0,0,0,.56),
    0 0 50px rgba(160,32,240,.075),
    0 0 28px rgba(255,20,147,.04);
}

.twitch-video-frame::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background:
    linear-gradient(90deg, rgba(255,20,147,.025), transparent 14%, transparent 86%, rgba(0,217,255,.022));
}

.twitch-player {
  position: absolute;
  inset: 0;
  z-index: 1;
  display: block;
  width: 100% !important;
  height: 100% !important;
  min-width: 0 !important;
  min-height: 0 !important;
  border: 0 !important;
  background: #000;
}

.twitch-corner {
  position: absolute;
  z-index: 8;
  width: 32px;
  height: 32px;
  pointer-events: none;
}

.corner-tl {
  left: 12px; top: 12px;
  border-left: 2px solid var(--hpink);
  border-top: 2px solid var(--hpink);
}

.corner-tr {
  right: 12px; top: 12px;
  border-right: 2px solid var(--hblue);
  border-top: 2px solid var(--hblue);
}

.corner-bl {
  left: 12px; bottom: 12px;
  border-left: 2px solid var(--hpurple);
  border-bottom: 2px solid var(--hpurple);
}

.corner-br {
  right: 12px; bottom: 12px;
  border-right: 2px solid var(--hgreen);
  border-bottom: 2px solid var(--hgreen);
}

.twitch-player-hud {
  position: absolute;
  z-index: 7;
  left: 18px;
  right: 18px;
  bottom: 17px;
  display: flex;
  align-items: flex-end;
  gap: 10px;
  pointer-events: none;
}

.twitch-player-hud > div {
  padding: 8px 11px;
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 10px;
  background: rgba(5,5,8,.72);
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 25px rgba(0,0,0,.25);
}

.twitch-player-hud span,
.twitch-player-hud b {
  display: block;
}

.twitch-player-hud span {
  color: rgba(255,255,255,.38);
  font-size: .47rem;
  letter-spacing: .11em;
}

.twitch-player-hud b {
  margin-top: 3px;
  color: #fff;
  font-size: .61rem;
  letter-spacing: .04em;
}

.twitch-player-hud .hud-right {
  margin-left: auto;
}

/* LOCAL DEVELOPMENT PREVIEW */

.twitch-dev-preview {
  position: absolute;
  inset: 0;
  z-index: 3;
  display: grid;
  place-items: center;
  padding: 32px;
  text-align: center;
  background:
    radial-gradient(circle at 50% 35%, rgba(160,32,240,.15), transparent 38%),
    linear-gradient(145deg, rgba(255,20,147,.05), rgba(0,217,255,.035)),
    #07070a;
}

.twitch-dev-preview-inner {
  max-width: 560px;
}

.twitch-dev-preview .dev-kicker {
  color: var(--hgreen);
  font-family: ui-monospace, monospace;
  font-size: .62rem;
  font-weight: 900;
  letter-spacing: .13em;
}

.twitch-dev-preview h4 {
  margin: 12px 0 8px;
  font-size: clamp(1.65rem, 3vw, 2.7rem);
  letter-spacing: -.045em;
}

.twitch-dev-preview p {
  margin: 0 auto 20px;
  color: #aaa3b1;
  line-height: 1.65;
}

/* PLAYER BUTTONS */

.twitch-player-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 11px;
  margin-top: 15px;
}

.twitch-player-actions .btn {
  width: 100%;
  min-height: 52px;
}

.btn.purple {
  border-color: rgba(160,32,240,.65);
  box-shadow: 0 0 20px rgba(160,32,240,.20);
}

.btn.purple:hover {
  background: rgba(160,32,240,.10);
}

/* INFO PANEL */

.twitch-info-panel {
  min-width: 0;
  padding: 30px;
  display: flex;
  flex-direction: column;
  background:
    radial-gradient(circle at 100% 0%, rgba(255,20,147,.10), transparent 28%),
    radial-gradient(circle at 0% 100%, rgba(0,217,255,.035), transparent 32%),
    linear-gradient(180deg, rgba(255,255,255,.018), rgba(255,255,255,.004));
}

.twitch-profile-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.twitch-live-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  width: fit-content;
  padding: 8px 12px;
  border: 1px solid rgba(255,20,147,.38);
  border-radius: 999px;
  background: rgba(255,20,147,.08);
  box-shadow: 0 0 18px rgba(255,20,147,.08);
  font-size: .62rem;
  font-weight: 900;
  letter-spacing: .08em;
}

.twitch-live-badge .status-dot {
  background: var(--hpink);
  box-shadow: 0 0 14px var(--hpink);
}

.panel-code {
  color: rgba(255,255,255,.31);
  font-family: ui-monospace, monospace;
  font-size: .56rem;
  letter-spacing: .08em;
}

.twitch-profile {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 28px;
}

.twitch-avatar-placeholder {
  width: 70px;
  height: 70px;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255,20,147,.34);
  border-radius: 20px;
  background: linear-gradient(135deg, rgba(255,20,147,.24), rgba(160,32,240,.14));
  color: #fff;
  font-size: 1.35rem;
  font-weight: 1000;
  box-shadow: 0 0 28px rgba(255,20,147,.10);
}

.profile-label {
  color: rgba(255,255,255,.37);
  font-size: .56rem;
  font-weight: 900;
  letter-spacing: .12em;
}

.twitch-profile h3 {
  margin: 4px 0 3px;
  color: #fff;
  font-size: clamp(2rem, 3vw, 2.8rem);
  line-height: .95;
  letter-spacing: -.05em;
}

.twitch-handle {
  color: var(--hpurple);
  font-family: ui-monospace, monospace;
  font-size: .72rem;
  transition: color .18s ease, text-shadow .18s ease;
}

.twitch-handle:hover {
  color: var(--hpink);
  text-shadow: 0 0 12px rgba(255,20,147,.28);
}

.twitch-description {
  margin: 24px 0 0;
  color: #aaa3b1;
  font-size: .94rem;
  line-height: 1.72;
}

.current-stream-card {
  margin-top: 23px;
  padding: 16px;
  border: 1px solid rgba(160,32,240,.20);
  border-radius: 15px;
  background:
    linear-gradient(110deg, rgba(160,32,240,.07), transparent 75%),
    rgba(255,255,255,.012);
}

.current-stream-heading {
  display: flex;
  align-items: center;
  gap: 10px;
}

.current-stream-heading span {
  color: rgba(255,255,255,.39);
  font-size: .55rem;
  font-weight: 900;
  letter-spacing: .11em;
}

.current-stream-heading i {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, rgba(160,32,240,.45), transparent);
}

.current-stream-card strong {
  display: block;
  margin-top: 9px;
  color: #fff;
  font-size: .80rem;
  line-height: 1.45;
}

.current-stream-card small {
  display: block;
  margin-top: 6px;
  color: rgba(255,255,255,.40);
  font-size: .70rem;
  line-height: 1.55;
}

.twitch-status-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0,1fr));
  gap: 9px;
  margin-top: 15px;
}

.twitch-stat {
  min-width: 0;
  padding: 13px;
  border: 1px solid rgba(255,255,255,.075);
  border-radius: 13px;
  background: rgba(255,255,255,.022);
}

.twitch-stat span,
.twitch-stat b {
  display: block;
}

.twitch-stat span {
  color: rgba(255,255,255,.34);
  font-size: .50rem;
  letter-spacing: .10em;
}

.twitch-stat b {
  margin-top: 5px;
  overflow: hidden;
  color: var(--hgreen);
  font-size: .71rem;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.stream-system-readout {
  margin-top: 17px;
}

.stream-system-readout > div:first-child {
  display: flex;
  justify-content: space-between;
  gap: 15px;
  margin-bottom: 8px;
  font-family: ui-monospace, monospace;
  font-size: .57rem;
}

.stream-system-readout span {
  color: rgba(255,255,255,.38);
}

.stream-system-readout strong {
  color: var(--hpink);
}

.system-meter {
  height: 7px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(255,255,255,.055);
}

.system-meter span {
  display: block;
  width: 97%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, #83104f, var(--hpink));
  box-shadow: 0 0 18px rgba(255,20,147,.30);
}

.blue-meter span {
  width: 86%;
  background: linear-gradient(90deg, #07718c, var(--hblue));
  box-shadow: 0 0 18px rgba(0,217,255,.28);
}

.twitch-big-button {
  width: 100%;
  min-height: 54px;
  margin-top: 27px;
}

/* CHAT */

.twitch-chat-section {
  position: relative;
  z-index: 3;
  border-top: 1px solid rgba(255,255,255,.075);
  background: linear-gradient(180deg, rgba(255,255,255,.012), rgba(255,255,255,.004));
}

.twitch-chat-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 24px 28px;
}

.twitch-chat-header h3 {
  margin: 6px 0 0;
  font-size: 1.65rem;
  letter-spacing: -.035em;
}

.twitch-chat-toggle {
  min-width: 135px;
  min-height: 42px;
  border: 1px solid rgba(0,217,255,.36);
  border-radius: 999px;
  padding: 10px 18px;
  background: rgba(0,217,255,.065);
  color: #fff;
  cursor: pointer;
  font-size: .75rem;
  font-weight: 900;
  letter-spacing: .05em;
}

.twitch-chat-toggle:hover {
  border-color: var(--hblue);
  background: rgba(0,217,255,.10);
  box-shadow: 0 0 20px rgba(0,217,255,.14);
}

.twitch-chat-container {
  display: none;
  padding: 0 24px 24px;
}

.twitch-chat-container.open {
  display: block;
}

.twitch-chat {
  display: block;
  width: 100%;
  height: 520px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 18px;
  background: #0e0e10;
  box-shadow: 0 25px 70px rgba(0,0,0,.32);
}

.twitch-chat-dev {
  padding: 28px;
  border: 1px solid rgba(0,217,255,.18);
  border-radius: 18px;
  background: rgba(0,217,255,.035);
  color: #aaa3b1;
  text-align: center;
}

/* SESSION FOOTER */

.twitch-bottom-message {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 20px;
  margin-top: 19px;
  padding: 0 4px;
}

.twitch-bottom-message p {
  margin: 0;
  color: rgba(255,255,255,.68);
  font-size: .83rem;
  text-align: center;
}

.twitch-bottom-code {
  color: rgba(255,255,255,.25);
  font-family: ui-monospace, monospace;
  font-size: .55rem;
  letter-spacing: .11em;
}

.twitch-bottom-code:last-child {
  text-align: right;
}

/* TABLET */

@media (max-width: 1100px) {
  .twitch-layout {
    grid-template-columns: 1fr;
  }

  .twitch-video-column {
    border-right: 0;
    border-bottom: 1px solid rgba(255,255,255,.075);
  }

  .twitch-info-panel {
    padding: 28px;
  }
}

/* MOBILE */

@media (max-width: 740px) {
  .twitch-live-section {
    padding: 76px 0;
  }

  .twitch-console {
    border-radius: 21px;
  }

  .twitch-console-header {
    align-items: flex-start;
    flex-direction: column;
    padding: 14px 16px;
  }

  .console-left,
  .console-right {
    width: 100%;
  }

  .console-right {
    justify-content: space-between;
  }

  .console-title,
  .console-channel {
    white-space: normal;
    line-height: 1.45;
  }

  .twitch-video-column {
    padding: 9px;
  }

  .twitch-video-frame {
    aspect-ratio: 16 / 9;
    min-height: 0;
    border-radius: 15px;
  }

  .twitch-player-hud {
    display: none;
  }

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

  .twitch-info-panel {
    padding: 21px;
  }

  .twitch-profile-top {
    align-items: flex-start;
    flex-direction: column;
  }

  .twitch-chat-header {
    align-items: flex-start;
    flex-direction: column;
    padding: 20px;
  }

  .twitch-chat-toggle {
    width: 100%;
  }

  .twitch-chat-container {
    padding: 0 10px 10px;
  }

  .twitch-chat {
    height: 460px;
    border-radius: 14px;
  }

  .twitch-bottom-message {
    grid-template-columns: 1fr;
  }

  .twitch-bottom-code,
  .twitch-bottom-code:last-child {
    text-align: center;
  }
}

@media (max-width: 520px) {
  .twitch-status-grid {
    grid-template-columns: 1fr;
  }

  .console-channel {
    display: none;
  }

  .twitch-avatar-placeholder {
    width: 56px;
    height: 56px;
    border-radius: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .console-signal i,
  .twitch-live-section .live-dot {
    animation: none;
  }
}
