/* Deed7 — public auth & landing pages */

.deed7-public .theme-toggle-wrap,
.deed7-auth-page .theme-toggle-wrap {
  display: none !important;
}

.deed7-public {
  display: block;
  min-height: 100vh;
}

.deed7-auth-page {
  display: block;
}

.deed7-text-logo {
  display: inline-block;
  font-size: 1.65rem;
  font-weight: 800;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--brand-grad-start) 0%, var(--brand-grad-mid) 42%, var(--brand-grad-end) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.deed7-site-header {
  position: sticky;
  top: 0;
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 16px clamp(20px, 4vw, 48px);
  border-bottom: 1px solid var(--border);
  background: rgba(10, 14, 20, 0.82);
  backdrop-filter: blur(12px);
}

[data-theme="light"] .deed7-site-header {
  background: rgba(248, 250, 252, 0.9);
}

.deed7-site-header__brand {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: inherit;
}

.deed7-site-header__brand img,
.deed7-site-header__brand .deed7-text-logo {
  max-width: 140px;
  height: auto;
  max-height: 40px;
  object-fit: contain;
}

.deed7-site-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px 18px;
}

.deed7-site-nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: color var(--transition);
}

.deed7-site-nav a:hover,
.deed7-site-nav a.active {
  color: var(--accent);
}

.deed7-header-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.deed7-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  border: 1px solid transparent;
  transition: background var(--transition), border-color var(--transition), color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.deed7-btn:active {
  transform: translateY(1px);
}

.deed7-btn:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  transform: none;
}

.deed7-btn--ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text);
}

.deed7-btn--ghost:hover:not(:disabled) {
  background: var(--hover-overlay);
  border-color: var(--accent);
  color: var(--accent);
}

.deed7-btn--primary {
  background: linear-gradient(135deg, rgba(0, 224, 255, 0.22) 0%, rgba(0, 160, 200, 0.35) 100%);
  border-color: rgba(0, 224, 255, 0.45);
  color: var(--text);
  box-shadow: 0 4px 20px var(--accent-glow);
}

.deed7-btn--primary:hover:not(:disabled) {
  background: linear-gradient(135deg, rgba(0, 224, 255, 0.32) 0%, rgba(0, 160, 200, 0.45) 100%);
  border-color: var(--accent);
}

.deed7-btn--sm {
  padding: 8px 14px;
  font-size: 13px;
}

.deed7-hero {
  max-width: 1120px;
  margin: 0 auto;
  padding: clamp(48px, 8vw, 96px) clamp(20px, 4vw, 48px) 56px;
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: clamp(32px, 5vw, 64px);
  align-items: center;
}

.deed7-hero__logo {
  display: block;
  width: min(220px, 72vw);
  max-width: 100%;
  height: auto;
  margin: 0 0 20px;
  object-fit: contain;
}

.deed7-hero h1 {
  margin: 0 0 18px;
  font-size: clamp(2rem, 4.5vw, 3.15rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--text) 0%, var(--accent) 55%, var(--brand-grad-end) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.deed7-hero__sub {
  margin: 0 0 28px;
  max-width: 560px;
  color: var(--text-muted);
  font-size: clamp(1rem, 2vw, 1.125rem);
  line-height: 1.65;
}

.deed7-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-bottom: 20px;
}

.deed7-hero__trust {
  margin: 0;
  font-size: 13px;
  color: var(--text-dim);
}

.deed7-preview-card {
  background: linear-gradient(165deg, var(--bg-card) 0%, rgba(22, 31, 46, 0.92) 100%);
  border: 1px solid var(--border-strong);
  border-radius: calc(var(--radius) + 4px);
  padding: 24px;
  box-shadow: var(--shadow);
  position: relative;
  overflow: hidden;
}

.deed7-preview-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 100% 0%, rgba(0, 224, 255, 0.12), transparent 55%);
  pointer-events: none;
}

.deed7-preview-card__label {
  margin: 0 0 18px;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.deed7-preview-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  position: relative;
}

.deed7-preview-stat {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px 16px;
}

.deed7-preview-stat span {
  display: block;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-dim);
  margin-bottom: 6px;
}

.deed7-preview-stat strong {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--accent);
}

.deed7-section {
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 clamp(20px, 4vw, 48px) 64px;
}

.deed7-section__title {
  margin: 0 0 10px;
  font-size: 1.65rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.deed7-section__sub {
  margin: 0 0 28px;
  color: var(--text-muted);
  max-width: 720px;
}

.deed7-feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 18px;
}

.deed7-feature-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  box-shadow: var(--shadow-sm);
  transition: border-color var(--transition), transform var(--transition), box-shadow var(--transition);
}

.deed7-feature-card:hover {
  border-color: rgba(0, 224, 255, 0.35);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

.deed7-feature-card h3 {
  margin: 0 0 10px;
  font-size: 1.05rem;
  color: var(--text);
}

.deed7-feature-card p {
  margin: 0;
  font-size: 14px;
  color: var(--text-muted);
  line-height: 1.55;
}

.deed7-operator-panel {
  background: linear-gradient(135deg, rgba(0, 224, 255, 0.08) 0%, rgba(22, 31, 46, 0.95) 100%);
  border: 1px solid rgba(0, 224, 255, 0.22);
  border-radius: calc(var(--radius) + 2px);
  padding: clamp(24px, 4vw, 36px);
  box-shadow: var(--shadow-sm);
}

.deed7-operator-panel h2 {
  margin: 0 0 12px;
  font-size: 1.4rem;
}

.deed7-operator-panel p {
  margin: 0;
  color: var(--text-muted);
  line-height: 1.65;
  max-width: 820px;
}

.deed7-portal-hero {
  max-width: 920px;
  margin: 0 auto;
  padding: clamp(56px, 10vw, 112px) clamp(20px, 4vw, 48px) 72px;
  text-align: center;
}

.deed7-portal-hero h1 {
  margin: 0 0 14px;
  font-size: clamp(2rem, 4.5vw, 2.75rem);
  font-weight: 800;
  line-height: 1.12;
  letter-spacing: -0.03em;
  background: linear-gradient(135deg, var(--text) 0%, var(--accent) 55%, var(--brand-grad-end) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.deed7-portal-hero .deed7-hero__logo {
  margin: 0 auto 24px;
}

.deed7-portal-hero__sub {
  margin: 0 auto 36px;
  max-width: 520px;
  color: var(--text-muted);
  font-size: clamp(1rem, 2vw, 1.125rem);
  line-height: 1.65;
}

.deed7-portal-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  text-align: left;
}

.deed7-portal-card {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-height: 100%;
  padding: clamp(22px, 3vw, 28px);
  border-radius: calc(var(--radius) + 2px);
  border: 1px solid var(--border-strong);
  background: linear-gradient(165deg, var(--bg-card) 0%, rgba(22, 31, 46, 0.92) 100%);
  box-shadow: var(--shadow-sm);
  text-decoration: none;
  color: inherit;
  transition: border-color var(--transition), box-shadow var(--transition), transform var(--transition);
}

.deed7-portal-card:hover {
  border-color: rgba(0, 224, 255, 0.45);
  box-shadow: 0 10px 32px rgba(0, 224, 255, 0.12);
  transform: translateY(-2px);
}

.deed7-portal-card--tenant:hover {
  border-color: rgba(106, 240, 196, 0.45);
  box-shadow: 0 10px 32px rgba(106, 240, 196, 0.1);
}

.deed7-portal-card__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  background: rgba(0, 224, 255, 0.12);
  border: 1px solid rgba(0, 224, 255, 0.25);
  color: var(--accent);
}

.deed7-portal-card--tenant .deed7-portal-card__icon {
  background: rgba(106, 240, 196, 0.1);
  border-color: rgba(106, 240, 196, 0.28);
  color: #6af0c4;
}

.deed7-portal-card h2 {
  margin: 4px 0 0;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.deed7-portal-card p {
  margin: 0;
  flex: 1;
  color: var(--text-muted);
  font-size: 0.95rem;
  line-height: 1.6;
}

.deed7-portal-card__cta {
  margin-top: 8px;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--accent);
}

.deed7-portal-card--tenant .deed7-portal-card__cta {
  color: #6af0c4;
}

.deed7-auth-actions--split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.deed7-tenant-signed-in {
  text-align: center;
  padding: 8px 0 4px;
}

.deed7-tenant-signed-in__title {
  margin: 0 0 8px;
  font-size: 1.1rem;
  font-weight: 700;
}

.deed7-tenant-signed-in__sub {
  margin: 0 0 20px;
  color: var(--text-muted);
  font-size: 14px;
}

.deed7-auth-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.deed7-auth-main {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px 20px 64px;
}

.deed7-auth-card {
  width: 100%;
  max-width: 460px;
  background: var(--bg-card);
  border: 1px solid var(--border-strong);
  border-radius: calc(var(--radius) + 4px);
  padding: clamp(28px, 4vw, 36px);
  box-shadow: var(--shadow);
}

.deed7-auth-card--wide {
  max-width: 520px;
}

.deed7-auth-card__logo {
  display: block;
  max-width: 160px;
  height: auto;
  margin: 0 auto 20px;
  object-fit: contain;
}

.deed7-auth-card h1 {
  margin: 0 0 8px;
  text-align: center;
  font-size: 1.5rem;
  font-weight: 700;
}

.deed7-auth-card__sub {
  margin: 0 0 24px;
  text-align: center;
  color: var(--text-muted);
  font-size: 14px;
}

.deed7-form-field {
  margin-bottom: 16px;
}

.deed7-name-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.deed7-form-field label {
  display: block;
  margin-bottom: 6px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text-muted);
}

.deed7-form-field input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background: var(--bg-input);
  color: var(--text);
  font-family: inherit;
  font-size: 15px;
  transition: border-color var(--transition), box-shadow var(--transition);
}

.deed7-form-field input:focus {
  outline: none;
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

@media (max-width: 520px) {
  .deed7-name-grid {
    grid-template-columns: 1fr;
    gap: 0;
  }
}

.deed7-password-wrap {
  position: relative;
}

.deed7-password-wrap input {
  padding-right: 88px;
}

.deed7-password-toggle {
  position: absolute;
  top: 50%;
  right: 8px;
  transform: translateY(-50%);
  padding: 6px 10px;
  border: none;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--accent);
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
}

.deed7-password-toggle:hover {
  background: var(--accent-soft);
}

.deed7-form-error {
  margin: 0 0 14px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--danger-bg);
  border: 1px solid rgba(248, 113, 113, 0.35);
  color: var(--danger);
  font-size: 13px;
}

.deed7-form-error.hidden,
.deed7-form-success.hidden {
  display: none;
}

.deed7-form-success {
  margin: 0 0 14px;
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  background: var(--success-bg);
  border: 1px solid rgba(52, 211, 153, 0.35);
  color: var(--success);
  font-size: 13px;
}

.deed7-auth-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 8px;
}

.deed7-auth-links {
  margin-top: 20px;
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
}

.deed7-auth-links a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.deed7-auth-links a:hover {
  text-decoration: underline;
}

.deed7-demo-card {
  margin-top: 22px;
  padding: 14px 16px;
  border-radius: var(--radius-sm);
  border: 1px dashed var(--border-strong);
  background: rgba(255, 255, 255, 0.02);
}

.deed7-demo-card p {
  margin: 0 0 6px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-dim);
}

.deed7-demo-card code {
  display: block;
  font-size: 13px;
  color: var(--text-muted);
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

.deed7-db-tools {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.deed7-db-tools h3 {
  margin: 0 0 8px;
  font-size: 14px;
}

.deed7-db-tools p {
  margin: 0 0 12px;
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.5;
}

.deed7-db-tools__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.deed7-security-note {
  max-width: 520px;
  margin: 24px auto 0;
  padding: 0 4px;
  font-size: 12px;
  color: var(--text-dim);
  line-height: 1.5;
  text-align: center;
}

.deed7-import-input {
  position: absolute;
  width: 0;
  height: 0;
  opacity: 0;
  pointer-events: none;
}

.deed7-site-footer {
  border-top: 1px solid var(--border);
  padding: 32px clamp(20px, 4vw, 48px);
  background: rgba(0, 0, 0, 0.15);
}

.deed7-site-footer__inner {
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.deed7-site-footer__brand {
  font-weight: 800;
  font-size: 1.1rem;
  background: linear-gradient(135deg, var(--brand-grad-start), var(--accent));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.deed7-site-footer__tag {
  margin: 4px 0 0;
  font-size: 13px;
  color: var(--text-dim);
}

.deed7-site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.deed7-site-footer__links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
}

.deed7-site-footer__links a:hover {
  color: var(--accent);
}

@media (max-width: 900px) {
  .deed7-hero {
    grid-template-columns: 1fr;
  }

  .deed7-preview-card {
    max-width: 420px;
  }
}

@media (max-width: 768px) {
  .deed7-portal-grid {
    grid-template-columns: 1fr;
  }

  .deed7-auth-actions--split {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 640px) {
  .deed7-site-header {
    flex-wrap: wrap;
  }

  .deed7-site-nav {
    order: 3;
    width: 100%;
    justify-content: center;
  }

  .deed7-header-actions {
    margin-left: auto;
  }

  .deed7-preview-grid {
    grid-template-columns: 1fr;
  }
}

[data-theme="light"] .deed7-preview-card,
[data-theme="light"] .deed7-feature-card,
[data-theme="light"] .deed7-auth-card,
[data-theme="light"] .deed7-portal-card {
  background: #ffffff;
}

[data-theme="light"] .deed7-preview-stat {
  background: rgba(14, 116, 144, 0.05);
}

[data-theme="light"] .deed7-operator-panel {
  background: linear-gradient(135deg, rgba(14, 116, 144, 0.08) 0%, #ffffff 100%);
}

[data-theme="light"] .deed7-site-footer {
  background: rgba(241, 245, 249, 0.8);
}

/* Compact, header-free portal selection */
body.deed7-portal-choice-page {
  height: 100vh;
  height: 100dvh;
  min-height: 0;
  overflow: hidden;
}

body.deed7-portal-choice-page main {
  display: grid;
  width: 100%;
  height: 100%;
  min-height: 0;
  place-items: center;
}

body.deed7-portal-choice-page .deed7-portal-hero {
  display: flex;
  width: min(100%, 920px);
  height: 100%;
  min-height: 0;
  padding: clamp(18px, 4vh, 42px) clamp(16px, 4vw, 36px);
  margin: 0 auto;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  overflow: hidden;
}

body.deed7-portal-choice-page .deed7-hero__logo {
  width: clamp(108px, 19vh, 156px);
  margin: 0 0 clamp(8px, 1.8vh, 16px);
}

body.deed7-portal-choice-page .deed7-portal-hero h1 {
  margin: 0;
  font-size: clamp(1.55rem, 4vh, 2.35rem);
  line-height: 1.08;
}

body.deed7-portal-choice-page .deed7-portal-hero__sub {
  margin: clamp(6px, 1.5vh, 12px) 0 clamp(14px, 3vh, 28px);
}

body.deed7-portal-choice-page .deed7-portal-grid {
  width: 100%;
  gap: clamp(12px, 2.5vh, 22px);
}

body.deed7-portal-choice-page .deed7-portal-card {
  min-height: 0;
  padding: clamp(16px, 2.7vh, 24px);
}

body.deed7-portal-choice-page .deed7-portal-card__icon {
  width: clamp(42px, 7vh, 52px);
  height: clamp(42px, 7vh, 52px);
  margin-bottom: clamp(8px, 1.4vh, 14px);
}

body.deed7-portal-choice-page .deed7-portal-card h2 {
  margin: 0 0 6px;
  font-size: clamp(1.02rem, 2.6vh, 1.28rem);
}

body.deed7-portal-choice-page .deed7-portal-card p {
  margin: 0 0 clamp(9px, 1.6vh, 14px);
  font-size: clamp(0.78rem, 1.8vh, 0.92rem);
  line-height: 1.38;
}

body.deed7-portal-choice-page .deed7-portal-card__cta {
  font-size: clamp(0.78rem, 1.8vh, 0.9rem);
}

@media (max-width: 680px) {
  body.deed7-portal-choice-page .deed7-portal-hero {
    width: min(100%, 520px);
  }

  body.deed7-portal-choice-page .deed7-portal-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-height: 650px) and (max-width: 680px) {
  body.deed7-portal-choice-page .deed7-portal-hero {
    padding-block: 12px;
  }

  body.deed7-portal-choice-page .deed7-hero__logo {
    width: 92px;
    margin-bottom: 6px;
  }

  body.deed7-portal-choice-page .deed7-portal-hero__sub {
    margin: 4px 0 10px;
  }

  body.deed7-portal-choice-page .deed7-portal-grid {
    gap: 9px;
  }

  body.deed7-portal-choice-page .deed7-portal-card {
    padding: 12px 15px;
  }

  body.deed7-portal-choice-page .deed7-portal-card__icon {
    width: 36px;
    height: 36px;
    margin-bottom: 6px;
  }

  body.deed7-portal-choice-page .deed7-portal-card p {
    margin-bottom: 7px;
    line-height: 1.25;
  }
}
