/* ── HearMi – Stile ────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }

:root {
  --accent:   #e08c00;
  --accent-d: #455a64;
  --bg:       #f5f7f8;
  --text:     #37474f;
  --light:    #ffffff;
  --radius:   12px;
}

html, body {
  margin: 0; padding: 0;
  font-family: 'Lato', sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

/* ── Header ── */
header {
   background: #607d8b;
  padding: 14px 20px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
header h1 { margin: 0; font-size: 1.6rem; font-weight: 700; }
header h1 a { color: #fff !important; text-decoration: none !important; letter-spacing: 1px; }
.langs a { margin-left: 10px; }
.langs img { height: 22px; width: auto; border-radius: 3px; }

/* ── Main content ── */
.page {
  max-width: 520px;
  margin: 40px auto;
  padding: 0 20px 60px;
  text-align: center;
}

.intro {
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--accent-d);
  margin-bottom: 32px;
}
.intro p { margin: 0 0 12px; }

/* ── Pulsanti ── */
a.btn, button.btn, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: var(--accent) !important;
  color: #fff !important;
  border: none;
  border-radius: var(--radius);
  padding: 14px 32px;
  font-size: 1.05rem;
  font-family: inherit;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none !important;
  transition: background .2s, transform .1s;
  margin: 8px;
  box-shadow: 0 2px 8px rgba(0,0,0,.15);
}
a.btn:hover, button.btn:hover, .btn:hover { background: var(--accent-d) !important; color: #fff !important; }
a.btn:active, button.btn:active, .btn:active { transform: scale(.97); }
a.btn:disabled, button.btn:disabled, .btn.disabled { opacity: .45; cursor: not-allowed; pointer-events: none; }

a.btn.outline, button.btn.outline, .btn.outline {
  background: transparent !important;
  border: 2px solid var(--accent);
  color: var(--accent) !important;
  box-shadow: none;
}
a.btn.outline:hover, button.btn.outline:hover, .btn.outline:hover {
  background: var(--accent) !important;
  color: #fff !important;
}

/* ── Icona centrale ── */
.hero-icon {
  font-size: 5rem;
  margin: 24px 0;
  line-height: 1;
  user-select: none;
}

/* ── Timer / contatore ── */
.timer {
  font-size: 2rem;
  font-weight: 700;
  color: var(--accent);
  margin: 16px 0;
  min-height: 2.5rem;
}

/* ── Barra di progresso audio ── */
.progress-wrap {
  width: 100%;
  background: #dde3e7;
  border-radius: 99px;
  height: 8px;
  margin: 16px 0;
  overflow: hidden;
  display: none;
}
.progress-bar {
  height: 100%;
  background: var(--accent);
  width: 0%;
  transition: width .5s linear;
  border-radius: 99px;
}

/* ── Pulse animation per recording ── */
@keyframes pulse {
  0%   { box-shadow: 0 0 0 0 rgba(96,125,139,.5); }
  70%  { box-shadow: 0 0 0 18px rgba(96,125,139,0); }
  100% { box-shadow: 0 0 0 0 rgba(96,125,139,0); }
}
button.btn.recording {
  animation: pulse 1.4s infinite;
  background: #c0392b !important;
}
button.btn.recording:hover { background: #962d22 !important; }

/* ── Modal ── */
.modal-overlay {
  display: none;
  position: fixed; inset: 0;
  background: rgba(0,0,0,.5);
  z-index: 100;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.modal-overlay.show { display: flex; }
.modal-box {
  background: var(--light);
  border-radius: var(--radius);
  padding: 28px 24px;
  max-width: 400px;
  width: 100%;
  text-align: center;
  box-shadow: 0 8px 32px rgba(0,0,0,.18);
}
.modal-box h2 { margin: 0 0 12px; font-size: 1.3rem; color: var(--accent-d); }
.modal-box p  { margin: 0 0 20px; line-height: 1.6; }
.modal-actions { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }

/* ── Footer ── */
footer {
  text-align: center;
  padding: 16px;
  font-size: .8rem;
  color: #90a4ae;
}

.logo-link { display:flex; align-items:center; gap:10px; text-decoration:none !important; }
.logo-img  { height:48px; width:48px; object-fit:contain; border-radius:8px; }
.logo-text { color:#fff !important; font-size:1.6rem; font-weight:700; }