/* HatHost Free WiFi — portale hotspot (hotspot.php) e pagina connesso (wifi.php) */
:root {
  --bg: #0a0a0b;
  --fg: #f5f5f7;
  --muted: #a1a1aa;
  --dim: #71717a;
  --line: rgba(255, 255, 255, 0.1);
  --card: rgba(24, 24, 27, 0.72);
  --accent: #ff002b;
  --accent-soft: #ff4d6a;
  --ok: #22c55e;
  --font-display: "Outfit", system-ui, sans-serif;
  --font-body: "Plus Jakarta Sans", system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  min-height: 100dvh;
  font-family: var(--font-body);
  color: var(--fg);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }

.wf {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: 100dvh;
  display: grid; grid-template-rows: auto 1fr auto;
  padding: clamp(1.25rem, 3vw, 2rem) clamp(1rem, 5vw, 4rem);
}
.wf::before {
  content: ""; position: absolute; inset: 0; z-index: -2;
  background:
    radial-gradient(50% 60% at 85% 15%, rgba(255, 0, 43, 0.28), transparent 65%),
    radial-gradient(45% 55% at 5% 100%, rgba(255, 0, 43, 0.14), transparent 70%);
}
.wf-grid {
  position: absolute; inset: -56px; z-index: -1;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.05) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(70% 70% at 70% 35%, #000, transparent 75%);
  mask-image: radial-gradient(70% 70% at 70% 35%, #000, transparent 75%);
  animation: wf-drift 18s linear infinite;
  pointer-events: none;
}
@keyframes wf-drift { to { transform: translate(56px, 56px); } }

.wf-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.wf-logo img { display: block; height: clamp(2.2rem, 5vw, 3rem); width: auto; filter: brightness(0) invert(1); }
.wf-top-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.55rem 1rem; border-radius: 999px;
  font-size: 0.85rem; font-weight: 600; text-decoration: none;
  border: 1px solid var(--line); background: rgba(255, 255, 255, 0.04);
  transition: border-color 0.2s ease, background 0.2s ease;
}
.wf-top-link:hover { border-color: rgba(255, 255, 255, 0.3); background: rgba(255, 255, 255, 0.08); }

.wf-main {
  display: grid; align-items: center;
  gap: clamp(2rem, 5vw, 4.5rem);
  width: 100%; max-width: 72rem; margin: 0 auto;
  padding: clamp(2rem, 7vw, 5rem) 0;
}
@media (min-width: 960px) { .wf-main { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); } }

.wf-kicker {
  display: inline-flex; align-items: center; gap: 0.6rem;
  margin: 0 0 1.2rem; padding: 0.42rem 0.9rem 0.42rem 0.75rem;
  border-radius: 999px;
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: #86efac; background: rgba(34, 197, 94, 0.1); border: 1px solid rgba(34, 197, 94, 0.3);
}
.wf-dot { position: relative; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: var(--ok); }
.wf-dot::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%;
  border: 2px solid var(--ok); animation: wf-ping 2s ease-out infinite;
}
@keyframes wf-ping { from { opacity: 0.8; transform: scale(0.6); } to { opacity: 0; transform: scale(1.9); } }

h1 {
  margin: 0 0 1.1rem;
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 6vw, 4.2rem);
  font-weight: 800; line-height: 1.02; letter-spacing: -0.04em;
}
h1 em { font-style: normal; color: var(--accent); }
.wf-lede { margin: 0; max-width: 34rem; font-size: clamp(1.02rem, 1.8vw, 1.15rem); line-height: 1.65; color: var(--muted); }
.wf-lede strong { color: var(--fg); font-weight: 600; }

.wf-actions { display: flex; flex-wrap: wrap; gap: 0.75rem; margin-top: 2rem; }
.wf-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.55rem;
  min-height: 3.1rem; padding: 0 1.4rem; border-radius: 0.8rem;
  font-family: var(--font-display); font-size: 1rem; font-weight: 700; text-decoration: none;
  border: 1px solid transparent;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}
.wf-btn:focus-visible, .wf-top-link:focus-visible, .wf-svc a:focus-visible, .wf-social a:focus-visible { outline: 2px solid #fff; outline-offset: 3px; }
.wf-btn-primary { color: #fff; background: var(--accent); box-shadow: 0 16px 34px -16px rgba(255, 0, 43, 0.8); }
.wf-btn-primary:hover { background: #d90024; transform: translateY(-1px); }
.wf-btn-ghost { border-color: rgba(255, 255, 255, 0.18); }
.wf-btn-ghost:hover { border-color: rgba(255, 255, 255, 0.45); transform: translateY(-1px); }
.wf-btn svg { width: 1rem; height: 1rem; flex: none; }
.wf-dest { margin: 0.8rem 0 0; font-size: 0.85rem; color: var(--dim); overflow-wrap: anywhere; }

.wf-tips { display: grid; gap: 0.6rem; margin: 2.2rem 0 0; padding: 0; list-style: none; max-width: 34rem; }
.wf-tips li { display: flex; gap: 0.7rem; align-items: flex-start; font-size: 0.9rem; line-height: 1.5; color: var(--muted); }
.wf-tips svg { flex: none; width: 1.1rem; height: 1.1rem; margin-top: 0.12rem; color: var(--accent-soft); }

/* riquadro servizi */
.wf-card {
  border-radius: 1.3rem; background: var(--card); border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
  box-shadow: 0 40px 80px -50px rgba(0, 0, 0, 0.9);
  overflow: hidden;
}
.wf-card-head {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1rem 1.3rem; border-bottom: 1px solid var(--line);
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--dim);
}
.wf-card-head time { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; letter-spacing: 0; text-transform: none; font-weight: 500; }
.wf-svc { margin: 0; padding: 0.4rem 0; list-style: none; }
.wf-svc li + li { border-top: 1px solid rgba(255, 255, 255, 0.05); }
.wf-svc a {
  display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; gap: 0.95rem;
  padding: 0.85rem 1.3rem; text-decoration: none;
  transition: background 0.2s ease;
}
.wf-svc a:hover { background: rgba(255, 255, 255, 0.04); }
.wf-ico {
  display: grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 0.7rem;
  color: var(--accent-soft); background: rgba(255, 0, 43, 0.1); border: 1px solid rgba(255, 0, 43, 0.2);
}
.wf-ico svg { width: 1.15rem; height: 1.15rem; }
.wf-svc strong { display: block; font-size: 0.95rem; font-weight: 600; }
.wf-svc small { display: block; margin-top: 0.1rem; font-size: 0.8rem; color: var(--dim); }
.wf-arrow { color: var(--dim); transition: transform 0.2s ease, color 0.2s ease; }
.wf-svc a:hover .wf-arrow { color: #fff; transform: translateX(3px); }
.wf-card-foot {
  display: grid; gap: 0.8rem;
  padding: 1.1rem 1.3rem 1.3rem; border-top: 1px solid var(--line);
}
.wf-card-foot p { margin: 0; font-size: 0.88rem; line-height: 1.5; color: var(--muted); }
.wf-card-foot .wf-btn { width: 100%; min-height: 2.8rem; font-size: 0.95rem; }

.wf-foot {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem;
  width: 100%; max-width: 72rem; margin: 0 auto; padding-top: 1.4rem;
  border-top: 1px solid var(--line);
  font-size: 0.85rem; color: var(--dim);
}
.wf-foot a { color: #d4d4d8; text-decoration: none; }
.wf-foot a:hover { color: #fff; }
.wf-links { display: flex; flex-wrap: wrap; gap: 0.4rem 1.4rem; }
.wf-legal { width: 100%; font-size: 0.75rem; line-height: 1.5; }
.wf-social { display: flex; gap: 0.35rem; margin: 0; padding: 0; list-style: none; }
.wf-social a {
  display: grid; place-items: center; width: 2.1rem; height: 2.1rem; border-radius: 50%;
  color: #a1a1aa; background: rgba(255, 255, 255, 0.06);
  transition: color 0.2s ease, background 0.2s ease;
}
.wf-social a:hover { color: #fff; background: var(--accent); }
.wf-social svg { width: 0.95rem; height: 0.95rem; }

.wf-in { animation: wf-rise 0.8s var(--ease) both; }
.wf-in.d1 { animation-delay: 0.06s; } .wf-in.d2 { animation-delay: 0.12s; } .wf-in.d3 { animation-delay: 0.18s; } .wf-in.d4 { animation-delay: 0.26s; }
@keyframes wf-rise { from { opacity: 0; transform: translateY(14px); } to { opacity: 1; transform: none; } }

@media (max-width: 600px) {
  .wf-top-link span { display: none; }
  .wf-actions .wf-btn { flex: 1 1 100%; }
  .wf-foot { flex-direction: column; align-items: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
  .wf-grid, .wf-dot::after, .wf-in { animation: none !important; }
}

/* ---------- portale di accesso (hotspot.php) ---------- */
.wf-accept {
  display: flex; gap: 0.75rem; align-items: flex-start;
  margin: 1.8rem 0 0; max-width: 34rem;
  font-size: 0.9rem; line-height: 1.5; color: var(--muted); cursor: pointer;
}
.wf-accept input {
  flex: none; width: 1.2rem; height: 1.2rem; margin: 0.12rem 0 0;
  accent-color: var(--accent); cursor: pointer;
}
.wf-accept a { color: var(--fg); }
.wf-actions button.wf-btn { cursor: pointer; }
.wf-actions button.wf-btn:disabled { opacity: 0.6; cursor: progress; transform: none; }
.wf-alert {
  margin: 1.4rem 0 0; max-width: 34rem; padding: 0.85rem 1rem; border-radius: 0.8rem;
  font-size: 0.9rem; line-height: 1.5;
  color: #fecaca; background: rgba(255, 0, 43, 0.1); border: 1px solid rgba(255, 0, 43, 0.35);
}
.wf-badge {
  position: fixed; bottom: 0.85rem; left: 50%; transform: translateX(-50%); z-index: 5;
  padding: 0.35rem 0.8rem; border-radius: 999px;
  background: #fff; color: #0a0a0b; font-size: 0.72rem; font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase;
}
.wf-place { margin: -0.4rem 0 1.1rem; font-size: 0.95rem; font-weight: 600; color: var(--accent-soft); }

/* ---------- racconto della zona (wifi.php) ---------- */
.wz {
  width: 100%; max-width: 72rem; margin: 0 auto;
  padding: clamp(1rem, 4vw, 2rem) 0 clamp(2.5rem, 7vw, 4.5rem);
}
.wz-head { max-width: 40rem; margin-bottom: clamp(1.8rem, 4vw, 2.6rem); }
.wz-kicker {
  margin: 0 0 0.7rem; font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase;
  color: var(--accent-soft);
}
.wz h2 {
  margin: 0 0 0.8rem; font-family: var(--font-display);
  font-size: clamp(1.8rem, 4.5vw, 2.8rem); font-weight: 800; line-height: 1.05; letter-spacing: -0.03em;
}
.wz-head p { margin: 0; font-size: 1.02rem; line-height: 1.65; color: var(--muted); }
.wz-cols { display: grid; gap: clamp(2rem, 5vw, 4rem); }
@media (min-width: 960px) { .wz-cols { grid-template-columns: minmax(0, 1.2fr) minmax(0, 1fr); } }
.wz h3 {
  margin: 0 0 1.2rem; font-family: var(--font-display); font-size: 1.25rem; font-weight: 700; letter-spacing: -0.01em;
}

.wz-time { position: relative; margin: 0; padding: 0; list-style: none; }
.wz-time::before {
  content: ""; position: absolute; left: 0.45rem; top: 0.5rem; bottom: 0.5rem; width: 2px;
  background: linear-gradient(var(--accent), rgba(255, 0, 43, 0.1));
}
.wz-time li { position: relative; padding: 0 0 1.6rem 2.2rem; }
.wz-time li:last-child { padding-bottom: 0; }
.wz-time li::before {
  content: ""; position: absolute; left: 0; top: 0.3rem; width: 0.95rem; height: 0.95rem; border-radius: 50%;
  background: var(--bg); border: 2px solid var(--accent); box-shadow: 0 0 0 4px rgba(255, 0, 43, 0.12);
}
.wz-year {
  display: inline-block; margin-bottom: 0.3rem; padding: 0.15rem 0.55rem; border-radius: 0.4rem;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.78rem; font-weight: 600;
  color: var(--accent-soft); background: rgba(255, 0, 43, 0.1);
}
.wz-time strong { display: block; margin-bottom: 0.3rem; font-size: 1.02rem; font-weight: 700; }
.wz-time p { margin: 0; font-size: 0.95rem; line-height: 1.65; color: var(--muted); }

.wz-side { display: grid; gap: 1.2rem; align-content: start; }
.wz-box {
  padding: 1.3rem 1.4rem; border-radius: 1.3rem; background: var(--card); border: 1px solid var(--line);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px);
}
.wz-box h3 { margin-bottom: 0.8rem; }
.wz-box p { margin: 0; font-size: 0.95rem; line-height: 1.65; color: var(--muted); }
.wz-box p + p { margin-top: 0.8rem; }
.wz-news { margin: 0; padding: 0; list-style: none; }
.wz-news li + li { margin-top: 0.9rem; padding-top: 0.9rem; border-top: 1px solid rgba(255, 255, 255, 0.06); }
.wz-news time { display: block; margin-bottom: 0.2rem; font-size: 0.75rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: var(--dim); }
.wz-news strong { display: block; font-size: 0.98rem; }
.wz-news p { margin-top: 0.25rem; font-size: 0.9rem; }
.wz-news a { display: inline-block; margin-top: 0.4rem; font-size: 0.85rem; font-weight: 600; color: var(--accent-soft); text-decoration: none; }
.wz-news a:hover { text-decoration: underline; }
.wf-svc-row {
  display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 0.95rem;
  padding: 0.85rem 1.3rem;
}
.wf-card-foot strong { color: var(--fg); }
html { scroll-behavior: smooth; }
