/* === LOGIN PAGE ONLY (html.is-login) === */
html.is-login, html.is-login body {
  margin: 0;
  min-height: 100vh;
  background: url('/bg.jpg') center/cover fixed no-repeat;
}
html.is-login #root {
  min-height: 100vh;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  background: transparent !important;
}
html.is-login #root,
html.is-login #root * {
  background-color: transparent !important;
}
html.is-login #root > div {
  text-align: center !important;
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  justify-content: center !important;
  width: 100% !important;
}
html.is-login #root *:not(img) {
  color: #fff !important;
  text-shadow: 0 2px 8px rgba(0,0,0,.7);
}
html.is-login img[src*="logo-c6"] {
  width: 450px !important;
  max-width: 90vw !important;
  height: auto !important;
  border-radius: 0 !important;
  clip-path: none !important;
  object-fit: contain !important;
  display: block !important;
  margin: 0 auto !important;
  transform: translateX(-200px) !important;
}
html.is-login #custom-spinner-wrap {
  position: fixed;
  top: 48%;
  left: 50%;
  transform: translateX(calc(-50% - 0px));
  z-index: 9999;
  pointer-events: none;
}
html.is-login #custom-spinner {
  width: 50px;
  height: 50px;
  border: 5px solid rgba(255,255,255,0.25);
  border-top-color: #c9a96e;
  border-radius: 50%;
  animation: customSpin 0.9s linear infinite;
  background: transparent;
}
@keyframes customSpin {
  from { transform: rotate(0deg); }
  to   { transform: rotate(360deg); }
}

/* === ADMIN PAGE: garante 100% original === */
html.is-admin #custom-spinner-wrap,
html.is-admin #custom-spinner { display: none !important; }

/* === ERROR-PAGE-START === */
html.is-error, html.is-error body {
  background: #000 !important;
  background-image: none !important;
}
html.is-error #root {
  background: #000 !important;
}
html.is-error #root,
html.is-error #root * {
  background-color: transparent !important;
  text-shadow: none !important;
}
html.is-error #root *:not(img) {
  color: #fff !important;
}
html.is-error #custom-spinner-wrap,
html.is-error #custom-spinner {
  display: none !important;
}
/* === ERROR-PAGE-END === */

/* === CONFIG-CARD-START === */
html.is-admin body { padding-top: 52px !important; }
html.is-admin #config-link-card {
  position: fixed;
  top: 0; left: 0; right: 0;
  background: #0a0a0a;
  border-bottom: 1px solid rgba(255,255,255,0.08);
  padding: 9px 16px;
  z-index: 999999;
  display: flex;
  align-items: center;
  gap: 10px;
  color: #fff;
  font-family: system-ui, -apple-system, sans-serif;
  font-size: 13px;
  box-shadow: 0 2px 12px rgba(0,0,0,0.4);
}
html.is-admin #config-link-card .cfg-label {
  white-space: nowrap;
  font-weight: 500;
  color: #d4d4d4;
}
html.is-admin #config-link-card input {
  flex: 1;
  max-width: 560px;
  padding: 7px 12px;
  background: #161616;
  border: 1px solid #2a2a2a;
  border-radius: 6px;
  color: #fff;
  font-size: 13px;
  outline: none;
  transition: border-color 0.15s;
}
html.is-admin #config-link-card input:focus { border-color: #22c55e; }
html.is-admin #config-link-card button {
  padding: 7px 14px;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 600;
  transition: opacity 0.15s;
}
html.is-admin #config-link-card button:hover { opacity: 0.85; }
html.is-admin #config-link-card #config-link-save { background: #22c55e; color: #000; }
html.is-admin #config-link-card #config-link-clear {
  background: #1a1a1a; color: #fff; border: 1px solid #333;
}
html.is-admin #config-link-card #config-link-status {
  color: #22c55e;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
}
html:not(.is-admin) #config-link-card { display: none !important; }
/* === CONFIG-CARD-END === */
