@layer tokens, base, shell, modules, utilities, accessibility;
/* app/Modules/Auth/Views/login.php: component layout. Brand values are central. */
@layer modules {

    *, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
    body {
      font-family:var(--font-ui);
      color: var(--text); background: var(--paper);
      min-height: 100vh; display: grid; grid-template-columns: 1fr 1fr;
    }

    /* ── Left panel ── */
    .panel {
      background: var(--brand-primary);
      display: flex; flex-direction: column; justify-content: center;
      padding: 60px 56px; position: relative; overflow: hidden;
    }
    .panel::before {
      content: '';
      position: absolute; inset: 0;
      background-image: url('/img/landing/wohngemeinschaft.jpg');
      background-size: cover; background-position: center; opacity: .15;
    }
    .panel__inner { position: relative; }
    .panel__brand { display: flex; align-items: center; gap: 10px; margin-bottom: 52px; }
    .panel__brand img { width: 36px; height: 36px; border-radius:var(--radius-control); object-fit: cover; border: 2px solid color-mix(in srgb, var(--white) 25%, transparent); }
    .panel__brand span { font-weight: 700; font-size: 1.1rem; color: color-mix(in srgb, var(--white) 90%, transparent); letter-spacing: -.01em; }
    .panel h2 {
      font-family:var(--font-ui);
      font-size: clamp(1.7rem, 2.2vw, 2.3rem);
      font-weight: 700; color: var(--white);
      letter-spacing: -.03em; line-height: 1.2; margin-bottom: 18px;
    }
    .panel > .panel__inner > p { color: color-mix(in srgb, var(--white) 65%, transparent); line-height: 1.7; font-size: .95rem; max-width: 360px; margin-bottom: 36px; }
    .panel__points { list-style: none; display: flex; flex-direction: column; gap: 13px; }
    .panel__points li {
      display: flex; align-items: flex-start; gap: 10px;
      color: color-mix(in srgb, var(--white) 78%, transparent); font-size: .93rem; line-height: 1.5;
    }
    .panel__points li::before { content: '✓'; color: var(--brand-accent); font-weight: 700; flex-shrink: 0; margin-top: 1px; }

    /* ── Right: form ── */
    .form-area {
      display: flex; align-items: center; justify-content: center;
      padding: 52px 40px;
    }
    .form-box { width: min(100%, 420px); }

    .form-box h1 {
      font-family:var(--font-ui); font-size: 2rem;
      font-weight: 700; color: var(--text); letter-spacing: -.03em;
      margin-bottom: 6px;
    }
    .form-box > p { color: var(--muted); font-size: .93rem; line-height: 1.6; margin-bottom: 30px; }

    label { display: block; margin-bottom: 7px; font-weight: 700; font-size: .87rem; color: var(--brand-hover); }
    input[type="email"], input[type="password"] {
      width: 100%; min-height: 50px; padding: 0 16px;
      border-radius: var(--radius-control); border: 1.5px solid var(--line);
      background: var(--white); color: var(--text);
      font-family:inherit; font-size: 1rem; margin-bottom: 18px;
      transition: border-color .15s, box-shadow .15s;
    }
    input:focus { outline: none; border-color: var(--brand-hover); box-shadow: 0 0 0 3px color-mix(in srgb, var(--info-text) 10%, transparent); }

    .btn-submit {
      width: 100%; min-height: 52px; border: none; border-radius: var(--radius-control);
      background: var(--brand-primary); color: var(--white);
      font-family:inherit; font-size: 1rem; font-weight: 600;
      cursor: pointer; letter-spacing: -.01em;
      transition: background .15s, transform .15s;
    }
    .btn-submit:hover { background: var(--brand-hover); transform: translateY(-1px); }

    .error { margin-bottom: 20px; padding: 12px 16px; border-radius: var(--radius-control); background: var(--surface-subtle); border: 1px solid var(--danger-line); color: var(--danger); font-size: .9rem; }
    .notice { margin-bottom: 20px; padding: 12px 16px; border-radius: var(--radius-control); background: var(--brand-soft); border: 1px solid color-mix(in srgb, var(--info-text) 35%, transparent); color: var(--brand-primary); font-size: .9rem; }
    .hint-box { margin-bottom: 20px; padding: 12px 16px; border-radius: var(--radius-control); background: var(--accent-soft); border: 1px solid color-mix(in srgb, var(--brand-accent) 30%, transparent); color: var(--warning-text); font-size: .9rem; }

    .divider { border: none; border-top: 1px solid var(--line); margin: 26px 0; }
    .meta { color: var(--muted); font-size: .9rem; text-align: center; }
    .meta a { color: var(--brand-primary); font-weight: 600; text-decoration: none; }
    .meta a:hover { text-decoration: underline; }

    @media (max-width: 820px) {
      body { grid-template-columns: 1fr; }
      .panel { display: none; }
      .form-area { min-height: 100vh; }
    }
}
