/* ============================================
   NENAST — Home Dashboard  (light theme)
   ============================================ */

@import url('https://fonts.googleapis.com/css2?family=Manrope:wght@400;500;600&family=JetBrains+Mono:wght@400;500&display=swap');

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --bg:           #f0f2f7;
  --bg-card:      #ffffff;
  --bg-card-hover:#f7f9fc;
  --border:       rgba(0,0,0,0.08);
  --border-hover: rgba(0,0,0,0.16);
  --accent:       #2563eb;
  --accent-dim:   rgba(37,99,235,0.10);
  --green:        #059669;
  --green-dim:    rgba(5,150,105,0.10);
  --amber-dim:    rgba(217,119,6,0.10);
  --text-1:       #111827;
  --text-2:       #4b5563;
  --text-3:       #9ca3af;
  --mono:         'JetBrains Mono', monospace;
  --sans:         'Manrope', sans-serif;
  --radius:       14px;
  --radius-sm:    8px;
  --shadow:       0 1px 4px rgba(0,0,0,0.07), 0 4px 16px rgba(0,0,0,0.04);
}

html { font-size: 16px; }

body {
  font-family: var(--sans);
  background: var(--bg);
  color: var(--text-1);
  min-height: 100vh;
  line-height: 1.6;
}

/* ---- Hero ---- */

.hero-wrapper {
  background-image: url("img/bg.jpg");
  background-position: center center;
  background-repeat: no-repeat;
  background-size: cover;
  height: 220px;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}

.hero-wrapper::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0.55) 0%, rgba(0,0,0,0.35) 100%);
}

.nadpis1 {
  position: relative;
  text-align: center;
}

.nadpis1 h1 {
  font-size: clamp(1.8rem, 5vw, 2.6rem);
  font-weight: 600;
  letter-spacing: 0.12em;
  color: #ffffff;
  text-shadow: 0 2px 12px rgba(0,0,0,0.4);
}

/* ---- Layout ---- */

.Site-Content {
  max-width: 960px;
  margin: 0 auto;
  padding: 2rem 1.25rem 4rem;
}

.conteynerblokov {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}

/* ---- Section labels ---- */

.section-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 0.6rem;
}

/* ---- Grids ---- */

.row-grid   { display: grid; gap: 12px; }
.row-grid-2 { grid-template-columns: 1fr 1fr; }
.row-grid-3 { grid-template-columns: repeat(3, 1fr); }

@media (max-width: 640px) {
  .row-grid-2,
  .row-grid-3 { grid-template-columns: 1fr; }
}

/* ---- Base card ---- */

.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem 1.5rem;
  box-shadow: var(--shadow);
  transition: border-color 0.18s, box-shadow 0.18s;
}

.card:hover {
  border-color: var(--border-hover);
  box-shadow: 0 2px 8px rgba(0,0,0,0.10), 0 6px 24px rgba(0,0,0,0.06);
}

/* ---- Nav cards ---- */

.nav-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 1.75rem 1.25rem;
  text-decoration: none;
  cursor: pointer;
  text-align: center;
}

.nav-card .icon-wrap {
  width: 52px; height: 52px;
  border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px;
  transition: transform 0.18s;
}

.nav-card:hover .icon-wrap { transform: scale(1.08); }

.icon-wrap.blue  { background: var(--accent-dim); }
.icon-wrap.green { background: var(--green-dim); }
.icon-wrap.amber { background: var(--amber-dim); }

.nav-card .label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-2);
}

/* ---- Sensor cards ---- */

.sensor-card .room-name {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.13em;
  text-transform: uppercase;
  color: var(--text-3);
  margin-bottom: 10px;
}

.sensor-card .metrics {
  display: flex;
  gap: 16px;
  align-items: center;
  margin-bottom: 10px;
}

.sensor-card .divider-v {
  width: 1px;
  height: 34px;
  background: var(--border);
  flex-shrink: 0;
}

.sensor-card .metric-val {
  font-family: var(--mono);
  font-size: 26px;
  font-weight: 500;
  color: var(--text-1);
  line-height: 1;
  letter-spacing: -0.02em;
}

.sensor-card .metric-val .unit {
  font-size: 13px;
  color: var(--text-3);
  margin-left: 1px;
}

.sensor-card .metric-lbl {
  font-size: 11px;
  color: var(--text-3);
  margin-top: 3px;
}

.sensor-card .updated {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text-3);
  display: flex;
  align-items: center;
  gap: 6px;
  border-top: 1px solid var(--border);
  padding-top: 8px;
}

.online-dot {
  width: 6px; height: 6px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 5px rgba(5,150,105,0.5);
  flex-shrink: 0;
}

/* ---- Weather card ---- */

.weather-main {
  display: flex;
  align-items: center;
  gap: 1.25rem;
  margin-bottom: 1rem;
}

.weather-icon { font-size: 44px; line-height: 1; }

.weather-temp {
  font-family: var(--mono);
  font-size: 50px;
  font-weight: 500;
  color: var(--text-1);
  line-height: 1;
  letter-spacing: -0.03em;
}

.weather-temp sup { font-size: 22px; }

.weather-meta { flex: 1; }

.weather-city {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-1);
}

.weather-desc {
  font-size: 12px;
  color: var(--text-2);
  margin-top: 2px;
}

.weather-hl { display: flex; gap: 10px; margin-top: 6px; }

.weather-hl .h {
  font-family: var(--mono);
  font-size: 12px;
  color: #dc2626;
}

.weather-hl .l {
  font-family: var(--mono);
  font-size: 12px;
  color: #2563eb;
}

.week-row {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 4px;
  border-top: 1px solid var(--border);
  padding-top: 1rem;
}

.week-day {
  text-align: center;
  padding: 6px 4px;
  border-radius: var(--radius-sm);
}

.week-day:hover { background: var(--bg); }

.wd-name {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.07em;
  color: var(--text-3);
  text-transform: uppercase;
}

.wd-ico  { font-size: 18px; margin: 4px 0; }
.wd-hi   { font-family: var(--mono); font-size: 12px; color: var(--text-1); }
.wd-lo   { font-family: var(--mono); font-size: 11px; color: var(--text-3); margin-top: 1px; }

/* ---- Link card ---- */

.link-card {
  display: flex;
  align-items: center;
  gap: 14px;
  text-decoration: none;
  cursor: pointer;
}

.link-card .link-icon {
  width: 44px; height: 44px;
  border-radius: var(--radius-sm);
  background: var(--bg);
  border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-size: 20px;
  flex-shrink: 0;
  transition: transform 0.18s;
}

.link-card:hover .link-icon { transform: scale(1.06); }

.link-card .link-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-1);
}

.link-card .link-sub {
  font-size: 12px;
  color: var(--text-3);
  margin-top: 1px;
}

.link-card .arrow {
  margin-left: auto;
  color: var(--text-3);
  font-size: 20px;
  transition: transform 0.18s, color 0.18s;
}

.link-card:hover .arrow {
  transform: translateX(3px);
  color: var(--accent);
}

/* ---- PHP fallback text ---- */

p.temp-value {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--text-3);
  margin-top: 2px;
}
