/* Public site (views/home.php), loaded after styles.css */

.home { font-size: var(--font-size-md); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
.home-wrap { max-width: 1040px; margin: 0 auto; padding: 0 var(--space-6); }
.home a.btn-primary { text-decoration: none; text-align: center; white-space: nowrap; }
.home-link { color: var(--color-gray-900); }
.home a:focus-visible { outline: 2px solid var(--color-blue); outline-offset: 2px; }

/* Header */
.home-header { display: flex; align-items: center; justify-content: space-between; padding: var(--space-4) 0; }
.home-brand { display: flex; align-items: center; gap: var(--space-2); font-size: var(--font-size-xl); line-height: var(--line-height-tight); font-weight: var(--font-weight-bold); color: inherit; text-decoration: none; }
.home-nav { display: flex; align-items: baseline; gap: var(--space-6); font-size: var(--font-size-base); }
.home-nav > a.home-link:hover { color: var(--color-black); }

/* Hero */
.home-hero { padding: var(--space-12) 0 var(--space-8); max-width: 34em; }
.home-hero h1 { font-size: var(--font-size-xl); line-height: var(--line-height-snug); font-weight: var(--font-weight-bold); text-wrap: balance; }
.home-lead { color: var(--color-gray-900); margin: var(--space-3) 0 var(--space-6); }
.home-cta { display: flex; align-items: center; gap: var(--space-4); flex-wrap: wrap; }
.home-cta small { color: var(--color-gray-900); font-size: var(--font-size-base); }

/* Hero shots, real captures of the vote page (poll DEMO8, guest view), from design/mockups/site-sobre.html:
   assets/img/safari-window-{fr,en}.png, a 1100 x 690 Safari window at 2x with transparent 18 px corners so
   drop-shadow follows them; assets/img/vote-iphone-{fr,en}.png, the page at 402 x 715, 3x, between the iOS
   status bar and Safari bar, inside Apple's iPhone 17 Black frame (glass transparent).
   Every size is in cqw of .home-shots-stage, so the composition scales as one picture. */
.home-shots { margin: 0 calc(-1 * clamp(0px, (100vw - 1040px) / 2, 104px)); }
.home-shots-stage { container-type: inline-size; padding: var(--space-8) 0 var(--space-12); }
.home-shots-canvas { position: relative; height: 59cqw; }
.home-shot-desktop { position: absolute; left: 0; top: 0; width: 88cqw; }
.home-shot-desktop img {
  display: block; width: 100%; height: auto;
  filter:
    drop-shadow(0 0 0.5px rgba(0, 0, 0, 0.35))
    drop-shadow(0 2px 3px rgba(0, 0, 0, 0.05))
    drop-shadow(0 14px 28px rgba(0, 0, 0, 0.08))
    drop-shadow(0 40px 64px rgba(0, 0, 0, 0.12));
}
.home-shot-phone {
  container-type: inline-size; position: absolute; z-index: 1; right: 0; bottom: 0; width: 23cqw;
  filter: drop-shadow(0 12px 18px rgba(0, 0, 0, 0.14)) drop-shadow(0 32px 48px rgba(0, 0, 0, 0.18));
}
.home-phone-frame { position: relative; display: block; width: 100%; height: auto; pointer-events: none; }
/* Glass area of the frame image (938 x 2040 px of 1050 x 2147) */
.home-phone-screen {
  position: absolute; left: 5.3333%; top: 2.5%; width: 89.3333%; height: 95%;
  overflow: hidden; border-radius: 11.11cqw; background: var(--color-white);
}
.home-phone-screen img { display: block; width: 100%; height: auto; }

/* Strengths: 2 columns, rows split by a hairline like the app's lists */
.home-points { list-style: none; display: grid; grid-template-columns: 1fr 1fr; column-gap: var(--space-12); margin-top: var(--space-12); }
.home-points li { border-top: 1px solid var(--color-border); padding: var(--space-4) 0 var(--space-6); }
.home-points b { display: block; font-weight: var(--font-weight-bold); }
.home-points p { color: var(--color-gray-900); font-size: var(--font-size-base); margin-top: var(--space-1); }

.home-again { text-align: center; padding: var(--space-8) 0 var(--space-20); }

/* Footer */
.home-footer { border-top: 1px solid var(--color-border); padding: 20px 0 28px; color: var(--color-gray-900); font-size: var(--font-size-base); }
.home-footer nav { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px 20px; }
.home-footer nav > div { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.home-footer a { color: inherit; white-space: nowrap; }
.home-footer-brand { margin-top: var(--space-3); }

/* Legal notice, privacy, contact (views/page.php) */
.site-page { max-width: 720px; padding: 40px 0 72px; }
.site-page h1 { font-size: 34px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.15; margin-bottom: 20px; }
.site-page h2 { font-size: var(--font-size-lg); font-weight: 500; margin: 32px 0 8px; }
.site-page p, .site-page li { color: var(--color-gray-900); line-height: 1.6; }
.site-page p + p { margin-top: 10px; }
.site-page ul { padding-left: 20px; display: grid; gap: 6px; margin-top: 8px; }
.site-page b { color: var(--color-black); font-weight: 500; }
.site-page a { color: var(--color-black); }
.site-meta { font-size: var(--font-size-base); margin: -12px 0 24px; }
.site-notice { margin-top: 20px; padding: 12px 16px; border: 1px solid var(--color-border); border-radius: var(--radius-sm); }
.site-error { border-color: #d33; color: #b00 !important; }
.contact-form { display: grid; gap: 4px; margin-top: 28px; max-width: 480px; }
.contact-form label { font-size: var(--font-size-base); font-weight: 500; }
.contact-form .login-input { display: block; margin: 6px 0 12px; }
.contact-form textarea.login-input { height: auto; padding: 10px 12px; resize: vertical; line-height: 1.5; }
.contact-form button { justify-self: start; }
.contact-form small { color: var(--color-gray-900); font-size: 13px; margin-top: 8px; }
.contact-hp { position: absolute; left: -9999px; }

@media (max-width: 800px) {
  .site-page { padding: 24px 0 48px; }
  .site-page h1 { font-size: 28px; }
}

@media (max-width: 820px) {
  .home-wrap { padding: 0 var(--space-4); }
  .home main { max-width: 415px; margin: 0 auto; }
  .home-hero { padding: var(--space-6) 0 var(--space-8); }
  .home-nav-login { display: none; }
  /* Phones only get the phone, large enough to read: the visitor's own phone is the other device */
  .home-shots { margin: 0; }
  .home-shots-stage { padding: var(--space-4) 0 var(--space-8); }
  .home-shots-canvas { height: auto; }
  .home-shot-desktop { display: none; }
  .home-shot-phone { position: relative; right: auto; bottom: auto; margin: 0 auto; width: 80cqw; }
  .home-points { grid-template-columns: minmax(0, 1fr); margin-top: var(--space-8); }
  .home-points li { padding-bottom: var(--space-4); }
  .home-again { padding: var(--space-6) 0 var(--space-12); }
  .home-again .btn-primary { display: flex; }
  /* Phones: large touch buttons; desktop keeps the standard black button */
  .home-btn-lg { display: inline-flex; align-items: center; justify-content: center; height: var(--control-height-lg); padding: 0 var(--space-6); font-size: var(--font-size-md); }
}

/* Phone footer: account links on the left, legal pages on the right, signature below */
@media (max-width: 600px) {
  .home-footer { padding: var(--space-3) 0 var(--space-6); }
  .home-footer nav { display: grid; grid-template-columns: 1fr 1fr; gap: 0 var(--space-6); align-items: start; }
  .home-footer nav > div { display: block; }
  .home-footer a { display: flex; align-items: center; min-height: 40px; }
  .home-footer-account a { color: var(--color-black); }
  .home-footer-brand { padding-top: var(--space-4); border-top: 1px solid var(--color-border); }
}
