/* Reset and base */
*, *::before, *::after { box-sizing: border-box; }
html { font-size: 16px; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  background-color: #f5f7f8;
  color: #333333;
  line-height: 1.5;
  min-height: 100vh;
}

/* Flash messages */
.flash-messages {
  position: fixed;
  top: 16px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-width: 90vw;
}
.flash {
  padding: 12px 20px;
  border-radius: 6px;
  font-size: 14px;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.flash-success { background: #d4edda; color: #155724; }
.flash-danger { background: #f8d7da; color: #721c24; }
.flash-warning { background: #fff3cd; color: #856404; }
.flash-info { background: #d1ecf1; color: #0c5460; }

/* Auth / Signup two-column card */
.auth-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.auth-card {
  display: flex;
  max-width: 960px;
  width: 100%;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 24px rgba(0,0,0,0.08);
  overflow: hidden;
}
.auth-panel-left {
  flex: 0 0 45%;
  background: #29313C;
  padding: 48px 40px;
  display: flex;
  flex-direction: column;
  justify-content: center;
}
.auth-logo {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  margin-bottom: 32px;
  letter-spacing: -0.02em;
}
.auth-logo .logo-ad {
  color: #FFC107;
  position: relative;
}
.auth-logo .logo-ad::before {
  content: "";
  display: inline-block;
  width: 0;
  height: 0;
  border-top: 5px solid transparent;
  border-bottom: 5px solid transparent;
  border-left: 6px solid #FFC107;
  margin-right: 2px;
  vertical-align: middle;
}
.auth-headline {
  font-size: 1.5rem;
  font-weight: 700;
  color: #fff;
  line-height: 1.3;
  margin: 0 0 16px 0;
}
.auth-subtext {
  font-size: 0.9375rem;
  color: #A0A6B1;
  margin: 0 0 32px 0;
  max-width: 320px;
}
.auth-browser-mock {
  margin-top: auto;
  background: rgba(255,255,255,0.06);
  border-radius: 8px;
  padding: 12px 12px 24px 12px;
  max-width: 280px;
}
.auth-browser-dots {
  display: flex;
  gap: 6px;
  margin-bottom: 10px;
}
.auth-browser-dots span {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.auth-browser-dots span:nth-child(1) { background: #e74c3c; }
.auth-browser-dots span:nth-child(2) { background: #f1c40f; }
.auth-browser-dots span:nth-child(3) { background: #2ecc71; }
.auth-browser-content {
  background: #fff;
  border-radius: 4px;
  height: 100px;
  display: flex;
}
.auth-browser-sidebar {
  width: 40px;
  background: #2c3e50;
  border-radius: 4px 0 0 4px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding-top: 12px;
}
.auth-browser-sidebar span {
  width: 8px;
  height: 8px;
  background: rgba(255,255,255,0.5);
  border-radius: 2px;
}
.auth-browser-main {
  flex: 1;
  padding: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.auth-browser-main .bar {
  height: 8px;
  background: #ecf0f1;
  border-radius: 4px;
  width: 60%;
}
.auth-browser-main .bar:nth-child(2) { width: 80%; }
.auth-browser-main .bar:nth-child(3) { width: 40%; }

.auth-panel-right {
  flex: 1;
  padding: 48px 40px;
  display: flex;
  flex-direction: column;
}
.auth-title {
  font-size: 1.75rem;
  font-weight: 700;
  color: #333333;
  margin: 0 0 28px 0;
}
.form-group {
  margin-bottom: 20px;
}
.form-group label {
  display: block;
  font-size: 0.875rem;
  font-weight: 500;
  color: #333333;
  margin-bottom: 6px;
}
.form-group label .required {
  color: rgb(220, 53, 69);
}
.input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.input-wrap .icon-left,
.input-wrap .icon-right {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #6C757D;
  pointer-events: none;
}
.input-wrap .icon-left { left: 12px; }
.input-wrap .icon-right { right: 12px; }
.input-wrap input {
  width: 100%;
  padding: 10px 12px 10px 40px;
  font-size: 1rem;
  border: 1px solid #CED4DA;
  border-radius: 6px;
  background: #fff;
  color: #333;
}
.input-wrap input::placeholder {
  color: #6C757D;
}
.input-wrap.icon-right input {
  padding-left: 12px;
  padding-right: 40px;
}
/* When both left and right icons (e.g. password), keep left padding so text doesn't overlap lock icon */
.input-wrap.icon-left.icon-right input {
  padding-left: 40px;
  padding-right: 40px;
}
.input-wrap.icon-both input {
  padding-right: 40px;
}
.form-check {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}
.form-check input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: #343A40;
}
.form-check label {
  font-size: 0.875rem;
  color: #333333;
  margin: 0;
  cursor: pointer;
}
.form-error {
  display: block;
  font-size: 0.8125rem;
  color: rgb(220, 53, 69);
  margin-top: 4px;
}
.form-link {
  font-size: 0.875rem;
  color: #6C757D;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 24px;
}
.form-link:hover { color: #007BFF; text-decoration: underline; }
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 24px;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  border: none;
  text-decoration: none;
  transition: background 0.2s, border-color 0.2s;
}
.btn-primary {
  background: #343A40;
  color: #fff;
  width: 100%;
  margin-bottom: 24px;
}
.btn-primary:hover { background: #23272b; }
.btn-outline {
  background: #fff;
  color: #333333;
  border: 1px solid #CED4DA;
  flex: 1;
}
.btn-outline:hover { background: #f8f9fa; border-color: #adb5bd; }
.auth-divider {
  border: 0;
  border-top: 1px solid #dee2e6;
  margin: 8px 0 20px 0;
}
.auth-cta-text {
  font-size: 0.875rem;
  color: #333333;
  text-align: center;
  margin-bottom: 16px;
}
.auth-buttons-row {
  display: flex;
  gap: 12px;
  margin-bottom: 28px;
}
.auth-buttons-row .btn-outline {
  white-space: nowrap;
  flex: 1;
  min-width: 0;
}
.auth-footer-text {
  font-size: 0.75rem;
  color: #6C757D;
  margin-top: auto;
}
.auth-footer-text a {
  color: #007BFF;
  text-decoration: none;
}
.auth-footer-text a:hover { text-decoration: underline; }

/* Signup header with step */
.signup-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 28px;
}
.signup-header h1 {
  font-size: 1.75rem;
  font-weight: 700;
  color: #333333;
  margin: 0;
}
.signup-header .signup-type {
  font-size: 0.875rem;
  color: #6C757D;
  padding-left: 12px;
  border-left: 1px solid #dee2e6;
}
.wizard-steps {
  display: flex;
  gap: 8px;
  margin-bottom: 24px;
}
.wizard-step {
  flex: 1;
  height: 4px;
  background: #dee2e6;
  border-radius: 2px;
}
.wizard-step.active,
.wizard-step.done { background: #343A40; }
.btn-register-wrap {
  display: flex;
  justify-content: flex-end;
  margin-top: 24px;
}
.signup-links {
  font-size: 0.875rem;
  margin-top: 20px;
}
.signup-links a {
  color: #007BFF;
  text-decoration: none;
}
.signup-links a:hover { text-decoration: underline; }
.signup-links span { color: #6C757D; margin: 0 8px; }

/* Step 2 tag box */
.tag-box {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  padding: 16px;
  margin: 20px 0;
  font-family: monospace;
  font-size: 0.8125rem;
  word-break: break-all;
}
.tag-instruction {
  font-size: 0.875rem;
  color: #6C757D;
  margin-bottom: 12px;
}
.btn-verify {
  background: #343A40;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 6px;
  font-weight: 600;
  cursor: pointer;
  margin-right: 8px;
}
.btn-verify:hover { background: #23272b; }
.btn-verify:disabled { opacity: 0.6; cursor: not-allowed; }
.tag-verified-msg {
  color: #155724;
  font-size: 0.875rem;
  margin-top: 8px;
}
.tag-error-msg {
  color: #721c24;
  font-size: 0.875rem;
  margin-top: 8px;
}
.btn-copy {
  background: #fff;
  border: 1px solid #CED4DA;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 0.875rem;
  cursor: pointer;
}
.btn-copy:hover { background: #f8f9fa; }
.btn-edit-website {
  color: #007BFF;
  font-size: 0.875rem;
  text-decoration: none;
}
.btn-edit-website:hover { text-decoration: underline; }
.step2-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 12px;
}

/* Step 3 approval */
.approval-box {
  text-align: center;
  padding: 48px 24px;
}
.approval-box h2 {
  font-size: 1.5rem;
  color: #333333;
  margin-bottom: 12px;
}
.approval-box p {
  color: #6C757D;
  margin-bottom: 24px;
}

/* Dashboard */
.dashboard-page {
  min-height: 100vh;
  background: #f5f7f8;
}
.dashboard-header {
  background: #fff;
  padding: 16px 24px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}
.dashboard-header-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.dashboard-title { font-size: 1.25rem; font-weight: 600; margin: 0; }
.dashboard-main {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px;
}
.dashboard-card {
  background: #fff;
  border-radius: 8px;
  padding: 24px;
  box-shadow: 0 1px 3px rgba(0,0,0,0.06);
}

/* Logout form */
.logout-form { display: inline; }
.logout-form .btn { width: auto; margin: 0; }

/* Responsive – mobile: left panel shows only logo, no headline/subtext/browser mock */
@media (max-width: 768px) {
  .auth-card { flex-direction: column; }
  .auth-panel-left {
    padding: 20px 24px;
    min-height: 0;
    justify-content: flex-start;
  }
  .auth-logo { margin-bottom: 0; }
  .auth-headline,
  .auth-subtext,
  .auth-browser-mock { display: none !important; }
  .auth-panel-right { padding: 32px 24px; }
  /* One button per line on mobile to avoid overlap */
  .auth-buttons-row {
    flex-direction: column;
    flex-wrap: wrap;
  }
  .auth-buttons-row .btn-outline {
    flex: none;
    width: 100%;
  }
}
