/* ============================================================
   Schwarzer Adler – Self Check-in Kiosk  v1.1
   Font: Jost (passend zur Hotel-Website)
   ============================================================ */

@import url('https://fonts.googleapis.com/css2?family=Jost:ital,wght@0,300;0,400;0,500;0,600;1,300&display=swap');

:root {
  --sa-bg:        #F5F2EB;
  --sa-surface:   #FFFFFF;
  --sa-green:     #3D5038;
  --sa-green-mid: #4E6647;
  --sa-green-soft:#E8EDE6;
  --sa-border:    #E0D8CC;
  --sa-text:      #1F1C18;
  --sa-muted:     #6A6055;
  --sa-radius:    14px;
  --sa-shadow:    0 6px 28px rgba(30,25,18,.10);
  --sa-trans:     all .3s cubic-bezier(.4,0,.2,1);
}

/* ---------- Wrapper ---------- */
.sa-checkin-wrap {
  font-family: 'Jost', sans-serif;
  font-weight: 300;
  background: var(--sa-bg);
  min-height: 100vh;
  color: var(--sa-text);
  padding: 0 0 100px; /* Platz für fixed Notfall-Button */
}

/* ---------- Intro ---------- */
.sa-intro {
  text-align: center;
  color: var(--sa-muted);
  font-size: 17px;
  font-weight: 300;
  margin: 40px 24px 16px;
  line-height: 1.65;
}

/* ---------- Gäste-Grid ---------- */
.sa-guests {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 14px;
  padding: 8px 32px 24px;
  max-width: 1100px;
  margin: 0 auto;
}

/* ---------- Gast-Button ---------- */
.sa-guest-btn {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: var(--sa-surface);
  border: 1.5px solid var(--sa-border);
  border-radius: var(--sa-radius);
  padding: 18px 22px;
  cursor: pointer;
  transition: var(--sa-trans);
  text-align: left;
  box-shadow: 0 2px 8px rgba(30,25,18,.05);
  position: relative;
  overflow: hidden;
}

.sa-guest-btn::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 4px;
  background: var(--sa-green);
  border-radius: 4px 0 0 4px;
  transform: scaleY(0);
  transition: transform .25s ease;
  transform-origin: bottom;
}

.sa-guest-btn:hover,
.sa-guest-btn:focus-visible {
  border-color: var(--sa-green);
  background: var(--sa-green-soft);
  box-shadow: var(--sa-shadow);
  transform: translateY(-2px);
  outline: none;
}

.sa-guest-btn:hover::before,
.sa-guest-btn:focus-visible::before {
  transform: scaleY(1);
}

.sa-guest-btn:active { transform: translateY(0); }

.sa-guest-btn__info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0;
}

.sa-guest-btn__name {
  font-size: 19px;
  font-weight: 400;
  color: var(--sa-text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sa-guest-btn__company {
  font-size: 13px;
  font-weight: 300;
  color: var(--sa-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sa-guest-btn__arrow {
  font-size: 20px;
  color: var(--sa-green);
  transition: transform .25s ease;
  flex-shrink: 0;
}

.sa-guest-btn:hover .sa-guest-btn__arrow { transform: translateX(5px); }

/* ---------- Empty State ---------- */
.sa-empty {
  text-align: center;
  padding: 80px 32px;
  color: var(--sa-muted);
}

.sa-empty__icon {
  font-size: 56px;
  margin-bottom: 16px;
  opacity: .5;
}

/* ---------- Notfall-Button (fixed) ---------- */
.sa-emergency {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 200;
  width: min(520px, 92vw);
  filter: drop-shadow(0 6px 20px rgba(61,80,56,.28));
}

.sa-emergency__btn {
  display: flex;
  align-items: center;
  gap: 14px;
  background: var(--sa-green);
  color: #ffffff;
  border-radius: 999px;
  padding: 16px 28px;
  text-decoration: none;
  transition: var(--sa-trans);
  border: 2px solid rgba(255,255,255,.12);
}

.sa-emergency__btn:hover,
.sa-emergency__btn:focus-visible {
  background: var(--sa-green-mid);
  transform: scale(1.02);
  color: #ffffff;
  text-decoration: none;
  outline: none;
}

.sa-emergency__icon  { font-size: 24px; flex-shrink: 0; }

.sa-emergency__text  {
  display: flex;
  flex-direction: column;
  gap: 1px;
  flex: 1;
}

.sa-emergency__text strong {
  font-size: 14px;
  font-weight: 500;
  letter-spacing: .05em;
  text-transform: uppercase;
  color: #ffffff;
}

.sa-emergency__text small {
  font-size: 12px;
  font-weight: 300;
  color: rgba(255,255,255,.75);
}

.sa-emergency__number {
  font-size: 18px;
  font-weight: 500;
  color: #ffffff;
  white-space: nowrap;
}

/* ============================================================
   MODAL
   ============================================================ */
.sa-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15,12,8,.6);
  backdrop-filter: blur(5px);
  z-index: 500;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .3s ease;
}

.sa-modal-overlay.is-open {
  opacity: 1;
  pointer-events: all;
}

.sa-modal {
  background: var(--sa-surface);
  border-radius: 22px;
  width: min(560px, 100%);
  max-height: 92vh;
  overflow-y: auto;
  box-shadow: 0 24px 72px rgba(15,12,8,.3);
  transform: translateY(28px) scale(.97);
  transition: transform .38s cubic-bezier(.34,1.56,.64,1);
  position: relative;
  padding: 0 0 32px;
}

.sa-modal-overlay.is-open .sa-modal {
  transform: translateY(0) scale(1);
}

/* Schließen-Knopf */
.sa-modal__close {
  position: absolute;
  top: 16px;
  right: 18px;
  background: rgba(255,255,255,.15);
  border: none;
  border-radius: 50%;
  width: 36px;
  height: 36px;
  font-size: 15px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: var(--sa-trans);
  color: rgba(255,255,255,.8);
  z-index: 10;
}

.sa-modal__close:hover { background: rgba(255,255,255,.25); color: #fff; }

/* Modal-Header (grünes Band) */
.sa-modal__header {
  background: var(--sa-green);
  border-radius: 22px 22px 0 0;
  padding: 32px 32px 26px;
  display: flex;
  align-items: flex-start;
  gap: 18px;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.sa-modal__header::after {
  content: '';
  position: absolute;
  right: -20px; bottom: -20px;
  width: 110px; height: 110px;
  border-radius: 50%;
  background: rgba(255,255,255,.06);
  pointer-events: none;
}

.sa-modal__building-icon { font-size: 40px; line-height: 1; flex-shrink: 0; margin-top: 4px; }

.sa-modal__greeting {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .16em;
  color: rgba(255,255,255,.50);
  margin-bottom: 4px;
  font-weight: 400;
}

.sa-modal__name {
  font-size: clamp(24px, 5vw, 36px);
  font-weight: 400;
  line-height: 1.1;
}

.sa-modal__company {
  font-size: 14px;
  font-weight: 300;
  color: rgba(255,255,255,.65);
  margin-top: 4px;
}

/* Zimmer-Block */
.sa-modal__room-block {
  display: flex;
  align-items: baseline;
  gap: 14px;
  padding: 24px 32px 10px;
  border-bottom: 1px solid var(--sa-border);
  flex-wrap: wrap;
}

.sa-modal__room-label {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .16em;
  color: var(--sa-muted);
  font-weight: 400;
  flex-shrink: 0;
}

.sa-modal__room-number {
  font-size: 52px;
  font-weight: 300;
  line-height: 1;
  color: var(--sa-green);
}

.sa-modal__building-label {
  font-size: 20px;
  font-weight: 300;
  font-style: italic;
  color: var(--sa-muted);
}

/* Wegbeschreibung */
.sa-modal__directions { padding: 22px 32px 0; }

.sa-modal__dir-title {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: .16em;
  text-transform: uppercase;
  color: var(--sa-muted);
  margin: 0 0 16px;
}

.sa-modal__steps {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 13px;
}

.sa-modal__steps li {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  font-size: 16px;
  font-weight: 300;
  line-height: 1.55;
}

.sa-modal__steps li::before {
  content: attr(data-n);
  display: flex;
  align-items: center;
  justify-content: center;
  width: 27px;
  height: 27px;
  min-width: 27px;
  border-radius: 50%;
  background: var(--sa-green);
  color: #fff;
  font-size: 12px;
  font-weight: 500;
  margin-top: 2px;
  flex-shrink: 0;
}

/* Zurück-Button */
.sa-modal__back {
  display: block;
  margin: 26px 32px 0;
  background: none;
  border: 1.5px solid var(--sa-border);
  border-radius: 12px;
  padding: 13px 22px;
  font-family: 'Jost', sans-serif;
  font-size: 15px;
  font-weight: 300;
  color: var(--sa-muted);
  cursor: pointer;
  transition: var(--sa-trans);
  width: calc(100% - 64px);
  text-align: center;
}

.sa-modal__back:hover {
  border-color: var(--sa-green);
  color: var(--sa-green);
  background: var(--sa-green-soft);
}

/* ---------- Responsive ---------- */
@media (max-width: 600px) {
  .sa-guests { padding: 8px 16px 24px; }
  .sa-modal__header,
  .sa-modal__room-block,
  .sa-modal__directions,
  .sa-modal__back { padding-left: 20px; padding-right: 20px; }
  .sa-modal__back { width: calc(100% - 40px); }
  .sa-modal__room-number { font-size: 40px; }
}

/* ============================================================
   SPLASH-SCREEN
   ============================================================ */
.sa-splash {
  position: fixed;
  inset: 0;
  z-index: 900;
  background: var(--sa-green);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity .5s ease, visibility .5s ease;
  opacity: 1;
  visibility: visible;
}

.sa-splash--hidden {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.sa-splash__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding: 40px 32px;
  text-align: center;
  position: relative;
}

/* Dezenter Kreis-Hintergrund */
.sa-splash__inner::before {
  content: '';
  position: absolute;
  width: 500px;
  height: 500px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.08);
  pointer-events: none;
}

.sa-splash__inner::after {
  content: '';
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  border: 1px solid rgba(255,255,255,.06);
  pointer-events: none;
}

.sa-splash__headline {
  font-family: 'Jost', sans-serif;
  font-size: clamp(52px, 10vw, 96px);
  font-weight: 300;
  color: #ffffff;
  line-height: 1;
  letter-spacing: -.01em;
  position: relative;
}

.sa-splash__subline {
  font-family: 'Jost', sans-serif;
  font-size: 16px;
  font-weight: 300;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: rgba(255,255,255,.55);
  position: relative;
}

.sa-splash__btn {
  margin-top: 32px;
  background: #ffffff;
  color: var(--sa-green);
  border: none;
  border-radius: 999px;
  padding: 20px 48px;
  font-family: 'Jost', sans-serif;
  font-size: 18px;
  font-weight: 400;
  letter-spacing: .04em;
  cursor: pointer;
  position: relative;
  transition: transform .25s ease, box-shadow .25s ease, background .25s ease;
  box-shadow: 0 8px 32px rgba(0,0,0,.18);
  /* Pulsier-Animation damit's einladend wirkt */
  animation: sa-pulse 3s ease-in-out infinite;
}

.sa-splash__btn:hover,
.sa-splash__btn:focus-visible {
  transform: scale(1.04);
  box-shadow: 0 12px 40px rgba(0,0,0,.25);
  animation: none;
  outline: none;
}

.sa-splash__btn:active {
  transform: scale(.98);
}

@keyframes sa-pulse {
  0%, 100% { box-shadow: 0 8px 32px rgba(0,0,0,.18); }
  50%       { box-shadow: 0 8px 48px rgba(0,0,0,.30), 0 0 0 8px rgba(255,255,255,.08); }
}

/* Haupt-App ausblenden wenn Splash aktiv */
.sa-checkin-wrap--hidden {
  visibility: hidden;
  pointer-events: none;
}
