/* The tagline is the page's <h1> (what search engines read as the topic);
   "Sign in" is an <h2> styled exactly as the old <h1> was. */
h1.auth-headline { margin: 0; }
.auth-main .auth-title {
  font-size: 1.5rem; font-weight: 600; letter-spacing: -.01em;
  color: #0E131A; margin: 0 0 5px;
}
@media (max-width: 520px) { .auth-main .auth-title { font-size: 1.35rem; } }

/* =====================================================================
   PRODUCT OVERVIEW under the sign-in sheet (login.php / home page)
   ---------------------------------------------------------------------
   Same light sheets as the sign-in card, floating on the fixed harvest
   footage. The palette is re-declared locally for the same reason the
   sign-in sheet does it: the page sits on a bright field in either theme.
   ===================================================================== */

.auth-more-link {
  margin-left: auto; font-weight: 600; font-size: .78rem; white-space: nowrap;
  color: #0A2A20; text-decoration: underline; text-underline-offset: 2px;
}
.auth-more-link:hover { color: #047857; }

.landing {
  position: relative; z-index: 1;
  width: min(1080px, 100%); margin: 0 auto; padding: 8px 20px 56px;
  display: flex; flex-direction: column; gap: 18px;
}

.landing-sheet,
.landing-foot {
  --surface: #FFFFFF;
  --surface-2: #F5F8F6;
  --line: #E3E9E5;
  --text: #131720;
  --muted: #4B5563;
  --accent: #047857;
  --accent-dim: #059669;
  --accent-glow: rgba(4, 120, 87, .10);
  --on-accent: #FFFFFF;
  color-scheme: light;
  color: var(--text);
}

.landing-sheet {
  background: rgba(255, 255, 255, .96);
  border-radius: 18px;
  box-shadow: 0 30px 90px rgba(4, 16, 11, .45);
  padding: 40px 38px;
}

.landing-eyebrow {
  font-size: .66rem; letter-spacing: .2em; text-transform: uppercase;
  color: var(--accent); font-weight: 700; margin-bottom: 10px;
}
.landing h2 {
  font-size: clamp(1.4rem, 2.6vw, 1.85rem); line-height: 1.2; font-weight: 650;
  letter-spacing: -.02em; color: var(--text); margin: 0 0 12px; max-width: 30ch;
}
.landing-intro { color: var(--muted); font-size: .95rem; line-height: 1.65; max-width: 68ch; margin: 0 0 26px; }

.landing-grid {
  list-style: none; margin: 0; padding: 0;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px;
}
.landing-grid li {
  background: linear-gradient(165deg, var(--accent-glow), transparent 60%), var(--surface-2);
  border: 1px solid var(--line); border-radius: 13px; padding: 18px;
}
.landing-grid .ico { color: var(--accent); }
.landing-grid h3 { font-size: .95rem; font-weight: 650; margin: 10px 0 5px; color: var(--text); }
.landing-grid p { font-size: .84rem; line-height: 1.55; color: var(--muted); margin: 0; }

.landing-split { display: grid; grid-template-columns: 1fr 1.1fr; gap: 36px; align-items: start; }
.landing-split .landing-intro { margin-bottom: 0; }
.landing-ticks { list-style: none; margin: 0; padding: 0; display: grid; gap: 14px; }
.landing-ticks li { display: flex; gap: 11px; font-size: .9rem; line-height: 1.6; color: var(--muted); }
.landing-ticks .ico { color: var(--accent); margin-top: 4px; }
.landing-ticks strong { color: var(--text); font-weight: 650; }

.landing-faq details { border-bottom: 1px solid var(--line); padding: 15px 0; }
.landing-faq details:first-of-type { border-top: 1px solid var(--line); }
.landing-faq summary {
  cursor: pointer; list-style: none; font-weight: 650; font-size: .98rem; color: var(--text);
  display: flex; justify-content: space-between; gap: 14px;
}
.landing-faq summary::-webkit-details-marker { display: none; }
.landing-faq summary::after { content: "+"; color: var(--accent); font-size: 1.3rem; line-height: 1; font-weight: 400; }
.landing-faq details[open] summary::after { content: "\2212"; }
.landing-faq summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; border-radius: 4px; }
.landing-faq details p { margin: 9px 0 0; color: var(--muted); font-size: .9rem; line-height: 1.65; max-width: 72ch; }

.landing-cta { text-align: center; }
.landing-cta h2, .landing-cta .landing-intro { margin-left: auto; margin-right: auto; }
.landing-cta-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.landing-cta .btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 22px; font-size: .92rem; text-decoration: none; }
:root .landing .btn:hover { background: var(--accent-dim); color: var(--on-accent); }
.landing .btn-ghost-light { background: transparent; color: var(--text); border-color: #9AA5A0; }
:root .landing .btn-ghost-light:hover { background: var(--surface-2); color: var(--text); border-color: var(--accent); }

.landing-foot {
  display: flex; justify-content: space-between; gap: 14px; flex-wrap: wrap;
  padding: 14px 6px 0; font-size: .82rem; color: rgba(255, 255, 255, .86);
}
.landing-foot a { color: #FFFFFF; text-decoration: none; }
.landing-foot a:hover { text-decoration: underline; }
.landing-foot nav { display: flex; gap: 16px; flex-wrap: wrap; }

@media (max-width: 860px) {
  .landing { width: min(500px, 100%); }
  .landing-grid { grid-template-columns: 1fr 1fr; }
  .landing-split { grid-template-columns: 1fr; gap: 22px; }
  .landing-sheet { padding: 28px 24px; }
  .auth-more-link { margin-left: 0; }
  .auth-region { flex-wrap: wrap; }
}
@media (max-width: 520px) {
  .landing { padding: 4px 20px 40px; }
  .landing-grid { grid-template-columns: 1fr; }
  .landing-sheet { padding: 24px 20px; border-radius: 16px; }
}

/* =====================================================================
   PAGE FLIP: sign-in screen → product pages (ported from School ERP)
   ---------------------------------------------------------------------
   With JavaScript on, the sign-in screen is a page of its own. The
   "Explore" button flips it up like a calendar page and the product
   sheets rise underneath as a separate vertical scroll, over the same
   harvest footage. Without JavaScript the page scrolls as before.
   The gradient is the farm's greens; swap these four for the Luzor
   blue→violet→magenta (#29b6f6, #7e6cf0, #c94bd8) to match School ERP.
   ===================================================================== */
.home-flip {
  --fx-1: #a3e635;
  --fx-2: #10b981;
  --fx-3: #047857;
  --fx-glow: 16, 185, 129;        /* rgb of --fx-2, for the glows */
}

/* The footage now lives outside the sign-in wrapper, so the wrapper
   must not paint its own dark backdrop over it. */
.home-flip .auth-wrap.has-video { background: transparent; overflow: visible; }

.flip-ready, .flip-ready body.home-flip { height: 100%; overflow: hidden; }
.flip-ready .flip-front,
.flip-ready .flip-back {
  position: fixed; inset: 0;
  overflow-y: auto; overflow-x: hidden;
  -webkit-overflow-scrolling: touch;
  overscroll-behavior: contain;
}
.flip-ready .flip-front {
  z-index: 3;
  display: flex; flex-direction: column;
  transform-origin: 50% 0%;
  transform: perspective(2400px) rotateX(0deg);
  transition: transform 1s cubic-bezier(.62,.04,.28,1), opacity .6s ease .35s, visibility 0s linear 0s;
  will-change: transform;
}
.flip-ready .flip-front .auth-wrap { min-height: 0; flex: 1 0 auto; padding-bottom: 8px; }
.flip-ready .flip-front::after {           /* page shading while it turns */
  content: ""; position: fixed; inset: 0; pointer-events: none;
  background: linear-gradient(180deg, rgba(4,16,11,0) 0%, rgba(4,16,11,.55) 100%);
  opacity: 0; transition: opacity .9s ease;
}
body.is-flipped .flip-front {
  transform: perspective(2400px) rotateX(88deg);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: transform 1s cubic-bezier(.62,.04,.28,1), opacity .45s ease .5s, visibility 0s linear 1s;
}
body.is-flipped .flip-front::after { opacity: 1; }

.flip-ready .flip-back {
  z-index: 2;
  background: linear-gradient(180deg, rgba(4,16,11,.22), rgba(4,16,11,.10) 40%, rgba(4,16,11,.30));
  transform-origin: 50% 100%;
  transform: perspective(2400px) translateY(60px) scale(.93);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: transform .9s cubic-bezier(.16,1,.3,1), opacity .5s ease, visibility 0s linear .9s;
}
body.is-flipped .flip-back {
  transform: none; opacity: 1; visibility: visible; pointer-events: auto;
  transition: transform 1.05s cubic-bezier(.16,1,.3,1) .28s, opacity .6s ease .28s, visibility 0s linear 0s;
}
.flip-ready.flip-instant .flip-front, .flip-ready.flip-instant .flip-back,
.flip-ready.flip-instant .flip-front::after { transition: none !important; }

.flip-ready .flip-back .landing { padding-top: 22px; }
/* the browser's own jump to #features / #faq clears the sticky bar too */
.flip-ready .flip-back .landing-sheet { scroll-margin-top: 76px; }

/* ---------- the Explore arrow under the sign-in sheet ---------- */
.explore-dock { display: none; }
.flip-ready .explore-dock {
  display: flex; justify-content: center;
  position: relative; z-index: 4;
  padding: 6px 16px 26px;
}
.explore-btn {
  --ring: conic-gradient(from var(--spin, 0deg), var(--fx-1), var(--fx-2), var(--fx-3), var(--fx-1));
  position: relative;
  display: inline-flex; align-items: center; gap: 14px;
  padding: 8px 8px 8px 22px;
  border: 0; border-radius: 999px; cursor: pointer;
  font: 600 13px/1 'Inter', 'Segoe UI', sans-serif; letter-spacing: .12em; text-transform: uppercase;
  color: #131720;
  background: rgba(255, 255, 255, .84);
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 10px 34px rgba(4, 16, 11, .40), inset 0 0 0 1px rgba(255, 255, 255, .6);
  animation: explore-pop .9s cubic-bezier(.34,1.56,.64,1) 1.1s backwards;
  transition: transform .35s cubic-bezier(.16,1,.3,1), box-shadow .35s cubic-bezier(.16,1,.3,1);
}
.explore-btn::before {                     /* animated gradient rim */
  content: ""; position: absolute; inset: -1.5px; border-radius: inherit; padding: 1.5px;
  background: var(--ring);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: .9; animation: explore-spin 6s linear infinite;
}
.explore-btn:hover { transform: translateY(-3px); box-shadow: 0 16px 44px rgba(4, 16, 11, .50), inset 0 0 0 1px #fff; }
.explore-btn:active { transform: translateY(0) scale(.98); }
.explore-btn:focus-visible { outline: 2px solid #fff; outline-offset: 4px; }
.explore-label { white-space: nowrap; text-align: left; }
.explore-label small { display: block; margin-top: 5px; font-size: 10.5px; font-weight: 500; letter-spacing: .04em;
                       text-transform: none; color: #4B5563; }
.explore-orb {
  position: relative; width: 46px; height: 46px; border-radius: 50%;
  display: grid; place-items: center; flex: none;
  background: linear-gradient(135deg, var(--fx-2), #059669 55%, var(--fx-3));
  box-shadow: 0 6px 18px rgba(var(--fx-glow), .45);
  overflow: visible;
}
.explore-orb::after {                      /* soft sonar pulse */
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  box-shadow: 0 0 0 0 rgba(var(--fx-glow), .55);
  animation: explore-pulse 2.4s ease-out 2s infinite;
}
.explore-orb svg { width: 20px; height: 20px; color: #fff; overflow: visible; }
.explore-orb .c1 { animation: chev 1.6s cubic-bezier(.45,0,.55,1) infinite; }
.explore-orb .c2 { animation: chev 1.6s cubic-bezier(.45,0,.55,1) .18s infinite; }
.explore-btn:hover .explore-orb .c1, .explore-btn:hover .explore-orb .c2 { animation-duration: 1s; }
@property --spin { syntax: '<angle>'; inherits: false; initial-value: 0deg; }
@keyframes explore-spin { to { --spin: 360deg; } }
@keyframes explore-pop {
  0%   { opacity: 0; transform: translateY(-18px) scale(.7); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes explore-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(var(--fx-glow), .5); }
  80%, 100% { box-shadow: 0 0 0 16px rgba(var(--fx-glow), 0); }
}
@keyframes chev {
  0%   { transform: translateY(-5px); opacity: 0; }
  35%  { opacity: 1; }
  70%  { transform: translateY(4px); opacity: 1; }
  100% { transform: translateY(8px); opacity: 0; }
}

/* ---------- top bar on the product pages ---------- */
.back-bar { display: none; }
.flip-ready .back-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  position: sticky; top: 0; z-index: 5;
  height: 60px; padding: 0 28px;
  background: rgba(255, 255, 255, .82);
  backdrop-filter: blur(14px) saturate(160%); -webkit-backdrop-filter: blur(14px) saturate(160%);
  border-bottom: 1px solid rgba(4, 16, 11, .10);
  box-shadow: 0 8px 30px rgba(4, 16, 11, .18);
}
.back-brand {
  display: inline-flex; align-items: center; gap: 10px;
  font-weight: 700; font-size: 14px; letter-spacing: -.01em; color: #131720; text-decoration: none;
}
.back-brand .mark {
  width: 30px; height: 30px; border-radius: 9px; display: grid; place-items: center;
  color: #047857; background: rgba(4, 120, 87, .10); border: 1px solid #047857;
}
.back-brand .sub {
  font-size: 10.5px; font-weight: 700; letter-spacing: .2em; text-transform: uppercase; color: #047857;
}
.back-btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 9px 16px 9px 12px; border-radius: 999px; cursor: pointer;
  font: 600 13px/1 'Inter', 'Segoe UI', sans-serif; color: #fff;
  background: linear-gradient(135deg, var(--fx-2), #059669 55%, var(--fx-3)); border: 0;
  box-shadow: 0 6px 18px rgba(var(--fx-glow), .35);
  transition: transform .25s cubic-bezier(.16,1,.3,1), box-shadow .25s cubic-bezier(.16,1,.3,1);
}
.back-btn svg { width: 16px; height: 16px; }
.back-btn:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(var(--fx-glow), .45); }
.back-btn:focus-visible { outline: 2px solid #047857; outline-offset: 3px; }
.back-progress { position: absolute; left: 0; bottom: -1px; height: 2px; width: 100%;
                 transform-origin: 0 50%; transform: scaleX(0);
                 background: linear-gradient(90deg, var(--fx-1), var(--fx-2), var(--fx-3)); }

/* product sheets rise in as they scroll into view */
.flip-ready .flip-back .landing-sheet { opacity: 0; transform: translateY(26px);
  transition: opacity .8s cubic-bezier(.16,1,.3,1), transform .8s cubic-bezier(.16,1,.3,1); }
.flip-ready .flip-back .landing-sheet.in { opacity: 1; transform: none; }

/* ---------- the badge on the sign-in panel ---------- */
.auth-aside .pill.comply {
  align-self: flex-start;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 14px 6px 10px; margin: -6px 0 -8px;
  font-size: 12.5px; font-weight: 600; letter-spacing: .03em; color: #131720;
  border-radius: 999px;
  background: linear-gradient(#fff, #fff) padding-box,
              linear-gradient(90deg, var(--fx-1), var(--fx-2), var(--fx-3)) border-box;
  border: 1px solid transparent;
  box-shadow: 0 4px 16px rgba(var(--fx-glow), .22);
}
.pill.comply svg { width: 15px; height: 15px; flex: none; }
.pill.comply .sep { width: 1px; height: 12px; background: #CBD5D0; }
.pill.comply .std { background: linear-gradient(90deg, #0d9488, #15803d); -webkit-background-clip: text;
                    background-clip: text; color: transparent; font-weight: 700; }

@media (max-width: 560px) {
  .flip-ready .back-bar { padding: 0 14px; }
  .back-brand .sub { display: none; }
  .explore-btn { padding-left: 18px; gap: 12px; }
  .auth-aside .pill.comply { font-size: 11.5px; gap: 6px; padding: 5px 11px 5px 8px; }
}
@media (prefers-reduced-motion: reduce) {
  .flip-ready .flip-back .landing-sheet { opacity: 1; transform: none; }
}

/* ---------- eye button on the password field ---------- */
.pw-field { position: relative; }
.auth-main .pw-field input { padding-right: 46px; }
/* Edge's built-in reveal button would make a second eye */
.pw-field input::-ms-reveal, .pw-field input::-ms-clear { display: none; }
.pw-toggle {
  position: absolute; top: 50%; right: 6px; transform: translateY(-50%);
  width: 36px; height: 36px; border-radius: 8px; border: 0; padding: 0;
  display: grid; place-items: center; cursor: pointer;
  background: transparent; color: #4B5563;
  transition: color .2s ease, background-color .2s ease;
}
.pw-toggle:hover { color: #047857; background: rgba(4, 120, 87, .08); }
.pw-toggle:focus-visible { outline: 2px solid #047857; outline-offset: 1px; }
.pw-toggle svg { width: 19px; height: 19px; }
.pw-toggle .eye-shut { display: none; }
.pw-toggle[aria-pressed="true"] .eye-open { display: none; }
.pw-toggle[aria-pressed="true"] .eye-shut { display: block; }

/* ---------- "Luzor AI" in the headline: glowing farm greens ----------
   Same motion as School ERP (a slow colour sweep, a 2.4s pulse and a
   halo that breathes with it), in the farm's own greens. The headline is
   its own stacking layer so the halo sits above the panel, behind the words. */
h1.auth-headline { position: relative; z-index: 0; }
.auth-headline .ai-glow {
  position: relative; display: inline-block; white-space: nowrap;
  padding: 0 .04em;
  background: linear-gradient(90deg, #047857, #10b981, #65a30d, #10b981, #047857);
  background-size: 200% 100%;
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
  font-weight: 700;
  animation: ai-sweep 6s linear infinite, ai-glow 2.4s ease-out 2s infinite;
}
.auth-headline .ai-glow::after {            /* soft halo behind the words */
  content: ""; position: absolute; inset: 8% -10% 0; z-index: -1; border-radius: 999px;
  background: radial-gradient(closest-side, rgba(16,185,129,.42), rgba(163,230,53,.16) 62%, transparent);
  filter: blur(12px); opacity: .35;
  animation: ai-halo 2.4s ease-out 2s infinite;
  pointer-events: none;
}
@keyframes ai-sweep { to { background-position: -200% 0; } }
@keyframes ai-glow {
  0%   { filter: drop-shadow(0 0 0 rgba(16,185,129,0)); }
  25%  { filter: drop-shadow(0 0 8px rgba(16,185,129,.65)) drop-shadow(0 0 20px rgba(101,163,13,.35)); }
  80%, 100% { filter: drop-shadow(0 0 0 rgba(16,185,129,0)); }
}
@keyframes ai-halo {
  0%   { opacity: .35; transform: scale(.9); }
  25%  { opacity: 1; transform: scale(1.02); }
  80%, 100% { opacity: .35; transform: scale(1.12); }
}
@media (prefers-reduced-motion: reduce) {
  .auth-headline .ai-glow { background-position: 0 0; filter: none; }
}
