/* =========================================================
   YOLLUG — ORTAK TASARIM SİSTEMİ
   ========================================================= */

:root {
  --uyghur-blue: #1598e5;
  --uyghur-blue-dark: #0877c7;
  --uyghur-blue-light: #dff2ff;

  --navy: #071d4f;
  --navy-soft: #163568;

  --page-background: #f8fcff;
  --surface: rgba(255, 255, 255, 0.88);
  --surface-strong: #ffffff;

  --border: rgba(21, 152, 229, 0.34);
  --border-soft: rgba(21, 152, 229, 0.16);

  --text: #0c224f;
  --text-soft: #456080;

  --shadow:
    0 20px 55px rgba(24, 87, 137, 0.13),
    0 5px 18px rgba(24, 87, 137, 0.08);

  --content-width: 1480px;
  --transition: 180ms ease;
}


/* =========================================================
   TEMEL AYARLAR
   ========================================================= */

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  margin: 0;
  overflow-x: hidden;

  color: var(--text);

  font-family:
    Inter,
    -apple-system,
    BlinkMacSystemFont,
    "Segoe UI",
    Roboto,
    Helvetica,
    Arial,
    sans-serif;

  /*
   * Uygur bayrağından esinlenen mavi zemin.
   * Üst kısım biraz daha açık, kenarlar daha koyu tutuldu.
   */
  background:
    radial-gradient(
      circle at 50% 20%,
      #bfeaff 0%,
      #83cff3 38%,
      #47aee1 72%,
      #268fc9 100%
    );

  background-attachment: fixed;

  position: relative;
  isolation: isolate;
}

/*
/*
 * Gerçek tamga ve Göktürk motiflerinin bulunduğu
 * yoğun tekrar eden arka plan katmanı.
 */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;

  pointer-events: none;

  background-image:
    url("/assets/images/yollug-turkic-pattern.svg");

  /*
   * SVG 1200 × 1200 hazırlanmıştı.
   * Küçülterek tekrar sıklığını artırıyoruz.
   */
  background-size: 560px 560px;
  background-repeat: repeat;
  background-position: center top;

  opacity: 0.72;
}


/*
 * Yazıların rahat okunabilmesi için sayfanın merkezinde
 * hafif, yarı saydam bir aydınlık alan oluşturur.
 * Motifleri tamamen kapatmaz.
 */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;

  pointer-events: none;

  background:
    radial-gradient(
      ellipse at 50% 38%,
      rgba(255, 255, 255, 0.62) 0%,
      rgba(255, 255, 255, 0.38) 28%,
      rgba(255, 255, 255, 0.13) 55%,
      rgba(255, 255, 255, 0.02) 82%
    );
}


/* =========================================================
   GENEL BAĞLANTILAR VE BUTONLAR
   ========================================================= */

a {
  color: inherit;
  text-decoration: none;
}

button,
select,
input {
  font: inherit;
}

button,
select,
a {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid rgba(21, 152, 229, 0.42);
  outline-offset: 4px;
}


/* =========================================================
   SAYFA KABUĞU
   ========================================================= */

.site-shell {
  width: min(100%, var(--content-width));
  min-height: 100vh;
  margin: 0 auto;
  padding: 0 48px;
}


/* =========================================================
   ÜST MENÜ
   ========================================================= */

.site-header {
  min-height: 148px;
  padding: 25px 0;

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

.brand {
  grid-column: 2;

  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 25px;

  min-width: 0;
}

.brand-logo {
  display: block;

  width: 116px;
  height: 116px;

  object-fit: contain;
  mix-blend-mode: multiply;
}

.brand-divider {
  width: 1px;
  height: 76px;

  background:
    linear-gradient(
      to bottom,
      transparent,
      rgba(21, 152, 229, 0.75),
      transparent
    );
}

.brand-name {
  color: var(--navy);

  font-family:
    Georgia,
    "Times New Roman",
    serif;

  font-size: clamp(2.9rem, 4.2vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.045em;
}


/* =========================================================
   DİL SEÇİCİ
   ========================================================= */

.language-area {
  grid-column: 3;
  justify-self: end;

  display: flex;
  align-items: center;
  gap: 10px;
}

.language-label {
  color: var(--text-soft);
  font-size: 0.9rem;
  font-weight: 600;
}

.language-select-wrapper {
  position: relative;
}

.language-select {
  min-width: 135px;
  height: 46px;

  padding: 0 42px 0 17px;

  border: 1px solid var(--border);
  border-radius: 999px;

  color: var(--navy);
  background:
    rgba(255, 255, 255, 0.88);

  box-shadow:
    0 7px 22px rgba(43, 102, 147, 0.08);

  font-size: 0.95rem;
  font-weight: 650;

  cursor: pointer;
  appearance: none;

  transition:
    border-color var(--transition),
    box-shadow var(--transition),
    background-color var(--transition);
}

.language-select:hover {
  border-color: rgba(21, 152, 229, 0.64);
  background: #ffffff;
}

.language-select:focus {
  border-color: var(--uyghur-blue);
  box-shadow:
    0 0 0 4px rgba(21, 152, 229, 0.13);
}

.language-select-wrapper::after {
  content: "";
  position: absolute;

  top: 50%;
  right: 17px;

  width: 8px;
  height: 8px;

  border-right: 2px solid var(--uyghur-blue);
  border-bottom: 2px solid var(--uyghur-blue);

  transform:
    translateY(-70%)
    rotate(45deg);

  pointer-events: none;
}


/* =========================================================
   ANA SAYFA
   ========================================================= */

.home-main {
  padding:
    clamp(25px, 5vh, 70px)
    0
    170px;
}

.hero {
  width: 100%;
  text-align: center;
}

.hero-title {
  max-width: 1320px;
  margin: 0 auto;

  color: var(--navy);

  font-family:
    Georgia,
    "Times New Roman",
    serif;

  font-size: clamp(2.6rem, 4.4vw, 5rem);
  font-weight: 700;
  line-height: 1.13;
  letter-spacing: -0.035em;

  text-wrap: balance;
}

html[lang="ug"] .hero-title {
  color: var(--uyghur-blue);

  font-family:
    "Noto Naskh Arabic",
    "Noto Sans Arabic",
    "Segoe UI",
    Arial,
    sans-serif;

  font-size: clamp(2.5rem, 4.3vw, 4.8rem);
  line-height: 1.55;
  letter-spacing: 0;
}


/* =========================================================
   ANA SAYFA YÖNLENDİRME KARTI
   ========================================================= */

.primary-navigation-card {
  width: min(920px, 100%);
  min-height: 150px;

  margin:
    clamp(48px, 6.5vh, 84px)
    auto
    0;

  padding: 25px 32px;

  display: grid;
  grid-template-columns: 84px 1fr 36px;
  align-items: center;
  gap: 25px;

  border: 1px solid var(--border);
  border-radius: 25px;

  background:
    linear-gradient(
      140deg,
      rgba(255, 255, 255, 0.96),
      rgba(247, 252, 255, 0.9)
    );

  box-shadow: var(--shadow);

  text-align: left;

  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.primary-navigation-card:hover {
  transform: translateY(-4px);
  border-color: rgba(21, 152, 229, 0.64);

  box-shadow:
    0 26px 64px rgba(24, 87, 137, 0.18),
    0 7px 22px rgba(24, 87, 137, 0.1);
}

.navigation-icon {
  width: 78px;
  height: 78px;

  display: grid;
  place-items: center;

  border-radius: 50%;

  color: var(--uyghur-blue);
  background:
    linear-gradient(
      145deg,
      rgba(21, 152, 229, 0.15),
      rgba(21, 152, 229, 0.05)
    );
}

.navigation-icon svg {
  width: 43px;
  height: 43px;
}

.navigation-copy {
  min-width: 0;
}

.navigation-title {
  margin: 0;

  color: var(--navy);

  font-size: clamp(1.15rem, 1.7vw, 1.55rem);
  font-weight: 750;
  line-height: 1.35;
}

html[lang="ug"] .navigation-title {
  color: var(--uyghur-blue);
  font-size: clamp(1.25rem, 1.9vw, 1.7rem);
  line-height: 1.8;
}

.navigation-arrow {
  color: var(--uyghur-blue);
  transition: transform var(--transition);
}

.navigation-arrow svg {
  display: block;
  width: 34px;
  height: 34px;
}

.primary-navigation-card:hover .navigation-arrow {
  transform: translateX(5px);
}


/* =========================================================
   UYGULAMALAR SAYFASI
   ========================================================= */

.apps-main {
  padding: 30px 0 160px;
}

.page-introduction {
  margin: 0 auto 42px;
  text-align: center;
}

.page-title {
  margin: 0;

  color: var(--navy);

  font-family:
    Georgia,
    "Times New Roman",
    serif;

  font-size: clamp(3rem, 5vw, 5.2rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

html[lang="ug"] .page-title {
  color: var(--uyghur-blue);

  font-family:
    "Noto Naskh Arabic",
    "Noto Sans Arabic",
    "Segoe UI",
    Arial,
    sans-serif;

  line-height: 1.5;
  letter-spacing: 0;
}

.page-description {
  max-width: 850px;
  margin: 23px auto 0;

  color: var(--navy-soft);

  font-size: clamp(1rem, 1.6vw, 1.25rem);
  line-height: 1.7;
}

html[lang="ug"] .page-description {
  color: var(--uyghur-blue-dark);
  font-size: clamp(1.1rem, 1.8vw, 1.4rem);
  line-height: 1.9;
}


/* =========================================================
   UYGULAMA KARTLARI
   ========================================================= */

.apps-grid {
  width: min(660px, 100%);
  margin: 0 auto;

  display: grid;
  gap: 24px;
}

.app-card {
  padding: 25px;

  border: 1px solid var(--border);
  border-radius: 25px;

  background:
    rgba(255, 255, 255, 0.9);

  box-shadow: var(--shadow);
}

.app-card-header {
  display: grid;
  grid-template-columns: 106px 1fr;
  align-items: center;
  gap: 25px;
}

.app-icon {
  width: 106px;
  height: 106px;

  display: grid;
  place-items: center;

  border: 1px solid var(--border-soft);
  border-radius: 25px;

  color: var(--uyghur-blue);

  background:
    linear-gradient(
      145deg,
      rgba(21, 152, 229, 0.16),
      rgba(21, 152, 229, 0.04)
    );
}

.app-icon svg {
  width: 66px;
  height: 66px;
}

.app-information {
  min-width: 0;
}

.app-name {
  margin: 0;

  color: var(--navy);

  font-size: clamp(1.55rem, 2.3vw, 2rem);
  font-weight: 760;
}

html[lang="ug"] .app-name {
  color: var(--uyghur-blue);
  line-height: 1.7;
}

.app-summary {
  margin: 12px 0 0;

  color: var(--text-soft);

  font-size: 1rem;
  line-height: 1.6;
}

html[lang="ug"] .app-summary {
  color: var(--uyghur-blue-dark);
  line-height: 1.9;
}

.app-card-divider {
  height: 1px;
  margin: 23px 0 18px;

  background:
    linear-gradient(
      to right,
      transparent,
      var(--border),
      transparent
    );
}

.app-open-button {
  min-height: 68px;
  width: 100%;

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

  padding: 15px 25px;

  border-radius: 18px;

  color: #ffffff;
  background:
    linear-gradient(
      135deg,
      var(--uyghur-blue),
      #0677df
    );

  box-shadow:
    0 13px 28px rgba(8, 119, 199, 0.24);

  font-size: 1.12rem;
  font-weight: 740;

  transition:
    transform var(--transition),
    box-shadow var(--transition),
    filter var(--transition);
}

.app-open-button:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);

  box-shadow:
    0 17px 34px rgba(8, 119, 199, 0.31);
}


/* =========================================================
   ALT SÜS AYIRICI
   ========================================================= */

.ornament-divider {
  width: min(310px, 70%);
  margin: 65px auto 0;

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

  color: var(--uyghur-blue);
}

.ornament-divider::before,
.ornament-divider::after {
  content: "";
  flex: 1;
  height: 1px;

  background:
    linear-gradient(
      to right,
      transparent,
      rgba(21, 152, 229, 0.72)
    );
}

.ornament-divider::after {
  background:
    linear-gradient(
      to left,
      transparent,
      rgba(21, 152, 229, 0.72)
    );
}

.ornament-symbol {
  width: 35px;
  height: 35px;

  display: grid;
  place-items: center;

  font-size: 1.55rem;
}


/* =========================================================
   DİL YÖNÜ
   ========================================================= */

html[dir="rtl"] body {
  direction: rtl;
}

html[dir="rtl"] .primary-navigation-card {
  grid-template-columns: 36px 1fr 84px;
  text-align: right;
}

html[dir="rtl"] .navigation-icon {
  grid-column: 3;
}

html[dir="rtl"] .navigation-copy {
  grid-column: 2;
  grid-row: 1;
}

html[dir="rtl"] .navigation-arrow {
  grid-column: 1;
  grid-row: 1;
  transform: rotate(180deg);
}

html[dir="rtl"]
.primary-navigation-card:hover
.navigation-arrow {
  transform:
    rotate(180deg)
    translateX(5px);
}

html[dir="rtl"] .language-select {
  padding:
    0
    17px
    0
    42px;
}

html[dir="rtl"] .language-select-wrapper::after {
  right: auto;
  left: 17px;
}


/* =========================================================
   YARDIMCI SINIFLAR
   ========================================================= */

.visually-hidden {
  position: absolute !important;

  width: 1px !important;
  height: 1px !important;

  padding: 0 !important;
  margin: -1px !important;

  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;

  white-space: nowrap !important;
  border: 0 !important;
}


/* =========================================================
   TABLET
   ========================================================= */

@media (max-width: 900px) {
  .site-shell {
    padding: 0 25px;
  }

  .site-header {
    min-height: auto;
    padding: 22px 0 35px;

    grid-template-columns: 1fr auto;
    gap: 20px;
  }

  .brand {
    grid-column: 1;
    justify-self: start;
    gap: 16px;
  }

  .brand-logo {
    width: 78px;
    height: 78px;
  }

  .brand-divider {
    height: 52px;
  }

  .brand-name {
    font-size: 2.65rem;
  }

  .language-area {
    grid-column: 2;
  }

  .language-label {
    display: none;
  }

  .primary-navigation-card {
    grid-template-columns: 70px 1fr 30px;
    min-height: 130px;
    padding: 22px;
    gap: 18px;
  }

  .navigation-icon {
    width: 66px;
    height: 66px;
  }

  .navigation-icon svg {
    width: 36px;
    height: 36px;
  }
}


/* =========================================================
   TELEFON
   ========================================================= */

@media (max-width: 600px) {
  .site-shell {
    padding: 0 17px;
  }

  .site-header {
    padding-top: 15px;
    align-items: center;
  }

  .brand {
    gap: 10px;
  }

  .brand-logo {
    width: 58px;
    height: 58px;
  }

  .brand-divider {
    height: 40px;
  }

  .brand-name {
    font-size: 1.85rem;
  }

  .language-select {
    min-width: 108px;
    height: 41px;
    padding-left: 13px;
    font-size: 0.82rem;
  }

  .home-main {
    padding-top: 55px;
  }

  .hero-title {
    font-size: clamp(2rem, 10.5vw, 3.2rem);
    line-height: 1.2;
  }

  html[lang="ug"] .hero-title {
    font-size: clamp(2rem, 9vw, 3rem);
    line-height: 1.7;
  }

  .primary-navigation-card {
    min-height: 0;

    margin-top: 48px;
    padding: 21px 18px;

    grid-template-columns: 58px 1fr;
    gap: 16px;

    border-radius: 21px;
  }

  .navigation-icon {
    width: 58px;
    height: 58px;
  }

  .navigation-icon svg {
    width: 31px;
    height: 31px;
  }

  .navigation-arrow {
    display: none;
  }

  .navigation-title {
    font-size: 1.04rem;
  }

  html[dir="rtl"] .primary-navigation-card {
    grid-template-columns: 1fr 58px;
  }

  html[dir="rtl"] .navigation-icon {
    grid-column: 2;
  }

  html[dir="rtl"] .navigation-copy {
    grid-column: 1;
  }

  .apps-main {
    padding-top: 35px;
  }

  .page-title {
    font-size: clamp(2.7rem, 14vw, 4rem);
  }

  .app-card {
    padding: 19px;
    border-radius: 21px;
  }

  .app-card-header {
    grid-template-columns: 78px 1fr;
    gap: 17px;
  }

  .app-icon {
    width: 78px;
    height: 78px;
    border-radius: 19px;
  }

  .app-icon svg {
    width: 49px;
    height: 49px;
  }

  .app-name {
    font-size: 1.45rem;
  }

  .app-summary {
    font-size: 0.92rem;
  }

  .app-open-button {
    min-height: 60px;
  }
}

/* =========================================================
   ÜÇLÜ UYGULAMA KARTI DÜZENİ
   ========================================================= */

.apps-grid.apps-grid-three {
  width: min(1180px, 100%);
  grid-template-columns: repeat(3, minmax(0, 1fr));
  align-items: stretch;
}

.apps-grid-three .app-card {
  min-width: 0;

  display: flex;
  flex-direction: column;

  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition);
}

.apps-grid-three .app-card:hover {
  transform: translateY(-4px);
  border-color: rgba(21, 152, 229, 0.58);

  box-shadow:
    0 26px 62px rgba(24, 87, 137, 0.17),
    0 7px 20px rgba(24, 87, 137, 0.09);
}

.apps-grid-three .app-card-header {
  grid-template-columns: 82px minmax(0, 1fr);
  align-items: start;
  gap: 18px;
}

.apps-grid-three .app-icon {
  width: 82px;
  height: 82px;
  border-radius: 21px;
}

.apps-grid-three .app-icon svg {
  width: 50px;
  height: 50px;
}

.apps-grid-three .app-information {
  align-self: center;
}

.apps-grid-three .app-name {
  font-size: clamp(1.35rem, 1.8vw, 1.7rem);
}

.apps-grid-three .app-summary {
  flex-grow: 1;
  margin-top: 22px;
}

.app-card-content {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}

.app-status {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  width: fit-content;
  min-height: 31px;
  margin-top: 12px;
  padding: 5px 12px;

  border: 1px solid rgba(21, 152, 229, 0.22);
  border-radius: 999px;

  color: var(--uyghur-blue-dark);
  background: rgba(21, 152, 229, 0.08);

  font-size: 0.78rem;
  font-weight: 700;
}

.app-status.is-available {
  color: #087649;
  border-color: rgba(8, 118, 73, 0.2);
  background: rgba(8, 118, 73, 0.08);
}

.app-card-actions {
  margin-top: auto;
}

.app-open-button.is-disabled {
  border: 1px solid rgba(74, 102, 128, 0.13);

  color: #71869a;
  background: #eaf1f6;

  box-shadow: none;
  cursor: not-allowed;
}

.app-open-button.is-disabled:hover {
  transform: none;
  filter: none;
  box-shadow: none;
}

.app-card.is-coming-soon {
  background:
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.85),
      rgba(244, 249, 252, 0.82)
    );
}

@media (max-width: 1050px) {
  .apps-grid.apps-grid-three {
    width: min(780px, 100%);
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .apps-grid.apps-grid-three {
    width: min(480px, 100%);
    grid-template-columns: 1fr;
  }

  .apps-grid-three .app-card-header {
    grid-template-columns: 76px minmax(0, 1fr);
  }

  .apps-grid-three .app-icon {
    width: 76px;
    height: 76px;
  }
}


/* =========================================================
   GİRİŞ VE KAYIT SAYFALARI
   ========================================================= */

.auth-main {
  width: min(520px, 100%);
  margin: 0 auto;
  padding: 35px 0 150px;
}

.auth-card {
  padding: clamp(25px, 5vw, 42px);

  border: 1px solid var(--border);
  border-radius: 28px;

  background:
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.97),
      rgba(244, 250, 255, 0.92)
    );

  box-shadow: var(--shadow);
}

.auth-heading {
  margin: 0;

  color: var(--navy);

  font-family:
    Georgia,
    "Times New Roman",
    serif;

  font-size: clamp(2.3rem, 6vw, 3.5rem);
  line-height: 1.15;
  text-align: center;
}

html[lang="ug"] .auth-heading {
  color: var(--uyghur-blue);

  font-family:
    "Noto Naskh Arabic",
    "Noto Sans Arabic",
    Arial,
    sans-serif;

  line-height: 1.6;
}

.auth-description {
  margin: 14px 0 30px;

  color: var(--text-soft);

  line-height: 1.65;
  text-align: center;
}

html[lang="ug"] .auth-description {
  color: var(--uyghur-blue-dark);
  line-height: 1.9;
}

.auth-form {
  display: grid;
  gap: 20px;
}

.auth-field {
  display: grid;
  gap: 8px;
}

.auth-label {
  color: var(--navy);
  font-size: 0.94rem;
  font-weight: 700;
}

.auth-input {
  width: 100%;
  min-height: 54px;

  padding: 0 17px;

  border: 1px solid var(--border);
  border-radius: 15px;

  color: var(--navy);
  background: rgba(255, 255, 255, 0.92);

  transition:
    border-color var(--transition),
    box-shadow var(--transition),
    background-color var(--transition);
}

.auth-input:hover {
  border-color: rgba(21, 152, 229, 0.58);
}

.auth-input:focus {
  outline: none;
  border-color: var(--uyghur-blue);

  background: #ffffff;

  box-shadow:
    0 0 0 4px rgba(21, 152, 229, 0.12);
}

.auth-submit {
  min-height: 58px;
  margin-top: 4px;

  border: 0;
  border-radius: 17px;

  color: #ffffff;
  background:
    linear-gradient(
      135deg,
      var(--uyghur-blue),
      var(--uyghur-blue-dark)
    );

  box-shadow:
    0 14px 29px rgba(8, 119, 199, 0.24);

  font-size: 1.05rem;
  font-weight: 750;

  cursor: pointer;

  transition:
    transform var(--transition),
    filter var(--transition),
    box-shadow var(--transition);
}

.auth-submit:hover {
  transform: translateY(-2px);
  filter: brightness(1.04);

  box-shadow:
    0 18px 35px rgba(8, 119, 199, 0.3);
}

.auth-submit:disabled {
  opacity: 0.65;
  cursor: wait;
  transform: none;
}

.auth-message {
  min-height: 25px;
  margin: 2px 0 0;

  color: var(--text-soft);
  text-align: center;
  line-height: 1.5;
}

.auth-message.is-error {
  color: #b42318;
}

.auth-message.is-success {
  color: #087649;
}

.auth-secondary {
  margin: 27px 0 0;
  padding-top: 24px;

  border-top: 1px solid var(--border-soft);

  color: var(--text-soft);
  text-align: center;
}

.auth-secondary-link {
  color: var(--uyghur-blue-dark);
  font-weight: 750;
}

.auth-secondary-link:hover {
  text-decoration: underline;
}


.auth-field-help {
  display: block;

  margin-top: 1px;

  color: var(--text-soft);

  font-size: 0.82rem;
  line-height: 1.45;
}

html[lang="ug"] .auth-field-help {
  color: var(--uyghur-blue-dark);
  line-height: 1.8;
}


/* =========================================================
   ÜST MENÜ HESAP ALANI
   ========================================================= */

.site-header {
  position: relative;
}

.header-actions {
  position: absolute;
  top: 50%;
  right: 0;

  display: flex;
  align-items: center;
  gap: 13px;

  transform: translateY(-50%);
}

html[dir="rtl"] .header-actions {
  right: auto;
  left: 0;
}

.header-actions .language-area {
  grid-column: auto;
  justify-self: auto;
}


/* Hesap menüsü dış kabuğu */

.account-menu {
  position: relative;
}


/* Hesap menüsünü açan buton */

.account-trigger {
  min-height: 52px;
  max-width: 245px;

  padding: 6px 13px 6px 7px;

  display: flex;
  align-items: center;
  gap: 10px;

  border: 1px solid var(--border);
  border-radius: 999px;

  color: var(--navy);
  background: rgba(255, 255, 255, 0.9);

  box-shadow:
    0 7px 22px rgba(43, 102, 147, 0.09);

  cursor: pointer;

  transition:
    transform var(--transition),
    border-color var(--transition),
    box-shadow var(--transition),
    background-color var(--transition);
}

.account-trigger:hover {
  border-color: rgba(21, 152, 229, 0.65);
  background: #ffffff;
}

.account-trigger.is-open {
  transform: scale(1.035);

  border-color: var(--uyghur-blue);

  box-shadow:
    0 12px 30px rgba(24, 87, 137, 0.16),
    0 0 0 4px rgba(21, 152, 229, 0.09);
}


/* Küçük profil simgesi */

.account-avatar {
  flex: 0 0 auto;

  width: 39px;
  height: 39px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(21, 152, 229, 0.2);
  border-radius: 50%;

  color: var(--uyghur-blue);

  background:
    linear-gradient(
      145deg,
      rgba(21, 152, 229, 0.16),
      rgba(21, 152, 229, 0.05)
    );
}

.account-avatar svg {
  width: 27px;
  height: 27px;
}


/* Kullanıcı adı */

.account-trigger-copy {
  min-width: 0;

  display: grid;
  gap: 1px;

  text-align: left;
}

html[dir="rtl"] .account-trigger-copy {
  text-align: right;
}

.account-trigger-label {
  color: var(--text-soft);

  font-size: 0.69rem;
  font-weight: 650;
  line-height: 1.2;
}

.account-trigger-name {
  max-width: 125px;

  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

  color: var(--navy);

  font-size: 0.9rem;
  line-height: 1.25;
}


/* Aşağı oku */

.account-chevron {
  flex: 0 0 auto;

  width: 17px;
  height: 17px;

  color: var(--uyghur-blue);

  transition: transform var(--transition);
}

.account-trigger.is-open .account-chevron {
  transform: rotate(180deg);
}


/* Açılır pencere */

.account-popover {
  position: absolute;
  top: calc(100% + 13px);
  right: 0;
  z-index: 50;

  width: min(320px, calc(100vw - 34px));

  padding: 17px;

  border: 1px solid var(--border);
  border-radius: 21px;

  background:
    rgba(255, 255, 255, 0.98);

  box-shadow:
    0 25px 65px rgba(24, 67, 109, 0.2),
    0 7px 20px rgba(24, 67, 109, 0.1);

  transform-origin: top right;

  animation:
    accountPopoverOpen
    150ms
    ease-out;
}

html[dir="rtl"] .account-popover {
  right: auto;
  left: 0;

  transform-origin: top left;
}

.account-popover[hidden] {
  display: none;
}

@keyframes accountPopoverOpen {
  from {
    opacity: 0;
    transform:
      translateY(-7px)
      scale(0.96);
  }

  to {
    opacity: 1;
    transform:
      translateY(0)
      scale(1);
  }
}


/* Açılır penceredeki kullanıcı bilgisi */

.account-popover-profile {
  display: grid;
  grid-template-columns: 55px minmax(0, 1fr);
  align-items: center;
  gap: 13px;
}

html[dir="rtl"] .account-popover-profile {
  grid-template-columns: minmax(0, 1fr) 55px;
}

html[dir="rtl"] .account-popover-avatar {
  grid-column: 2;
}

html[dir="rtl"] .account-popover-copy {
  grid-column: 1;
  grid-row: 1;
  text-align: right;
}

.account-popover-avatar {
  width: 55px;
  height: 55px;

  display: grid;
  place-items: center;

  border: 1px solid rgba(21, 152, 229, 0.24);
  border-radius: 50%;

  color: var(--uyghur-blue);

  background:
    linear-gradient(
      145deg,
      rgba(21, 152, 229, 0.18),
      rgba(21, 152, 229, 0.05)
    );
}

.account-popover-avatar svg {
  width: 37px;
  height: 37px;
}

.account-popover-copy {
  min-width: 0;

  display: grid;
  gap: 4px;
}

.account-popover-name {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

  color: var(--navy);

  font-size: 1rem;
}

.account-popover-email {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;

  color: var(--text-soft);

  font-size: 0.8rem;
}

.account-popover-divider {
  height: 1px;
  margin: 15px 0;

  background:
    linear-gradient(
      to right,
      transparent,
      var(--border),
      transparent
    );
}


/* Çıkış butonu */

.account-logout-button {
  width: 100%;
  min-height: 47px;

  padding: 10px 13px;

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

  border: 1px solid rgba(180, 35, 24, 0.16);
  border-radius: 14px;

  color: #b42318;
  background: rgba(180, 35, 24, 0.055);

  font-weight: 730;

  cursor: pointer;

  transition:
    background-color var(--transition),
    border-color var(--transition),
    transform var(--transition);
}

.account-logout-button:hover {
  transform: translateY(-1px);

  border-color: rgba(180, 35, 24, 0.3);
  background: rgba(180, 35, 24, 0.1);
}

.account-logout-button:disabled {
  opacity: 0.6;
  cursor: wait;
  transform: none;
}

.account-logout-button svg {
  width: 21px;
  height: 21px;
}

.account-message {
  min-height: 0;
  margin: 10px 0 0;

  color: #b42318;

  font-size: 0.78rem;
  text-align: center;
}


/* =========================================================
   HESAP MENÜSÜ — TABLET VE TELEFON
   ========================================================= */

@media (max-width: 1100px) {
  .header-actions {
    gap: 8px;
  }

  .account-trigger-label {
    display: none;
  }

  .account-trigger-name {
    max-width: 92px;
  }
}

@media (max-width: 900px) {
  .site-header {
    display: grid;
    grid-template-columns: 1fr auto;
  }

  .header-actions {
    position: static;

    grid-column: 2;
    justify-self: end;

    transform: none;
  }

  html[dir="rtl"] .site-header {
    grid-template-columns: auto 1fr;
  }

  html[dir="rtl"] .brand {
    grid-column: 2;
    justify-self: end;
  }

  html[dir="rtl"] .header-actions {
    grid-column: 1;
    justify-self: start;
  }
}

@media (max-width: 690px) {
  .header-actions {
    gap: 6px;
  }

  .header-actions .language-select {
    min-width: 93px;
  }

  .account-trigger {
    width: 47px;
    min-height: 47px;
    padding: 4px;

    justify-content: center;
  }

  .account-avatar {
    width: 37px;
    height: 37px;
  }

  .account-trigger-copy,
  .account-chevron {
    display: none;
  }

  .account-popover {
    width: min(295px, calc(100vw - 25px));
  }
}


/* Mavi ve yoğun arka plan üzerinde kartların okunabilirliği */

.primary-navigation-card,
.app-card,
.auth-card,
.account-popover {
  background:
    linear-gradient(
      145deg,
      rgba(255, 255, 255, 0.95),
      rgba(241, 249, 255, 0.91)
    );

  backdrop-filter: blur(7px);
  -webkit-backdrop-filter: blur(7px);
}

.site-header {
  position: relative;
  z-index: 10;
}

.home-main,
.apps-main,
.auth-main {
  position: relative;
  z-index: 1;
}




/* =========================================================
   YÖNETİM PANELİ
   ========================================================= */

.admin-main {
  padding: 25px 0 150px;
}

.admin-panel {
  width: min(1180px, 100%);
  margin: 0 auto;
  padding: clamp(22px, 4vw, 38px);

  border: 1px solid var(--border);
  border-radius: 28px;

  background: rgba(255, 255, 255, 0.94);
  box-shadow: var(--shadow);

  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
}

.admin-panel-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 25px;

  margin-bottom: 28px;
}

.admin-title {
  margin: 0;

  color: var(--navy);

  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(2.3rem, 4vw, 3.7rem);
}

.admin-description {
  max-width: 700px;
  margin: 12px 0 0;

  color: var(--text-soft);
  line-height: 1.65;
}

.admin-identity {
  display: grid;
  gap: 4px;

  min-width: 180px;
  padding: 13px 17px;

  border: 1px solid var(--border);
  border-radius: 16px;

  background: rgba(21, 152, 229, 0.07);
}

.admin-identity span {
  color: var(--text-soft);
  font-size: 0.77rem;
}

.admin-identity strong {
  color: var(--navy);
}

.admin-flash-message {
  margin-bottom: 22px;
  padding: 14px 17px;

  border: 1px solid rgba(8, 118, 73, 0.22);
  border-radius: 15px;

  color: #087649;
  background: rgba(8, 118, 73, 0.08);

  font-weight: 650;
}

.admin-table-wrapper {
  overflow-x: auto;

  border: 1px solid var(--border-soft);
  border-radius: 19px;
}

.admin-table {
  width: 100%;
  min-width: 800px;

  border-collapse: collapse;
  background: rgba(255, 255, 255, 0.7);
}

.admin-table th,
.admin-table td {
  padding: 15px 17px;

  border-bottom: 1px solid var(--border-soft);

  text-align: left;
  vertical-align: middle;
}

html[dir="rtl"] .admin-table th,
html[dir="rtl"] .admin-table td {
  text-align: right;
}

.admin-table th {
  color: var(--navy);
  background: rgba(21, 152, 229, 0.08);

  font-size: 0.82rem;
  font-weight: 750;
}

.admin-table tbody tr:last-child td {
  border-bottom: 0;
}

.admin-table tbody tr:hover {
  background: rgba(21, 152, 229, 0.035);
}

.admin-user-cell {
  display: grid;
  gap: 4px;
}

.admin-user-cell strong {
  color: var(--navy);
}

.admin-user-cell span {
  color: var(--text-soft);
  font-size: 0.8rem;
}

.admin-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;

  min-height: 30px;
  padding: 5px 11px;

  border: 1px solid var(--border-soft);
  border-radius: 999px;

  color: var(--text-soft);
  background: rgba(74, 102, 128, 0.07);

  font-size: 0.77rem;
  font-weight: 700;
}

.admin-badge.is-admin {
  color: #764b00;
  border-color: rgba(179, 117, 0, 0.2);
  background: rgba(255, 183, 38, 0.12);
}

.admin-badge.is-active {
  color: #087649;
  border-color: rgba(8, 118, 73, 0.2);
  background: rgba(8, 118, 73, 0.08);
}

.admin-badge.is-locked {
  color: #b42318;
  border-color: rgba(180, 35, 24, 0.17);
  background: rgba(180, 35, 24, 0.06);
}

.admin-action-form {
  margin: 0;
}

.admin-action-button {
  min-height: 41px;
  padding: 8px 14px;

  border-radius: 12px;

  font-weight: 700;
  cursor: pointer;

  transition:
    transform var(--transition),
    background-color var(--transition);
}

.admin-action-button:hover {
  transform: translateY(-1px);
}

.admin-action-button.is-grant {
  border: 1px solid rgba(8, 118, 73, 0.25);

  color: #087649;
  background: rgba(8, 118, 73, 0.09);
}

.admin-action-button.is-revoke {
  border: 1px solid rgba(180, 35, 24, 0.22);

  color: #b42318;
  background: rgba(180, 35, 24, 0.07);
}

.admin-back-link {
  min-height: 44px;
  padding: 0 15px;

  display: inline-flex;
  align-items: center;

  border: 1px solid var(--border);
  border-radius: 999px;

  color: var(--navy);
  background: rgba(255, 255, 255, 0.88);

  font-size: 0.86rem;
  font-weight: 700;
}

@media (max-width: 760px) {
  .admin-panel-heading {
    flex-direction: column;
  }

  .admin-identity {
    width: 100%;
  }

  .admin-back-link {
    display: none;
  }
}




/* Dört uygulamalı ekran */

.apps-grid.apps-grid-three {
  width: min(1280px, 100%);
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

@media (max-width: 1250px) {
  .apps-grid.apps-grid-three {
    width: min(900px, 100%);
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 700px) {
  .apps-grid.apps-grid-three {
    width: min(480px, 100%);
    grid-template-columns: 1fr;
  }
}


.gallery-reauth-form {
  margin-top: 27px;
}

.gallery-reauth-form .auth-message {
  margin-bottom: 0;
}





.gallery-security-note {
  margin: 20px 0;
  padding: 13px 15px;

  border: 1px solid rgba(21, 152, 229, 0.2);
  border-radius: 14px;

  color: var(--navy);
  background: rgba(21, 152, 229, 0.07);

  font-size: 0.86rem;
  line-height: 1.55;
}

.gallery-unlock-result {
  display: flex;
  align-items: baseline;
  justify-content: center;
  gap: 9px;

  margin: 25px 0;
  padding: 22px;

  border: 1px solid rgba(8, 118, 73, 0.2);
  border-radius: 18px;

  color: #087649;
  background: rgba(8, 118, 73, 0.08);
}

.gallery-unlock-result strong {
  font-size: 2.4rem;
}

.gallery-unlock-result span {
  font-weight: 700;
}




/* =========================================================
   ŞİFRELİ GALERİ FOTOĞRAF GÖRÜNÜMÜ
   ========================================================= */

.auth-card.is-gallery-expanded {
  width: min(1180px, 100%);
  max-width: 1180px;
}

.gallery-view {
  width: 100%;
}

.gallery-view-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 24px;

  margin-bottom: 20px;
}

.gallery-lock-button {
  min-height: 44px;
  padding: 9px 16px;

  border: 1px solid rgba(180, 35, 24, 0.22);
  border-radius: 13px;

  color: #b42318;
  background: rgba(180, 35, 24, 0.07);

  font-weight: 700;
  cursor: pointer;
}

.gallery-lock-button:hover {
  background: rgba(180, 35, 24, 0.12);
}

.gallery-photo-grid {
  display: grid;
  grid-template-columns:
    repeat(auto-fill, minmax(210px, 1fr));
  gap: 18px;

  margin-top: 28px;
}

.gallery-photo-card {
  overflow: hidden;
  margin: 0;

  border: 1px solid var(--border-soft);
  border-radius: 18px;

  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 28px rgba(10, 45, 70, 0.09);
}

.gallery-photo-image,
.gallery-photo-loading,
.gallery-photo-error {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 3;
}

.gallery-photo-image {
  object-fit: cover;
  background: rgba(20, 55, 80, 0.06);
}

.gallery-photo-loading,
.gallery-photo-error {
  display: flex;
  align-items: center;
  justify-content: center;

  padding: 20px;

  text-align: center;
  font-size: 0.85rem;
  font-weight: 700;
}

.gallery-photo-loading {
  color: var(--text-soft);
  background:
    linear-gradient(
      110deg,
      rgba(21, 152, 229, 0.05) 8%,
      rgba(21, 152, 229, 0.13) 18%,
      rgba(21, 152, 229, 0.05) 33%
    );

  background-size: 200% 100%;
  animation: gallery-loading 1.4s linear infinite;
}

.gallery-photo-error {
  color: #b42318;
  background: rgba(180, 35, 24, 0.06);
}

.gallery-photo-caption {
  overflow: hidden;

  padding: 12px 14px;

  color: var(--navy);

  font-size: 0.78rem;
  font-weight: 650;

  white-space: nowrap;
  text-overflow: ellipsis;
}

@keyframes gallery-loading {
  to {
    background-position-x: -200%;
  }
}

@media (max-width: 700px) {
  .gallery-view-header {
    flex-direction: column;
  }

  .gallery-lock-button {
    width: 100%;
  }

  .gallery-photo-grid {
    grid-template-columns:
      repeat(2, minmax(0, 1fr));

    gap: 10px;
  }

  .gallery-photo-caption {
    padding: 10px;
    font-size: 0.7rem;
  }
}

@media (max-width: 430px) {
  .gallery-photo-grid {
    grid-template-columns: 1fr;
  }
}



/* =========================================================
   GALERİ FOTOĞRAF PENCERESİ
   ========================================================= */

.gallery-photo-open {
  display: block;
  width: 100%;
  padding: 0;

  border: 0;
  background: transparent;

  cursor: zoom-in;
}

.gallery-photo-open:focus-visible {
  outline: 3px solid rgba(21, 152, 229, 0.65);
  outline-offset: -3px;
}

.gallery-photo-open .gallery-photo-image {
  transition: transform 180ms ease;
}

.gallery-photo-open:hover .gallery-photo-image {
  transform: scale(1.025);
}

/*
 * Artık bütün sayfayı kaplayan siyah bir katman değil,
 * ekranın ortasında duran bağımsız fotoğraf penceresi.
 */
.gallery-lightbox {
  position: fixed;
  z-index: 99999;

  top: 50%;
  left: 50%;

  width: min(94vw, 1200px);
  max-height: 92vh;

  padding: 14px;

  transform: translate(-50%, -50%);

  border: 1px solid rgba(255, 255, 255, 0.16);
  border-radius: 18px;

  background: rgba(7, 15, 24, 0.97);

  box-shadow:
    0 24px 90px rgba(0, 0, 0, 0.55);

  overflow: hidden;
}

.gallery-lightbox[hidden] {
  display: none;
}

.gallery-lightbox-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;

  width: 100%;
  max-height: calc(92vh - 28px);
}

.gallery-lightbox-image {
  display: block;

  width: auto;
  height: auto;

  max-width: 100%;
  max-height: calc(92vh - 72px);

  border-radius: 12px;

  object-fit: contain;
  user-select: none;

  background: transparent;
}

.gallery-lightbox-caption {
  width: calc(100% - 70px);
  margin: 10px 0 0;

  overflow: hidden;

  color: rgba(255, 255, 255, 0.88);

  text-align: center;
  text-overflow: ellipsis;
  white-space: nowrap;

  font-size: 0.86rem;
}

.gallery-lightbox-close {
  position: absolute;
  z-index: 2;

  top: 10px;
  right: 10px;

  width: 42px;
  height: 42px;

  padding: 0;

  border: 1px solid rgba(255, 255, 255, 0.28);
  border-radius: 50%;

  color: white;
  background: rgba(0, 0, 0, 0.58);

  font-size: 1.8rem;
  line-height: 1;

  cursor: pointer;
}

.gallery-lightbox-close:hover {
  background: rgba(255, 255, 255, 0.18);
}

/*
 * Overflow hidden kullanmıyoruz.
 * Böylece uzun galeri sayfası fotoğraf açılırken
 * yukarı sıçramıyor.
 */
body.is-gallery-lightbox-open {
  overscroll-behavior: none;
}

@media (max-width: 600px) {
  .gallery-lightbox {
    width: 94vw;
    max-height: 88vh;

    padding: 8px;

    border-radius: 14px;
  }

  .gallery-lightbox-content {
    max-height: calc(88vh - 16px);
  }

  .gallery-lightbox-image {
    max-height: calc(88vh - 58px);

    border-radius: 9px;
  }

  .gallery-lightbox-close {
    top: 7px;
    right: 7px;

    width: 38px;
    height: 38px;

    font-size: 1.6rem;
  }
}