:root{
  --navy:#151E33;
  --navy-deep:#0D1526;
  --ivory:#F4EEE3;
  --gold:#B8905A;
  --gold-soft:#D9BD93;
  --wine:#732B36;
  --line: rgba(244,238,227,0.18);
  --shadow: 0 20px 60px rgba(13,21,38,0.35);
}
*{box-sizing:border-box; margin:0; padding:0;}
html,body{height:100%;}
body{
  font-family:'Jost', sans-serif;
  background:var(--ivory);
  color:var(--navy-deep);
  -webkit-font-smoothing:antialiased;
}
h1,h2,h3, .display{
  font-family:'Cormorant Garamond', serif;
  font-weight:600;
  letter-spacing:0.01em;
}
.eyebrow{
  font-family:'Jost', sans-serif;
  text-transform:uppercase;
  letter-spacing:0.28em;
  font-size:11px;
  font-weight:500;
  color:var(--gold);
}
button{font-family:inherit; cursor:pointer;}
input,textarea{font-family:inherit;}

.eiffel{ display:block; opacity:0.9; }
.eiffel-watermark{
  position:absolute; right:-40px; bottom:-40px;
  width:420px; height:420px; opacity:0.06; pointer-events:none;
}

/* ================= AUTH SCREEN ================= */
#authScreen{ min-height:100vh; display:grid; grid-template-columns: 1.1fr 1fr; }
.auth-hero{
  position:relative;
  background: linear-gradient(180deg, var(--navy) 0%, var(--navy-deep) 100%);
  color:var(--ivory);
  display:flex; flex-direction:column; justify-content:space-between;
  padding:56px 60px; overflow:hidden;
}
.auth-hero::before{ content:""; position:absolute; inset:14px; border:1px solid var(--line); pointer-events:none; }
.brand-row{ display:flex; align-items:center; gap:14px; z-index:1; }
.brand-row .eiffel{ width:26px; height:34px; }
.brand-name{ font-size:22px; letter-spacing:0.04em; }
.hero-copy{ z-index:1; max-width:420px; }
.hero-copy .eyebrow{ margin-bottom:18px; display:block; }
.hero-copy h1{ font-size:52px; line-height:1.05; font-style:italic; color:var(--ivory); }
.hero-copy p{ margin-top:22px; font-size:15px; line-height:1.7; color:rgba(244,238,227,0.72); font-weight:300; }
.hero-foot{
  z-index:1; display:flex; gap:36px; font-size:12px; text-transform:uppercase;
  letter-spacing:0.14em; color:rgba(244,238,227,0.55); border-top:1px solid var(--line); padding-top:20px;
}
.auth-panel{ display:flex; align-items:center; justify-content:center; padding:40px; background:var(--ivory); }
.auth-card{ width:100%; max-width:380px; }
.auth-card .eyebrow{ margin-bottom:10px; }
.auth-card h2{ font-size:32px; font-style:italic; margin-bottom:6px; }
.auth-sub{ font-size:13.5px; color:#6b6458; margin-bottom:32px; font-weight:300; }
.field{ margin-bottom:18px; }
.field label{ display:block; font-size:11px; text-transform:uppercase; letter-spacing:0.16em; color:#8a8172; margin-bottom:8px; }
.field input{
  width:100%; border:none; border-bottom:1.5px solid #cfc4ac; background:transparent;
  padding:9px 2px; font-size:15px; color:var(--navy-deep); outline:none; transition:border-color .2s ease;
}
.field input:focus{ border-color:var(--gold); }
.field-error{ display:none; font-size:12px; color:var(--wine); margin-top:6px; }

.btn{
  width:100%; padding:13px 18px; border-radius:2px; border:1.5px solid transparent;
  font-size:13px; letter-spacing:0.08em; text-transform:uppercase; font-weight:500;
  transition:transform .15s ease, opacity .15s ease, background .2s ease;
}
.btn:active{ transform:scale(0.98); }
.btn-primary{ background:var(--navy-deep); color:var(--ivory); margin-top:8px; }
.btn-primary:hover{ background:var(--navy); }
.btn-outline{ background:transparent; border-color:var(--navy-deep); color:var(--navy-deep); margin-top:12px; }
.btn-outline:hover{ background:rgba(21,30,51,0.05); }

.divider{ display:flex; align-items:center; gap:14px; margin:26px 0; color:#a89f8e; font-size:11px; text-transform:uppercase; letter-spacing:0.14em; }
.divider::before, .divider::after{ content:""; flex:1; height:1px; background:#dcd3c1; }

.btn-google{
  width:100%; display:flex; align-items:center; justify-content:center; gap:10px; padding:12px 18px;
  background:#fff; border:1.5px solid #e2dccc; border-radius:2px; font-size:14px; color:#2b2b2b; font-weight:500;
  text-decoration:none;
}
.btn-google:hover{ border-color:#c9bfa5; }
.btn-google svg{ width:18px; height:18px; }

.auth-toggle{ text-align:center; margin-top:28px; font-size:13px; color:#6b6458; }
.auth-toggle a{ color:var(--wine); text-decoration:none; font-weight:500; border-bottom:1px solid transparent; }
.auth-toggle a:hover{ border-color:var(--wine); }
.name-field{ display:none; }
.google-note{ font-size:11px; color:#a89f8e; text-align:center; margin-top:14px; line-height:1.5; }
.auth-error-banner{
  display:none; background:#f6e6e6; border:1px solid #e0b8b8; color:var(--wine);
  font-size:12.5px; padding:10px 14px; border-radius:4px; margin-bottom:18px;
}

/* ================= APP SCREEN ================= */
#appScreen{ display:none; min-height:100vh; }
.app-header{ display:flex; align-items:center; justify-content:space-between; padding:22px 48px; background:var(--navy-deep); color:var(--ivory); }
.app-header .brand-row{ gap:12px; }
.app-header .eiffel{ width:20px; height:26px; }
.app-header .brand-name{ font-size:18px; }
.user-chip{ display:flex; align-items:center; gap:14px; font-size:13px; color:rgba(244,238,227,0.8); }
.user-chip .avatar{
  width:32px; height:32px; border-radius:50%; background:var(--gold); color:var(--navy-deep);
  display:flex; align-items:center; justify-content:center; font-family:'Cormorant Garamond',serif; font-weight:700; font-size:15px;
  overflow:hidden;
}
.user-chip .avatar img{ width:100%; height:100%; object-fit:cover; }
.logout-link{ background:none; border:none; color:var(--gold-soft); font-size:12px; text-transform:uppercase; letter-spacing:0.1em; text-decoration:underline; }

.app-body{ max-width:1080px; margin:0 auto; padding:54px 32px 100px; }
.app-body .eyebrow{ display:block; margin-bottom:10px; }
.app-body h1{ font-size:40px; font-style:italic; margin-bottom:10px; }
.app-body > p.lead{ color:#6b6458; font-size:14.5px; max-width:560px; margin-bottom:44px; font-weight:300; }

.welcome-banner{
  display:flex; align-items:center; gap:12px;
  background:linear-gradient(90deg, var(--navy-deep), var(--navy));
  color:var(--ivory); padding:16px 24px; border-radius:4px; margin-bottom:34px;
  font-family:'Cormorant Garamond', serif; font-size:19px; font-style:italic; letter-spacing:0.01em;
  opacity:0; transform:translateY(-6px); animation: welcomeIn .5s ease forwards;
}
.welcome-icon{ color:var(--gold-soft); font-style:normal; font-size:16px; }
@keyframes welcomeIn{ to{ opacity:1; transform:translateY(0); } }

.stay-panel{
  background:#fff; border:1px solid #e6ddc9; border-radius:4px; padding:30px 34px;
  display:grid; grid-template-columns:1fr 1fr 1fr; gap:26px; margin-bottom:20px;
  box-shadow:0 12px 30px rgba(21,30,51,0.05);
}
.stay-field label{ display:block; font-size:11px; text-transform:uppercase; letter-spacing:0.14em; color:#8a8172; margin-bottom:9px; }
.stay-field input[type="date"]{
  width:100%; border:1.5px solid #dcd3c1; border-radius:3px; padding:10px 12px; font-size:14px;
  color:var(--navy-deep); background:#fdfbf6; outline:none;
}
.stay-field input[type="date"]:focus{ border-color:var(--gold); }
.nights-display{ display:flex; flex-direction:column; justify-content:center; }
.nights-display .num{ font-family:'Cormorant Garamond', serif; font-size:38px; font-weight:700; color:var(--wine); line-height:1; }
.nights-display .lbl{ font-size:12px; text-transform:uppercase; letter-spacing:0.12em; color:#8a8172; margin-top:6px; }
.stay-note{ font-size:12px; color:var(--wine); margin-bottom:44px; display:none; }

.rooms-heading{ display:flex; align-items:baseline; justify-content:space-between; margin-bottom:22px; }
.rooms-heading h2{ font-size:26px; font-style:italic; }
.rooms-heading span{ font-size:12px; color:#8a8172; text-transform:uppercase; letter-spacing:0.1em; }

.room-grid{ display:grid; grid-template-columns:1fr 1fr; gap:24px; margin-bottom:40px; }
.room-card{
  position:relative; background:#fff; border:1.5px solid #e6ddc9;
  border-radius:6px 6px 60px 60px / 6px 6px 40px 40px; padding:0 0 28px; overflow:hidden;
  cursor:pointer; transition:border-color .2s ease, box-shadow .2s ease, transform .15s ease;
}
.room-card:hover{ transform:translateY(-2px); box-shadow:var(--shadow); }
.room-card.selected{ border-color:var(--gold); box-shadow:0 14px 34px rgba(184,144,90,0.25); }
.room-card.selected::after{
  content:"✓ Seleccionada"; position:absolute; top:18px; right:22px; font-size:11px;
  letter-spacing:0.08em; text-transform:uppercase; color:var(--gold); font-weight:600;
}
.room-photo{ width:100%; height:180px; object-fit:cover; display:block; }
.room-card-body{ padding:22px 28px 0; }
.room-icon{
  width:46px; height:46px; border-radius:50%; background:var(--navy-deep); color:var(--gold-soft);
  display:flex; align-items:center; justify-content:center; margin-bottom:18px;
}
.room-icon svg{ width:22px; height:22px; }
.room-card h3{ font-size:23px; font-style:italic; margin-bottom:16px; }
.amenity-list{ list-style:none; display:grid; grid-template-columns:1fr 1fr; gap:10px 14px; }
.amenity-list li{ font-size:13px; color:#4b453b; display:flex; align-items:center; gap:8px; }
.amenity-list li::before{ content:""; width:5px; height:5px; background:var(--gold); border-radius:50%; flex-shrink:0; }

.confirm-row{ display:flex; align-items:center; justify-content:space-between; gap:20px; padding-top:24px; border-top:1px solid #e6ddc9; }
.confirm-summary{ font-size:13.5px; color:#6b6458; }
.confirm-summary b{ color:var(--navy-deep); }
.btn-confirm{ width:auto; padding:14px 32px; background:var(--wine); color:var(--ivory); }
.btn-confirm:hover{ background:#5f2129; }
.btn-confirm:disabled{ background:#d8cfbe; color:#a89f8e; cursor:not-allowed; }

.confirm-toast{ display:none; margin-top:22px; padding:18px 22px; background:#eef6ee; border:1px solid #bfe0bf; color:#2e5a2e; border-radius:4px; font-size:13.5px; }

.whatsapp-float{
  position:fixed; bottom:26px; right:26px; width:60px; height:60px; background:#25D366; border-radius:50%;
  display:flex; align-items:center; justify-content:center; box-shadow:0 8px 20px rgba(0,0,0,0.25);
  z-index:999; transition:transform .2s ease, box-shadow .2s ease; text-decoration:none;
}
.whatsapp-float:hover{ transform:scale(1.08); box-shadow:0 10px 26px rgba(0,0,0,0.32); }
.whatsapp-float svg{ width:32px; height:32px; }

/* ================= ADMIN PANEL ================= */
#adminLogin, #adminBootstrap{ min-height:100vh; display:flex; align-items:center; justify-content:center; background:var(--navy-deep); }
.admin-login-card{
  width:100%; max-width:360px; background:var(--ivory); padding:44px 36px; border-radius:6px; box-shadow:var(--shadow);
}
.admin-login-card h2{ font-size:26px; font-style:italic; margin-bottom:6px; }
.admin-login-card p{ font-size:13px; color:#6b6458; margin-bottom:26px; }
.admin-error{ display:none; font-size:12.5px; color:var(--wine); margin-top:10px; }

#adminPanel{ display:none; min-height:100vh; background:#faf7f0; }
.admin-header{
  display:flex; align-items:center; justify-content:space-between; padding:20px 40px;
  background:var(--navy-deep); color:var(--ivory);
}
.admin-body{ max-width:900px; margin:0 auto; padding:40px 28px 100px; }
.admin-section{ background:#fff; border:1px solid #e6ddc9; border-radius:6px; padding:28px 30px; margin-bottom:26px; }
.admin-section h3{ font-size:20px; font-style:italic; margin-bottom:18px; }
.admin-field{ margin-bottom:16px; }
.admin-field label{ display:block; font-size:12px; text-transform:uppercase; letter-spacing:0.1em; color:#8a8172; margin-bottom:7px; }
.admin-field input[type="text"], .admin-field input[type="password"], .admin-field textarea{
  width:100%; border:1.5px solid #dcd3c1; border-radius:3px; padding:10px 12px; font-size:14px; color:var(--navy-deep);
  background:#fdfbf6; outline:none;
}
.admin-field input:focus, .admin-field textarea:focus{ border-color:var(--gold); }
.admin-field textarea{ resize:vertical; min-height:90px; }
.admin-room{ border:1px dashed #dcd3c1; border-radius:6px; padding:20px; margin-bottom:16px; }
.admin-room-preview{ width:100%; max-width:220px; height:130px; object-fit:cover; border-radius:4px; margin-bottom:12px; background:#eee4d3; display:block; }
.admin-btn-save{ background:var(--wine); color:var(--ivory); padding:12px 26px; border-radius:2px; border:none; font-size:13px; letter-spacing:0.08em; text-transform:uppercase; }
.admin-btn-save:hover{ background:#5f2129; }
.admin-btn-secondary{ background:transparent; border:1.5px solid var(--navy-deep); color:var(--navy-deep); padding:11px 22px; border-radius:2px; font-size:13px; letter-spacing:0.08em; text-transform:uppercase; }
.save-toast{ display:none; margin-top:14px; padding:12px 16px; background:#eef6ee; border:1px solid #bfe0bf; color:#2e5a2e; border-radius:4px; font-size:13px; }
.file-input-label{
  display:inline-block; padding:9px 18px; border:1.5px solid var(--navy-deep); border-radius:2px;
  font-size:12.5px; text-transform:uppercase; letter-spacing:0.08em; cursor:pointer;
}

@media (max-width: 900px){
  #authScreen{ grid-template-columns:1fr; }
  .auth-hero{ display:none; }
  .stay-panel{ grid-template-columns:1fr; }
  .room-grid{ grid-template-columns:1fr; }
  .app-header{ padding:18px 20px; }
  .app-body{ padding:40px 20px 90px; }
  .confirm-row{ flex-direction:column; align-items:flex-start; }
  .btn-confirm{ width:100%; }
  .admin-header{ padding:18px 20px; }
}

:focus-visible{ outline:2px solid var(--gold); outline-offset:2px; }
