/* ==========================================================================
   Okan Akgül — dinamik sistem banner'ı
   Ana sayfa hero'sundaki "canlı panel": kamera, ağ ve kod görünümleri.
   ========================================================================== */

/* --- Hero arka planı: yavaş kayan aurora -------------------------------- */
.hero {
  background:
    radial-gradient(60% 90% at 82% 0%, rgba(34, 211, 238, .18), transparent 62%),
    radial-gradient(55% 85% at 102% 96%, rgba(255, 46, 46, .3), transparent 64%),
    radial-gradient(50% 70% at 10% 100%, rgba(168, 85, 247, .14), transparent 68%),
    linear-gradient(150deg, #050810 0%, #0b1026 52%, #10182c 100%);
  background-size: 180% 180%, 180% 180%, 180% 180%, 100% 100%;
  animation: bannerAurora 22s ease-in-out infinite alternate;
}

@keyframes bannerAurora {
  0% { background-position: 0% 0%, 100% 100%, 0% 100%, 0 0; }
  100% { background-position: 28% 14%, 72% 82%, 24% 72%, 0 0; }
}

@media (min-width: 1025px) {
  .hero-inner {
    grid-template-columns: minmax(0, 1.22fr) minmax(380px, .78fr);
  }
}

@media (max-width: 1024px) {
  .hero-inner {
    grid-template-columns: 1fr;
  }

  .banner {
    max-width: 560px;
    margin-inline: auto;
  }
}

/* --- Panel kabuğu -------------------------------------------------------- */
.banner {
  --mx: 72%;
  --my: 0%;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 13px;
  width: 100%;
  max-width: 520px;
  padding: 20px;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 22px;
  background: linear-gradient(150deg, rgba(25, 36, 58, .94), rgba(8, 13, 24, .92));
  box-shadow:
    0 44px 90px -40px rgba(255, 46, 46, .5),
    0 30px 80px rgba(0, 0, 0, .45),
    inset 0 1px 0 rgba(255, 255, 255, .08);
  backdrop-filter: blur(18px);
  isolation: isolate;
  overflow: hidden;
}

.banner::before {
  content: "";
  position: absolute;
  top: 0;
  left: 26px;
  right: 26px;
  height: 3px;
  border-radius: 99px;
  background: linear-gradient(90deg, transparent, #ff8a3d, #ff2e2e, #ff3f8e, transparent);
  background-size: 200% 100%;
  animation: bannerTopFlow 6s linear infinite;
}

.banner::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: .55;
  background: radial-gradient(240px 200px at var(--mx) var(--my), rgba(255, 255, 255, .09), transparent 70%);
}

.banner > * {
  position: relative;
  z-index: 1;
}

@keyframes bannerTopFlow {
  to { background-position: 200% 0; }
}

.js .banner.reveal {
  transition:
    opacity .7s var(--ease-out),
    filter .8s var(--ease-out),
    transform .35s var(--ease-out),
    border-color .35s ease,
    box-shadow .35s ease;
}

.js .banner.reveal.is-visible {
  transform: none;
}

/* --- Üst satır ----------------------------------------------------------- */
.banner__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.banner__live {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, .64);
  font-size: .66rem;
  font-weight: 800;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.banner__live .dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #38e07b;
  box-shadow: 0 0 0 4px rgba(56, 224, 123, .13);
  animation: pulseDot 2s infinite;
}

.banner__tools {
  display: inline-flex;
  align-items: center;
  gap: 9px;
}

.banner__clock {
  color: #fff;
  font-family: var(--font-head);
  font-size: .9rem;
  font-weight: 700;
  letter-spacing: .08em;
  font-variant-numeric: tabular-nums;
}

.banner__pause {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 7px;
  background: rgba(255, 255, 255, .04);
  color: rgba(255, 255, 255, .55);
  font-size: .56rem;
  cursor: pointer;
  transition: color .2s ease, border-color .2s ease, background .2s ease;
}

.banner__pause:hover {
  color: #fff;
  border-color: rgba(255, 255, 255, .32);
  background: rgba(255, 255, 255, .08);
}

.banner__pause[aria-pressed="true"] {
  color: #ffb3b6;
  border-color: rgba(255, 70, 70, .45);
  background: rgba(255, 46, 46, .16);
}

.banner__pause:focus-visible {
  outline: 2px solid #ff8a8f;
  outline-offset: 2px;
}

/* --- Sekmeler ------------------------------------------------------------ */
.banner__tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
  padding: 4px;
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 11px;
  background: rgba(2, 6, 14, .5);
}

.banner__tab {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  height: 34px;
  padding: 0 6px;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: rgba(255, 255, 255, .55);
  font-family: inherit;
  font-size: .74rem;
  font-weight: 700;
  cursor: pointer;
  transition: color .25s ease, background .25s ease, box-shadow .25s ease;
}

.banner__tab i {
  font-size: .72rem;
  opacity: .85;
}

.banner__tab:hover {
  color: #fff;
}

.banner__tab.is-active {
  color: #fff;
  background: linear-gradient(135deg, rgba(255, 46, 46, .92), rgba(255, 95, 46, .82));
  box-shadow: 0 8px 20px -10px rgba(255, 46, 46, .95);
}

.banner__tab:focus-visible {
  outline: 2px solid #ff8a8f;
  outline-offset: 2px;
}

/* --- Sahne --------------------------------------------------------------- */
.banner__stage {
  position: relative;
  aspect-ratio: 16 / 10;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, .1);
  border-radius: 14px;
  background: #04070d;
}

.banner__panel {
  position: absolute;
  inset: 0;
  opacity: 0;
  visibility: hidden;
  transform: scale(1.015);
  transition: opacity .45s ease, transform .6s var(--ease), visibility .45s;
}

.banner__panel.is-active {
  opacity: 1;
  visibility: visible;
  transform: none;
}

/* --- Kamera görünümü ----------------------------------------------------- */
.cam {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(4, 8, 15, .48), rgba(4, 8, 15, .88)),
    url("../img/cover-camera.svg") center / cover no-repeat;
}

.cam__vignette {
  position: absolute;
  inset: 0;
  background: radial-gradient(120% 100% at 50% 42%, transparent 32%, rgba(2, 5, 10, .78) 100%);
}

.cam__grid {
  position: absolute;
  inset: 0;
  opacity: .16;
  background-image:
    linear-gradient(rgba(255, 255, 255, .3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .3) 1px, transparent 1px);
  background-size: 36px 36px;
  mask-image: radial-gradient(circle at 50% 50%, #000, transparent 78%);
}

.cam__scan {
  position: absolute;
  left: 0;
  right: 0;
  top: -30%;
  height: 26%;
  background: linear-gradient(180deg, transparent, rgba(103, 232, 249, .14) 55%, rgba(103, 232, 249, .4) 82%, transparent);
  mix-blend-mode: screen;
  animation: camScan 4.6s linear infinite;
}

@keyframes camScan {
  0% { transform: translateY(0); opacity: 0; }
  8% { opacity: 1; }
  92% { opacity: 1; }
  100% { transform: translateY(490%); opacity: 0; }
}

.cam__corner {
  position: absolute;
  width: 18px;
  height: 18px;
  border: 1.5px solid rgba(255, 255, 255, .55);
}

.cam__corner--tl { top: 11px; left: 11px; border-right: 0; border-bottom: 0; border-radius: 3px 0 0 0; }
.cam__corner--tr { top: 11px; right: 11px; border-left: 0; border-bottom: 0; border-radius: 0 3px 0 0; }
.cam__corner--bl { bottom: 11px; left: 11px; border-right: 0; border-top: 0; border-radius: 0 0 0 3px; }
.cam__corner--br { bottom: 11px; right: 11px; border-left: 0; border-top: 0; border-radius: 0 0 3px 0; }

.cam__rec {
  position: absolute;
  top: 12px;
  left: 38px;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 7px;
  border-radius: 5px;
  background: rgba(0, 0, 0, .42);
  color: #fff;
  font-size: .56rem;
  font-weight: 800;
  letter-spacing: .12em;
}

.cam__rec span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #ff3b3b;
  box-shadow: 0 0 8px #ff3b3b;
  animation: recBlink 1.6s steps(1) infinite;
}

@keyframes recBlink {
  0%, 62% { opacity: 1; }
  63%, 100% { opacity: .18; }
}

.cam__ch {
  position: absolute;
  left: 38px;
  bottom: 12px;
  color: rgba(255, 255, 255, .74);
  font-size: .56rem;
  font-weight: 700;
  letter-spacing: .09em;
}

.cam__stamp {
  position: absolute;
  right: 38px;
  bottom: 12px;
  color: rgba(255, 255, 255, .58);
  font-size: .56rem;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
}

.cam__box {
  position: absolute;
  border: 1px solid rgba(56, 224, 123, .9);
  border-radius: 4px;
  box-shadow: inset 0 0 24px rgba(56, 224, 123, .08), 0 0 18px rgba(56, 224, 123, .12);
}

.cam__box em {
  position: absolute;
  top: -16px;
  left: -1px;
  padding: 2px 5px;
  border-radius: 3px;
  background: #38e07b;
  color: #03120a;
  font-size: .48rem;
  font-style: normal;
  font-weight: 800;
  letter-spacing: .06em;
  white-space: nowrap;
}

.cam__box--a {
  top: 36%;
  left: 19%;
  width: 31%;
  height: 29%;
  animation: boxDriftA 8.5s ease-in-out infinite alternate;
}

.cam__box--b {
  right: 14%;
  bottom: 26%;
  width: 20%;
  height: 25%;
  border-color: rgba(103, 232, 249, .85);
  box-shadow: inset 0 0 24px rgba(103, 232, 249, .08), 0 0 18px rgba(103, 232, 249, .12);
  animation: boxDriftB 11s ease-in-out infinite alternate;
}

.cam__box--b em {
  background: #67e8f9;
  color: #04141a;
}

@keyframes boxDriftA {
  from { transform: translate(0, 0); }
  to { transform: translate(14px, 9px); }
}

@keyframes boxDriftB {
  from { transform: translate(0, 0); }
  to { transform: translate(-12px, -8px); }
}

/* --- Ağ görünümü --------------------------------------------------------- */
.net {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(80% 80% at 50% 50%, rgba(34, 211, 238, .1), transparent 72%),
    linear-gradient(160deg, #050e18, #07141f);
}

.net::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: .13;
  background-image:
    linear-gradient(rgba(255, 255, 255, .18) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .18) 1px, transparent 1px);
  background-size: 24px 24px;
  mask-image: radial-gradient(circle at 50% 50%, #000, transparent 82%);
}

.net__map {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.net__links path {
  stroke-dasharray: 5 7;
  animation: netDash 2.4s linear infinite;
}

@keyframes netDash {
  to { stroke-dashoffset: -24; }
}

.net__pulse {
  fill: #67e8f9;
  filter: drop-shadow(0 0 6px #67e8f9);
}

.net__ring {
  fill: none;
  stroke: rgba(255, 46, 46, .55);
  stroke-width: 1;
}

.net__node circle {
  fill: #0b1a26;
  stroke: rgba(103, 232, 249, .7);
  stroke-width: 1.5;
}

.net__node--core circle {
  fill: rgba(255, 46, 46, .16);
  stroke: #ff5f5f;
  stroke-width: 2;
}

.net__node text {
  fill: rgba(255, 255, 255, .62);
  font-family: var(--font-head);
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: .09em;
  text-anchor: middle;
}

.net__node--core text {
  fill: #fff;
  font-size: 9px;
}

.net__hud {
  position: absolute;
  top: 12px;
  left: 14px;
  padding: 3px 7px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 5px;
  background: rgba(0, 0, 0, .28);
  color: rgba(255, 255, 255, .68);
  font-size: .52rem;
  font-weight: 700;
  letter-spacing: .13em;
}

/* --- İstatistikler ------------------------------------------------------- */
.banner__stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  padding: 11px 0;
  border-top: 1px solid rgba(255, 255, 255, .08);
  border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.banner__stats div {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 0 4px;
  border-left: 1px solid rgba(255, 255, 255, .08);
}

.banner__stats div:first-child {
  border-left: 0;
}

.banner__stats b {
  color: #fff;
  font-family: var(--font-head);
  font-size: .98rem;
  font-weight: 800;
  letter-spacing: -.01em;
}

.banner__stats span {
  color: rgba(255, 255, 255, .45);
  font-size: .58rem;
  font-weight: 600;
  letter-spacing: .07em;
  text-align: center;
  text-transform: uppercase;
}

/* --- Butonlar ------------------------------------------------------------ */
.banner__actions {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: 8px;
}

.banner__actions .btn {
  width: auto;
  min-height: 42px;
  padding: 0 12px;
  border-radius: 11px;
  font-size: .79rem;
  white-space: nowrap;
}

.banner__actions .btn i {
  font-size: .9rem;
}

/* --- Durum satırı -------------------------------------------------------- */
.banner__status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-height: 16px;
  color: rgba(255, 255, 255, .45);
  font-size: .61rem;
}

.banner__status-live {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  min-width: 0;
}

.banner__status-dot {
  width: 5px;
  height: 5px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: #38e07b;
  box-shadow: 0 0 6px #38e07b;
}

.banner__status-text {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  transition: opacity .25s ease;
}

.banner__status-text.is-swapping {
  opacity: 0;
}

.banner__status a {
  color: rgba(255, 255, 255, .62);
  font-weight: 700;
  white-space: nowrap;
}

.banner__status a:hover {
  color: #ff8a8f;
}

/* --- Küçük ekranlar ------------------------------------------------------ */
@media (max-width: 420px) {
  .banner {
    padding: 16px;
    border-radius: 18px;
  }

  .banner__live {
    font-size: .6rem;
    letter-spacing: .13em;
  }

  .banner__clock {
    font-size: .8rem;
  }

  .banner__stats b {
    font-size: .9rem;
  }

  .banner__stats span {
    font-size: .52rem;
  }

  .banner__actions {
    grid-template-columns: 1fr;
  }

  .cam__ch,
  .cam__stamp {
    font-size: .5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero {
    animation: none;
  }

  .banner::before,
  .cam__scan,
  .cam__box,
  .cam__rec span,
  .net__links path {
    animation: none !important;
  }

  .net__pulse,
  .net__ring {
    display: none;
  }
}
