/* MASTER HOME — WEB APP | Page d'accueil pilote | v0.1.4 */
:root {
  color-scheme: light;
  --cream: #f8f5f0;
  --cream-deep: #eee8de;
  --ink: #292622;
  --muted: #7c7065;
  --taupe: #91785f;
  --taupe-dark: #6c543c;
  --glass: rgba(255,255,255,.67);
  --font-ui: 'Quicksand', 'Trebuchet MS', Arial, sans-serif;
  font-family: var(--font-ui);
  font-synthesis: none;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
}
* { box-sizing: border-box; }
html { min-height: 100%; background: var(--cream); }
body { margin: 0; min-width: 280px; min-height: 100vh; color: var(--ink); background: var(--cream); padding: 0; }
button, a { -webkit-tap-highlight-color: transparent; }
button { font: inherit; }
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible { outline: 3px solid #77512e; outline-offset: 3px; }
[hidden] { display: none !important; }
.svg-defs { width: 0; height: 0; position: absolute; overflow: hidden; }
.line-icon { display: block; width: 25px; height: 25px; fill: none; stroke: currentColor; stroke-width: 1.65; stroke-linecap: round; stroke-linejoin: round; flex-shrink: 0; }

.app-shell {
  position: relative;
  width: 100%;
  max-width: 480px;
  min-height: 100dvh;
  margin-inline: auto;
  overflow-x: clip;
  background: var(--cream);
  box-shadow: 0 16px 80px rgba(51, 35, 19, .13);
}
.content-area { position: relative; isolation: isolate; padding-bottom: calc(103px + env(safe-area-inset-bottom, 0px)); }

/* The photograph and its gradient are independent of the menu cards. */
.hero { height: clamp(330px, 46svh, 424px); position: relative; isolation: isolate; }
.hero__image { position: absolute; inset: 0; height: calc(100% + 30px); width: 100%; object-fit: cover; object-position: center 34%; z-index: -2; }
.hero__fade {
  position: absolute; inset: 0 0 -35px; z-index: -1;
  background: linear-gradient(to bottom,
    rgba(248,245,240,.02) 0%, rgba(248,245,240,.02) 26%,
    rgba(248,245,240,.23) 40%, rgba(248,245,240,.77) 67%,
    var(--cream) 94%, var(--cream) 100%);
}
.hero__topbar { position: absolute; top: calc(18px + env(safe-area-inset-top, 0px)); right: 19px; z-index: 4; }
.language-control { position: relative; }
.language-button {
  display: flex; align-items: center; justify-content: center; gap: 7px;
  height: 42px; min-width: 91px; padding: 0 12px;
  color: #352a20; border: 1px solid rgba(255,255,255,.85);
  border-radius: 999px; background: rgba(255,255,255,.73);
  box-shadow: 0 5px 18px rgba(61, 39, 16, .13);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  font-size: 13px; font-weight: 700; cursor: pointer;
}
.language-button .line-icon { width: 18px; height: 18px; }
.language-button .language-button__chevron { width: 13px; height: 13px; transform: rotate(90deg); }
.language-menu {
  position: absolute; top: 49px; right: 0; z-index: 9; width: 156px;
  padding: 6px; border-radius: 17px; background: rgba(255,255,255,.95);
  border: 1px solid #eee7dc; box-shadow: 0 13px 30px rgba(61, 39, 16, .19);
  backdrop-filter: blur(16px); -webkit-backdrop-filter: blur(16px);
}
.language-menu button { display: block; width: 100%; padding: 12px 10px; text-align: left; border: 0; border-radius: 11px; color: var(--ink); background: transparent; cursor: pointer; font-size: 13px; }
.language-menu button:hover, .language-menu button[aria-pressed="true"] { background: #f3ede3; }

.hero__branding { position: absolute; bottom: 11px; left: 0; width: 100%; padding: 0 20px; display: flex; flex-direction: column; align-items: center; }
.hero__logo { display: block; width: min(96%, 365px); height: auto; object-fit: contain; filter: drop-shadow(0 1px 0 rgba(255,255,255,.1)); }
.hero__tagline { margin: 4px 0 0; text-align: center; font-weight: 600; font-size: clamp(12px,3.0vw,14px); letter-spacing: .30em; line-height: 1.7; }
.hero__divider { display: block; width: 54px; height: 2px; margin: 16px 0 0; border-radius: 3px; background: #bea184; }

.menu-grid {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px; padding: 15px 15px 14px;
  background: radial-gradient(ellipse 80% 44% at -18% 16%, rgba(209,190,165,.12), transparent 75%),
              radial-gradient(ellipse 90% 54% at 107% 63%, rgba(209,190,165,.14), transparent 76%);
}
.menu-card {
  min-width: 0; min-height: 120px; position: relative;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 10px;
  padding: 16px 44px 16px 16px;
  border-radius: 25px;
  background: linear-gradient(140deg, rgba(255,255,255,.83), rgba(255,255,255,.55));
  border: 1px solid rgba(255,255,255,.97);
  box-shadow: 0 8px 25px rgba(102,75,47,.095), inset 0 1px 1px rgba(255,255,255,.96), 0 2px 2px rgba(151,117,82,.04);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  transition: transform .16s ease, box-shadow .16s ease, background .16s ease;
}
.menu-card:hover { transform: translateY(-2px); box-shadow: 0 13px 30px rgba(102,75,47,.16), inset 0 1px 1px white; background: rgba(255,255,255,.85); }
.menu-card:active { transform: scale(.975); box-shadow: 0 3px 14px rgba(102,75,47,.12); }
.menu-card__icon {
  width: 53px; height: 53px; display: flex; align-items: center; justify-content: center;
  color: var(--taupe-dark); background: #f0e5d7; border-radius: 50%;
}
.menu-card__icon .line-icon { width: 28px; height: 28px; stroke-width: 1.55; }
.menu-card__label { position: relative; z-index: 1; font-weight: 700; letter-spacing: -.015em; line-height: 1.22; font-size: clamp(12px, 3.55vw, 15px); overflow-wrap: break-word; text-align: center; max-width: 100%; }
.menu-card__chevron { position: absolute; top: 50%; right: 14px; transform: translateY(-50%); width: 18px; height: 18px; color: #6d5c4a; stroke-width: 1.6; }

.tabbar {
  position: fixed; z-index: 20; bottom: 0; left: 50%; transform: translateX(-50%);
  width: min(480px, 100%);
  display: grid; grid-template-columns: repeat(4, minmax(0, 1fr));
  min-height: calc(82px + env(safe-area-inset-bottom, 0px));
  padding: 10px 10px calc(8px + env(safe-area-inset-bottom, 0px));
  border: 1px solid rgba(242,234,224,.94); border-bottom: 0;
  border-radius: 33px 33px 0 0;
  background: rgba(255,255,255,.91);
  box-shadow: 0 -7px 26px rgba(82,61,40,.11);
  backdrop-filter: blur(22px); -webkit-backdrop-filter: blur(22px);
}
.tabbar__item { min-width: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 3px; border-radius: 19px; color: #554e45; }
.tabbar__icon { display: flex; align-items: center; justify-content: center; width: 66px; max-width: 92%; height: 35px; border-radius: 17px; transition: background .15s ease, color .15s ease; }
.tabbar__icon .line-icon { width: 25px; height: 25px; }
.tabbar__label { font-size: clamp(10px,2.9vw,12px); font-weight: 600; line-height: 1.2; white-space: nowrap; }
.tabbar__underline { height: 3px; width: 25px; border-radius: 99px; background: transparent; }
.tabbar__item.is-active { color: var(--taupe-dark); }
.tabbar__item.is-active .tabbar__icon { background: #f4ebdf; }
.tabbar__item.is-active .tabbar__underline { background: #b18f70; }
.tabbar__item:hover .tabbar__icon { background: #f5eee5; }
.tabbar__monogram { padding: 0; }
.tabbar__monogram-image { display: block; width: 38px; height: auto; object-fit: contain; filter: brightness(0); }

/* Transitions entre les pages : la barre inférieure reste fixe. */
/* Chaque écran possède son propre fond opaque : aucun contenu ne transparaît
   pendant le défilement. La barre du bas reste fixe. */
.view-home { background: var(--cream); }
.view.is-route-entering { position: relative; z-index: 3; }
.view.is-route-exiting {
  position: absolute; inset: 0 0 auto;
  width: 100%; z-index: 2; pointer-events: none;
}
.view.route-enter-forward { animation: mh-enter-right 380ms cubic-bezier(.22,.68,.22,1) both; }
.view.route-exit-forward { animation: mh-exit-left 380ms cubic-bezier(.22,.68,.22,1) both; }
.view.route-enter-back { z-index: 2; animation: mh-enter-left 380ms cubic-bezier(.22,.68,.22,1) both; }
.view.route-exit-back { z-index: 3; animation: mh-exit-right 380ms cubic-bezier(.22,.68,.22,1) both; }
/* Mouvement seulement : aucune réduction d'opacité, même entre deux écrans. */
@keyframes mh-enter-right { from { transform: translate3d(100%,0,0); } to { transform: translate3d(0,0,0); } }
@keyframes mh-exit-left { from { transform: translate3d(0,0,0); } to { transform: translate3d(-20%,0,0); } }
@keyframes mh-enter-left { from { transform: translate3d(-20%,0,0); } to { transform: translate3d(0,0,0); } }
@keyframes mh-exit-right { from { transform: translate3d(0,0,0); } to { transform: translate3d(100%,0,0); } }

/* This first prototype intentionally contains no fictitious apartment data.
   Secondary routes are functional placeholders, not completed pages. */
.view-detail { min-height: 100dvh; padding: 0 19px; background: var(--cream); }
.detail-header { display: flex; align-items: center; justify-content: space-between; padding: calc(17px + env(safe-area-inset-top, 0px)) 0 16px; border-bottom: 1px solid #eae2d8; }
.back-button { width: 46px; height: 46px; display: flex; align-items: center; justify-content: center; background: rgba(255,255,255,.78); border-radius: 16px; border: 1px solid #ebe2d7; }
.detail-header__brand { font-size: 11px; letter-spacing: .18em; font-weight: 700; color: var(--taupe-dark); }
.detail-header__spacer { width: 46px; }
.detail-content { display: flex; flex-direction: column; align-items: center; text-align: center; padding: clamp(65px,12vh,130px) 8px 30px; }
.detail-content__eyebrow { color: var(--muted); font-size: 11px; font-weight: 700; letter-spacing: .23em; }
.detail-content__symbol { display: flex; align-items: center; justify-content: center; width: 92px; height: 92px; margin-top: 27px; border-radius: 29px; background: #efe3d5; color: var(--taupe-dark); }
.detail-content__symbol .line-icon { width: 42px; height: 42px; }
.detail-content h1 { font-size: clamp(24px,7vw,31px); font-weight: 600; margin: 27px 0 6px; line-height: 1.3; }
.detail-content p { font-size: 15px; line-height: 1.7; max-width: 305px; color: #70645a; }
.detail-home-button { display: inline-flex; align-items: center; justify-content: center; margin-top: 25px; padding: 14px 22px; border-radius: 16px; background: #7f664d; color: white; font-size: 13px; font-weight: 700; }
.detail-home-button:active { transform: scale(.97); }

@media (min-width: 700px) {
  body { background: linear-gradient(120deg, #e8ddcd, #f8f5f0 40%, #eae0d2); }
  /* La photo démarre au bord supérieur, même dans l'aperçu PC. */
  .app-shell { margin-block: 0; min-height: 100dvh; border-radius: 0 0 28px 28px; overflow: hidden; }
  .tabbar { bottom: 0; border-radius: 29px 29px 0 0; }
  .content-area { padding-bottom: 110px; }
}
@media (max-width: 340px) {
  .hero { height: 327px; }
  .hero__branding { padding: 0 9px; }
  .hero__tagline { letter-spacing: .22em; }
  .menu-grid { padding-inline: 10px; gap: 9px; }
  .menu-card { padding: 14px 38px 14px 12px; min-height: 116px; border-radius: 20px; gap: 8px; }
  .menu-card__icon { width: 47px; height: 47px; }
  .menu-card__label { font-size: 12px; }
  .tabbar { padding-left: 2px; padding-right: 2px; }
}
@media (prefers-reduced-motion: reduce) {
  .view.is-route-entering, .view.is-route-exiting { animation: none !important; }
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
