:root {
  color-scheme: light;

  --navy: #1e3a8a;
  --ink: #0f172a;
  --slate: #334155;

  --bg: #f6f8ff;
  --white: #fff;

  --red: #dc2626;
  --blue: #2563eb;
  --green: #16a34a;
  --teal: #14b8a6;

  --card-b: #e5e7eb;
}

* { box-sizing: border-box; }

html, body { height: 100%; }

body {
  margin: 0;
  padding: 28px;

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

  background: var(--bg);
  color: var(--ink);
  font-family: system-ui, Segoe UI, Roboto, Ubuntu, Arial, sans-serif;
}

/* ======================================================================
   KÜLSŐ KERET / WRAPPER (opcionális)
   Ha a tartalmat nem body közepére teszed, hanem pl. egy div-be,
   add a HTML-ben erre a class-t: <div class="sat-frame"> ... </div>
   ====================================================================== */
.sat-frame {
  width: min(1100px, 96vw);
  /* ugyanaz a keret/árnyék mint a card-on, ha wrapperként használod */
  border: 2px solid var(--navy);
  border-radius: 18px;
  background: var(--white);
  box-shadow: 0 22px 60px rgba(17, 24, 39, 0.18);
  padding: 28px;
  position: relative;
  overflow: hidden;
}

/* ======================================================================
   CARD — EZ ADJA A "KÜLSŐ KERETET" AZ EREDETI KÓDBAN
   ====================================================================== */
.card {
  width: min(1100px, 96vw);
  background: var(--white);

  border: 2px solid var(--navy);     /* <-- EZ A KÜLSŐ KERET */
  border-radius: 18px;

  box-shadow: 0 22px 60px rgba(17, 24, 39, 0.18);
  padding: 28px;

  position: relative;
  overflow: hidden;
}

/* Brand header */
.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 6px;
}

.logo {
  width: 56px;
  height: 56px;
  border-radius: 14px;

  background: linear-gradient(135deg, var(--red) 0%, #ffffff 55%, var(--navy) 100%);
  box-shadow: 0 14px 32px rgba(220, 38, 38, 0.22);

  flex: 0 0 auto;
  position: relative;
}

.logo::after {
  content: "";
  position: absolute;
  inset: -16px;
  border-radius: 22px;
  background: radial-gradient(closest-side, rgba(220, 38, 38, 0.14), transparent 70%);
  pointer-events: none;
}

h1 {
  margin: 0;
  font-size: 32px;
  color: var(--navy);
  letter-spacing: 0.2px;
}

/* Subhead */
.sub {
  margin: 2px 0 16px;
  color: var(--slate);
  font-size: 14px;
}

/* Divider */
.divider {
  height: 1px;
  background: var(--card-b);
  margin: 12px 0 20px;
}

/* Hero: tech orbit */
.hero {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 22px;
  align-items: center;
}

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

/* Orbit stage */
.stage {
  position: relative;
  aspect-ratio: 1.9 / 1;
  min-height: 280px;

  background:
    radial-gradient(ellipse at 30% 20%, rgba(37, 99, 235, 0.10), transparent 40%),
    radial-gradient(circle at 75% 60%, rgba(220, 38, 38, 0.08), transparent 45%);

  border: 1px solid var(--card-b);
  border-radius: 16px;
  padding: 14px;
  overflow: hidden;
}

/* Orbit center — the brand */
.center {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);

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

  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--card-b);
  border-radius: 14px;
  padding: 10px 14px;
  backdrop-filter: blur(4px);
}

.center .logo {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  box-shadow: none;
}

.center .title {
  font-weight: 900;
  color: var(--navy);
  font-size: 20px;
}

/* Orbiting badges */
.badge {
  --r: 120px;
  --t: 9s;
  --delay: 0s;
  --clr: var(--blue);

  position: absolute;
  left: 50%;
  top: 50%;

  transform-origin: calc(-1 * var(--r)) 0;
  animation: orbit var(--t) linear infinite;
}

.badge > span {
  display: inline-flex;
  align-items: center;
  gap: 8px;

  background: #fff;
  color: var(--ink);

  border: 1px solid var(--card-b);
  border-radius: 999px;
  padding: 8px 12px;

  font-weight: 700;
  font-size: 14px;

  box-shadow: 0 10px 22px rgba(17, 24, 39, 0.10);
}

.badge svg {
  width: 18px;
  height: 18px;
  color: var(--clr);
}

.badge.delay  { animation-delay: calc(var(--t) / -3); }
.badge.delay2 { animation-delay: calc(var(--t) * -2 / 3); }

@keyframes orbit {
  from { transform: rotate(0deg) translateX(var(--r)) rotate(0deg); }
  to   { transform: rotate(360deg) translateX(var(--r)) rotate(-360deg); }
}

/* Right column: contact */
.contact {
  background: #fff;
  border: 1px solid var(--card-b);
  border-radius: 16px;
  padding: 18px;
  box-shadow: 0 10px 28px rgba(17, 24, 39, 0.08);
}

.contact .row {
  display: flex;
  gap: 12px;
  align-items: center;
  margin: 8px 0;
}

.chip {
  font-size: 13px;
  color: var(--slate);
  text-transform: uppercase;
  letter-spacing: 0.06em;

  border: 1px solid var(--navy);
  border-radius: 999px;
  padding: 2px 8px;
  display: inline-block;
}

/* Features grid */
.features {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}

@media (max-width: 1000px) {
  .features { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 560px) {
  .features { grid-template-columns: repeat(2, 1fr); }
}

.tile {
  background: #fff;
  border: 1px solid var(--card-b);
  border-radius: 12px;
  padding: 12px;

  box-shadow: 0 8px 20px rgba(17, 24, 39, 0.06);

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

.tile h3 {
  margin: 0;
  font-size: 14px;
  color: var(--navy);
}

.tile p {
  margin: 2px 0 0;
  font-size: 12px;
  color: var(--slate);
}

.icon {
  width: 38px;
  height: 38px;
  flex: 0 0 auto;
}

/* Animations for icons */
.spin   { animation: spin 10s linear infinite; }
.pulse  { animation: pulse 2.2s ease-in-out infinite; }
.ripple { animation: ripple 2.4s ease-out infinite; }
.wave   { animation: wave 1.6s linear infinite; }

@keyframes spin { to { transform: rotate(360deg); } }

@keyframes pulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 0 rgba(20, 184, 166, 0.0)); }
  50%      { transform: scale(1.06); filter: drop-shadow(0 0 10px rgba(20, 184, 166, 0.35)); }
}

@keyframes ripple {
  0%   { transform: scale(0.9); opacity: 0.85; }
  70%  { transform: scale(1.05); opacity: 0.9; }
  100% { transform: scale(0.9); opacity: 0.85; }
}

@keyframes wave {
  0%   { transform: translateX(0); }
  50%  { transform: translateX(2px); }
  100% { transform: translateX(0); }
}

/* Footer */
.footer {
  margin-top: 16px;
  font-size: 12px;
  color: var(--slate);

  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.footer a {
  color: var(--navy);
  text-decoration: none;
  font-weight: 600;
}

.footer a:hover {
  text-decoration: underline;
}

/* ==========================================================================
   erp32.css kiegészítés — SAT (SysAdminTech) UI blokkok
   Ezt a részt tedd AZONOS fájlba (erp32.css) a brand CSS alá.
   Cél: a WebUI (ESP32) oldal inline CSS nélkül is ugyanúgy nézzen ki.
   ========================================================================== */

/* --- Layout helpers a "card" belsejéhez --- */
.sat-page {
  /* a .card már adja a keretet + árnyékot + paddinget */
}

.sat-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
}

@media (max-width: 720px) {
  .sat-header {
    grid-template-columns: auto 1fr;
  }
  .sat-bigline {
    grid-column: 1 / -1;
    text-align: left;
    margin-top: 6px;
  }
}

.sat-brandtext {
  min-width: 0;
}

.sat-bigline {
  text-align: right;
  font-weight: 800;
  color: var(--ink);
}

.sat-url {
  font-size: 18px;
  line-height: 1.1;
}

.sat-mail {
  font-size: 16px;
  line-height: 1.1;
  color: var(--slate);
}

/* --- Login oldali kártya méret (showLogin) --- */
.sat-login-card {
  width: min(420px, 92vw);
}

/* --- Tipográfia / címek --- */
.sat-title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.sat-badges {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.sat-badge {
  font-size: 11px;
  background: #eef2ff;
  color: #4338ca;
  padding: 3px 8px;
  border-radius: 10px;
  font-weight: 600;
  border: 1px solid rgba(30, 58, 138, 0.15);
}

/* --- A features rácsot "wrap"-ként használjuk a root oldalon --- */
.sat-wrap {
  /* .features: grid-template-columns: repeat(6,1fr) */
  /* Root oldalon "tile wide" elemeket teszünk egymás alá */
  grid-template-columns: 1fr !important;
}

/* --- Tile széles változat, root oldal szekciókhoz --- */
.sat-tile-wide {
  min-height: auto;
  align-items: stretch;
  flex-direction: column;
}

/* --- Mért érték (nagy szám) --- */
.sat-bigvals {
  display: flex;
  justify-content: center;
  margin: 12px 0 6px;
}

.sat-bigbox {
  text-align: center;
}

.sat-lbl {
  color: #64748b;
  margin-bottom: 6px;
  font-weight: 600;
}

.sat-valrow {
  display: inline-flex;
  align-items: baseline;
  gap: 6px;
}

.sat-val {
  font-size: 44px;
  font-weight: 800;
  color: var(--red);
  letter-spacing: -0.5px;
}

.sat-unit {
  font-size: 24px;
  color: #64748b;
  font-weight: 700;
}

/* --- Time line --- */
.sat-time {
  font-size: 13px;
  color: #64748b;
  text-align: center;
  margin-top: 14px;
}

/* --- Key/Value grid (Eszköz adatok) --- */
.sat-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 12px;
  margin-top: 10px;
}

.sat-kv {
  background: #f8fafc;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #e2e8f0;
  font-size: 14px;
  word-break: break-all;
}

.sat-kv b {
  color: var(--navy);
}

/* --- Form (Kalibráció) --- */
.sat-form {
  margin-top: 8px;
}

.sat-row {
  display: flex;
  gap: 15px;
}

@media (max-width: 620px) {
  .sat-row {
    flex-direction: column;
  }
}

.sat-field {
  flex: 1;
  min-width: 0;
}

.sat-label {
  font-weight: 700;
  margin-bottom: 6px;
  display: block;
  color: var(--ink);
}

.sat-input {
  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 2px solid var(--navy);
  background: #fff;
  color: var(--ink);
  outline: none;
}

.sat-input:focus {
  box-shadow: 0 0 0 4px rgba(37, 99, 235, 0.18);
  border-color: var(--blue);
}

/* --- Actions: Mentés + Kilépés --- */
.sat-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin-top: 12px;
}

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

/* --- Gombok (link is lehet gomb) --- */
.sat-btn {
  display: inline-block;
  text-align: center;

  width: 100%;
  padding: 10px 12px;
  border-radius: 10px;
  border: 0;

  background: var(--red);
  color: #fff;
  font-weight: 800;
  cursor: pointer;

  box-shadow: 0 6px 16px rgba(220, 38, 38, 0.25);
  text-decoration: none;
}

.sat-btn:hover {
  filter: brightness(0.98);
}

.sat-btn:active {
  transform: translateY(1px);
}

.sat-btn-secondary {
  background: #475569;
  box-shadow: 0 6px 16px rgba(71, 85, 105, 0.22);
}

/* --- Footer finomhangolás a root oldalon --- */
.sat-footer {
  margin-top: 18px;
}

/* --- Optional: linkek a sat területen ne legyenek aláhúzva --- */
.sat-page a {
  color: inherit;
}
.sat-page a:hover {
  text-decoration: underline;
}

