/**
 * Bolçi portal — modern katman (1. parça: kabuk, login, portal, formlar).
 * Geri almak: index.html içinden bu dosyanın <link>'ini ve html.theme-modern sınıfını sil.
 * style.css değişmez.
 */
html.theme-modern {
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --shadow-soft: 0 8px 28px rgba(31, 15, 8, 0.08);
  --shadow-lift: 0 14px 36px rgba(31, 15, 8, 0.12);
  --focus-ring: 0 0 0 3px rgba(196, 92, 38, 0.22);
}

html.theme-modern,
html.theme-modern body {
  height: auto;
  min-height: 100dvh;
  overflow-x: hidden;
  overflow-y: auto;
  touch-action: pan-y;
}

html.theme-modern body {
  background:
    radial-gradient(ellipse 90% 50% at 50% -10%, #fff 0%, transparent 55%),
    linear-gradient(180deg, #f7f1ea 0%, var(--bolci-cream) 40%, #f3ece4 100%);
  padding: 24px 20px 48px;
  align-items: stretch;
}

html.theme-modern .brand-header {
  margin-bottom: 18px;
  gap: 6px;
  background: transparent;
}

html.theme-modern .brand-logo-img {
  max-height: 64px;
  filter: none;
  mix-blend-mode: multiply;
  background: transparent;
}

html.theme-modern .brand-tagline {
  letter-spacing: 0.18em;
  font-weight: 700;
  color: var(--bolci-orange-dark);
}

html.theme-modern .brand-header,
html.theme-modern .form-card {
  max-width: min(1280px, 100%);
  margin-left: auto;
  margin-right: auto;
}

html.theme-modern .form-card {
  border: 1px solid rgba(232, 223, 213, 0.9);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  overflow: visible;
  flex: none;
  display: block;
  width: 100%;
}

html.theme-modern .card-top-bar {
  padding: 22px 28px 20px;
  border-bottom: none;
  background:
    linear-gradient(180deg, rgba(197, 160, 89, 0.18) 0%, transparent 42%),
    linear-gradient(135deg, var(--bolci-brown-dark) 0%, var(--bolci-brown-main) 58%, #4a2a1c 100%);
}

html.theme-modern .card-top-bar h1 {
  font-size: 1.35rem;
  font-weight: 650;
  letter-spacing: 0.02em;
}

html.theme-modern .card-top-bar p {
  opacity: 0.92;
  font-weight: 500;
}

html.theme-modern .btn-back {
  width: 48px;
  height: 48px;
  min-width: 48px;
  min-height: 48px;
  padding: 0;
  border-radius: 14px;
  background: #fff;
  color: #2a140c;
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.22);
}

html.theme-modern .btn-page-logout {
  border-radius: 12px;
  padding: 8px 12px;
  min-height: 40px;
  font-size: 13.5px;
  font-weight: 700;
  background: #fff;
  color: var(--bolci-brown-main);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

html.theme-modern .page-heading-panel {
  background: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.16);
}

html.theme-modern .btn-back:hover,
html.theme-modern .btn-page-logout:hover {
  background: #fff;
  filter: brightness(0.97);
}

html.theme-modern .auth-bar[hidden] {
  display: none !important;
}

html.theme-modern .auth-bar:not([hidden]) {
  margin-top: 12px;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--bolci-border);
  border-radius: 999px;
  box-shadow: 0 4px 14px rgba(52, 26, 16, 0.06);
  backdrop-filter: blur(8px);
}

html.theme-modern .auth-bar-logout {
  border-radius: 999px;
  padding: 6px 14px;
  min-height: 32px;
}

html.theme-modern .card-body,
html.theme-modern .portal-home-wrap {
  padding: 32px 36px 40px;
}

html.theme-modern .portal-hello {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin: 0 0 18px;
  padding: 0 2px 12px;
  border-bottom: 1px solid #ece4db;
}

html.theme-modern .portal-hello-text {
  margin: 0;
  font-size: 15px;
  font-weight: 600;
  color: var(--bolci-brown-main);
  min-width: 0;
}

html.theme-modern .portal-hello-logout {
  flex-shrink: 0;
  appearance: none;
  background: transparent;
  border: 1px solid #d9cfc4;
  color: var(--bolci-brown-main);
  border-radius: 999px;
  padding: 6px 14px;
  min-height: 36px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
}

html.theme-modern .portal-hello-logout:hover {
  background: #f3ede6;
  border-color: #c4b5a8;
}

html.theme-modern .category-heading {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  border-bottom: none;
  color: var(--bolci-brown-light);
  margin: 8px 0 10px;
}

html.theme-modern .forms-portal-grid {
  gap: 12px;
}

html.theme-modern .form-item-card {
  border-radius: 12px;
  padding: 16px 18px;
  border: 1px solid #ece4db;
  min-height: 72px;
  box-shadow: none;
  background: #fff;
}

html.theme-modern .form-item-card:hover {
  transform: none;
  border-color: #d4c8bc;
  background: #faf6f1;
  box-shadow: none;
}

html.theme-modern .form-item-card:active {
  transform: none;
}

html.theme-modern .form-item-icon {
  width: 40px;
  height: 40px;
  font-size: 22px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 0;
  border: none;
  background: transparent;
}

html.theme-modern .form-item-icon .bi {
  font-size: 22px;
}

html.theme-modern .icon-picker-trigger {
  background: #faf6f1;
  border-color: #e6ddd4;
}

html.theme-modern .icon-picker-trigger-cta {
  border-color: #e6ddd4;
  color: #c45c26;
}

html.theme-modern .icon-pick.is-selected {
  border-color: #c45c26;
  background: #fff7f2;
}

html.theme-modern .form-item-title {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 16px;
  font-weight: 650;
  letter-spacing: -0.01em;
}

html.theme-modern .form-item-desc {
  font-size: 13px;
  color: #8a7b72;
}

html.theme-modern .form-item-go {
  background: transparent;
  color: #c4b5a8;
  width: 24px;
  height: 24px;
}

html.theme-modern .form-item-card:hover .form-item-go {
  background: transparent;
  color: var(--bolci-orange);
}

html.theme-modern .login-wrap {
  max-width: 520px;
  padding-top: 12px;
}

html.theme-modern .login-form .form-group label {
  font-size: 12px;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

html.theme-modern .input-control,
html.theme-modern .select-control,
html.theme-modern .textarea-control {
  border-radius: 12px;
  background: #fff;
  border-color: #e4d8cc;
  min-height: 52px;
  padding: 14px 16px;
  font-size: 16px;
}

html.theme-modern .input-control:focus,
html.theme-modern .select-control:focus,
html.theme-modern .textarea-control:focus {
  border-color: var(--bolci-orange);
  box-shadow: var(--focus-ring);
}

html.theme-modern .btn-submit,
html.theme-modern .btn-back-portal,
html.theme-modern .btn-tbl-detail,
html.theme-modern .btn-tbl-timeline,
html.theme-modern .btn-apply-custom-date,
html.theme-modern .btn-verify {
  border-radius: 12px;
  min-height: 52px;
  padding-left: 18px;
  padding-right: 18px;
  box-shadow: none;
}

html.theme-modern .btn-submit {
  letter-spacing: 0.02em;
  -webkit-appearance: none;
  appearance: none;
  background-color: var(--bolci-orange);
  background-image: linear-gradient(135deg, var(--bolci-orange), var(--bolci-orange-dark));
}

html.theme-modern .btn-submit:hover:not(:disabled) {
  filter: none;
  transform: none;
  background-color: var(--bolci-orange-dark);
  background-image: linear-gradient(135deg, #b4531f, #7a3210);
}

html.theme-modern .btn-submit:active:not(:disabled) {
  transform: none;
  filter: none;
  background-image: linear-gradient(135deg, var(--bolci-orange-dark), #7a3210);
}

html.theme-modern .login-remember input {
  accent-color: var(--bolci-orange);
}

html.theme-modern .section-title {
  font-family: "Plus Jakarta Sans", sans-serif;
  font-size: 0.95rem;
  font-weight: 700;
  border-bottom-color: transparent;
  letter-spacing: 0;
}

html.theme-modern .history-card,
html.theme-modern .mgmt-panel,
html.theme-modern .generated-link-card {
  border-radius: var(--radius-md);
}

html.theme-modern .copy-toast {
  border-radius: 999px;
  bottom: max(24px, env(safe-area-inset-bottom));
}

@media (min-width: 721px) {
  html.theme-modern .forms-portal-grid {
    gap: 16px;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  html.theme-modern .form-item-card:hover .form-item-go {
    background: transparent;
    color: var(--bolci-orange);
  }
}

@media (max-width: 720px) {
  html.theme-modern,
  html.theme-modern body {
    height: auto !important;
    min-height: 100dvh;
    overflow-x: hidden !important;
    overflow-y: auto !important;
    touch-action: pan-y;
  }

  html.theme-modern body {
    padding: 0;
    padding-top: env(safe-area-inset-top);
    padding-bottom: env(safe-area-inset-bottom);
    background: #f6f1eb;
    display: block;
  }

  html.theme-modern .brand-header {
    padding: 12px 16px 10px;
    background: #f6f1eb;
    border-bottom: 1px solid rgba(232, 223, 213, 0.8);
    backdrop-filter: none;
    position: sticky;
    top: 0;
    z-index: 20;
    max-width: none;
  }

  html.theme-modern .brand-logo-img {
    max-height: 52px;
  }

  html.theme-modern .auth-bar:not([hidden]) {
    width: 100%;
    border-radius: 14px;
    justify-content: space-between;
  }

  html.theme-modern .form-card {
    border-radius: 0;
    box-shadow: none;
    background: transparent;
    border: none;
    max-width: none;
    display: block;
    flex: none;
    min-height: 0;
    overflow: visible;
  }

  html.theme-modern .card-top-bar {
    border-radius: 0;
    padding: 20px 18px 18px;
  }

  html.theme-modern .card-top-bar h1 {
    font-family: "Plus Jakarta Sans", sans-serif;
    font-size: 1.35rem;
  }

  html.theme-modern .portal-home-wrap,
  html.theme-modern .card-body {
    padding: 18px 16px 40px;
  }

  html.theme-modern .portal-hello {
    margin-bottom: 14px;
    padding-bottom: 10px;
  }

  html.theme-modern .portal-hello-text {
    font-size: 14px;
  }

  html.theme-modern .form-item-card {
    min-height: 68px;
    padding: 14px 16px;
  }

  html.theme-modern .form-item-card:hover {
    transform: none;
  }

  html.theme-modern .btn-submit {
    min-height: 54px;
    font-size: 17px;
  }

  html.theme-modern .forms-portal-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
}

html.theme-modern.kvkk-modal-open,
html.theme-modern.kvkk-modal-open body,
html.theme-modern.filter-sheet-open,
html.theme-modern.filter-sheet-open body {
  overflow: hidden !important;
}

@media (prefers-reduced-motion: reduce) {
  html.theme-modern *,
  html.theme-modern *::before,
  html.theme-modern *::after {
    transition: none !important;
    animation: none !important;
  }
}
