/* ============================================================
   DYNVITIA HQ — hoja de estilos base
   Paleta de marca (misma que landing/save-the-date):
     --hueso   #F4F4F0  Blanco Hueso (Porcelain)
     --carbon  #22252A  Carbón Orgánico (Shadow Grey)
     --vino    #8C263E  Rubí Quemado (Dark Amaranth) — acento principal
     --taupe   #D3A297  Rosa Viejo Satinado — solo fondo/decorativo,
                        NUNCA como texto sobre fondo claro (bajo contraste)
   Tipografía: Gloock (display, editorial) + Jost (cuerpo)
   ============================================================ */

:root {
  --hueso: #F4F4F0;
  --carbon: #1c1e22;
  --carbon-2: #22252A;
  --carbon-soft: #4a4d52;
  --vino: #8C263E;
  --vino-dark: #6e1e31;
  --taupe: #D3A297;
  --line: rgba(244,244,240,0.12);
  --white: #fffdf8;

  --font-display: 'Gloock', serif;
  --font-body: 'Jost', sans-serif;
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--carbon);
  color: var(--hueso);
  font-family: var(--font-body);
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }
button { font-family: inherit; }

::selection { background: var(--vino); color: var(--white); }

/* ---------------- LOGIN ---------------- */
.hq-login-screen {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  background: var(--carbon);
  overflow: hidden;
  padding: 24px;
}

.hq-login-screen::before {
  content: '';
  position: absolute;
  inset: -20%;
  background:
    radial-gradient(circle at 22% 18%, rgba(140, 38, 62, 0.35), transparent 42%),
    radial-gradient(circle at 82% 78%, rgba(211, 162, 151, 0.16), transparent 46%);
  pointer-events: none;
}

.hq-login-card {
  position: relative;
  width: 100%;
  max-width: 380px;
  text-align: center;
}

.hq-login-mark {
  font-family: var(--font-body);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.36em;
  text-transform: uppercase;
  color: var(--taupe);
  margin: 0 0 14px;
}

.hq-login-title {
  font-family: var(--font-display);
  font-size: 56px;
  font-weight: 400;
  margin: 0 0 10px;
  letter-spacing: 0.01em;
  line-height: 1;
}

.hq-login-rule {
  width: 44px;
  height: 1px;
  background: var(--vino);
  margin: 22px auto 26px;
}

.hq-login-sub {
  font-size: 14px;
  font-weight: 300;
  color: rgba(244,244,240,0.5);
  margin: 0 0 44px;
  letter-spacing: 0.01em;
}

.hq-google-btn {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 15px;
  border-radius: 2px;
  border: 1px solid var(--line);
  background: var(--hueso);
  color: var(--carbon);
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background 0.2s ease, transform 0.15s ease, box-shadow 0.2s ease;
}
.hq-google-btn:hover {
  background: var(--white);
  transform: translateY(-1px);
  box-shadow: 0 8px 24px rgba(0,0,0,0.25);
}
.hq-google-btn:disabled { opacity: 0.55; cursor: default; transform: none; box-shadow: none; }
.hq-google-btn svg { flex-shrink: 0; }

.hq-login-error {
  margin-top: 18px;
  font-size: 13px;
  color: var(--taupe);
  min-height: 18px;
}

/* ---------------- APP SHELL ---------------- */
.hq-app { min-height: 100vh; }

.hq-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 26px 48px;
  border-bottom: 1px solid var(--line);
}

.hq-topbar-mark {
  font-family: var(--font-display);
  font-size: 21px;
  letter-spacing: 0.02em;
  display: flex;
  align-items: baseline;
  gap: 8px;
}
.hq-topbar-mark em {
  font-style: normal;
  font-size: 13px;
  font-family: var(--font-body);
  font-weight: 500;
  letter-spacing: 0.14em;
  color: var(--taupe);
  border: 1px solid var(--taupe);
  padding: 2px 7px;
  border-radius: 2px;
}

.hq-topbar-right {
  display: flex;
  align-items: center;
  gap: 20px;
  font-size: 12px;
  color: rgba(244,244,240,0.5);
  letter-spacing: 0.02em;
}

.hq-logout-btn {
  background: none;
  border: 1px solid var(--line);
  color: var(--hueso);
  padding: 9px 18px;
  border-radius: 2px;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  cursor: pointer;
  transition: border-color 0.2s ease, background 0.2s ease, color 0.2s ease;
}
.hq-logout-btn:hover { border-color: var(--taupe); background: rgba(211,162,151,0.08); color: var(--taupe); }

/* ---------------- HUB / MÓDULOS ---------------- */
.hq-hub {
  max-width: 1100px;
  margin: 0 auto;
  padding: 90px 48px 120px;
}

.hq-hub-eyebrow {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--taupe);
  margin: 0 0 20px;
}

.hq-hub-title {
  font-family: var(--font-display);
  font-size: 52px;
  font-weight: 400;
  margin: 0 0 64px;
  max-width: 680px;
  line-height: 1.2;
  letter-spacing: 0.005em;
}
.hq-hub-title em {
  font-style: italic;
  color: var(--taupe);
}

.hq-module-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-bottom: 1px solid var(--line);
}

@media (max-width: 860px) {
  .hq-module-grid { grid-template-columns: 1fr; }
  .hq-topbar { padding: 20px 22px; }
  .hq-hub { padding: 56px 22px 90px; }
  .hq-hub-title { font-size: 36px; margin-bottom: 48px; }
}

.hq-module-card {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  text-decoration: none;
  color: var(--hueso);
  border-top: 1px solid var(--line);
  border-right: 1px solid var(--line);
  padding: 36px 30px 40px;
  min-height: 300px;
  overflow: hidden;
  transition: background 0.3s ease;
}
.hq-module-grid .hq-module-card:last-child { border-right: 1px solid var(--line); }

.hq-module-card::after {
  content: '';
  position: absolute;
  left: 0; right: 0; bottom: 0;
  height: 2px;
  background: var(--vino);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.35s ease;
}
.hq-module-card:hover::after { transform: scaleX(1); }
.hq-module-card:hover { background: rgba(140,38,62,0.06); }

.hq-module-index {
  font-family: var(--font-display);
  font-size: 15px;
  color: var(--taupe);
  letter-spacing: 0.02em;
}

.hq-module-name {
  font-family: var(--font-display);
  font-size: 34px;
  font-weight: 400;
  margin: 56px 0 12px;
  line-height: 1.1;
}

.hq-module-desc {
  font-size: 13.5px;
  font-weight: 300;
  color: rgba(244,244,240,0.5);
  line-height: 1.6;
  margin: 0;
  max-width: 240px;
}

.hq-module-arrow {
  position: absolute;
  top: 34px;
  right: 28px;
  font-family: var(--font-display);
  font-size: 20px;
  color: rgba(244,244,240,0.25);
  transition: color 0.3s ease, transform 0.3s ease;
}
.hq-module-card:hover .hq-module-arrow {
  color: var(--taupe);
  transform: translate(3px, -3px);
}
