/* Dark Theme with Liquid Glass Effect */
:root {
  --primary-color: #3b82f6;
  --primary-hover: #2563eb;
  --primary-glow: rgba(59, 130, 246, 0.5);
  --success-color: #10b981;
  --success-bg: rgba(16, 185, 129, 0.15);
  --error-color: #ef4444;
  --error-bg: rgba(239, 68, 68, 0.15);
  --text-primary: #f1f5f9;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --border-color: rgba(255, 255, 255, 0.1);
  --border-focus: rgba(59, 130, 246, 0.5);
  --bg-color: #0a0a0f;
  --glass-bg: rgba(255, 255, 255, 0.03);
  --glass-border: rgba(255, 255, 255, 0.08);
  --glass-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
  --input-bg: rgba(255, 255, 255, 0.05);
  --radius: 12px;
  --radius-lg: 20px;
}

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Base Styles */
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  background: var(--bg-color);
  background-image:
    radial-gradient(ellipse at 20% 20%, rgba(59, 130, 246, 0.08) 0%, transparent 50%),
    radial-gradient(ellipse at 80% 80%, rgba(139, 92, 246, 0.06) 0%, transparent 50%),
    radial-gradient(ellipse at 50% 50%, rgba(16, 185, 129, 0.04) 0%, transparent 70%);
  background-attachment: fixed;
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
}

.container {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

/* Form Card */
.form-wrapper {
  width: 100%;
  max-width: 660px;
  background: #12121a;
  border-radius: var(--radius-lg);
  border: 1px solid var(--glass-border);
  box-shadow: var(--glass-shadow);
  overflow: hidden;
  position: relative;
  padding: 10px 0;
  margin-top: 20px;
  margin-bottom: 20px;
}


/* Form Header */
.form-header {
  padding: 24px 32px 16px;
  text-align: center;
  border-bottom: 1px solid var(--glass-border);
}

.logo {
  width: min(100%, 320px);
  max-width: 320px;
  height: auto;
  margin-top: 6px;
  margin-bottom: 10px;
}

.form-header h1 {
  font-size: 26px;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: 8px;
  letter-spacing: -0.02em;
}

.form-header p {
  color: var(--text-secondary);
  font-size: 15px;
  margin-bottom: 5px;
}

/* Form Styles */
form {
  padding: 32px;
}

.form-group {
  margin-bottom: 22px;
}

.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

label {
  display: block;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  margin-bottom: 8px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.required {
  color: var(--primary-color);
}

input[type="text"],
input[type="email"],
input[type="tel"],
input[type="url"],
input[type="password"],
select {
  width: 100%;
  padding: 14px 16px;
  font-size: 15px;
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
  background: var(--input-bg);
  color: var(--text-primary);
  transition: all 0.2s ease;
}

input::placeholder {
  color: var(--text-muted);
}

input:focus,
select:focus {
  outline: none;
  border-color: var(--border-focus);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15), 0 0 20px rgba(59, 130, 246, 0.1);
  background: rgba(255, 255, 255, 0.07);
}

select {
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2394a3b8'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M19 9l-7 7-7-7'%3E%3C/path%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
  padding-right: 44px;
}

select option {
  background: #1a1a2e;
  color: var(--text-primary);
}

/* Section Divider */
.section-divider {
  margin: 28px 0;
  border: none;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--glass-border), transparent);
}

.section-title {
  font-size: 12px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 20px;
  display: flex;
  align-items: center;
  gap: 12px;
}

.section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--glass-border);
}

/* Address Section (Collapsible) */
.address-section {
  margin-bottom: 24px;
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.02);
}

.address-section summary {
  padding: 14px 18px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-secondary);
  background: transparent;
  transition: all 0.2s;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 10px;
}

.address-section summary::-webkit-details-marker {
  display: none;
}

.address-section summary::before {
  content: '+';
  font-size: 18px;
  font-weight: 400;
  color: var(--primary-color);
  width: 20px;
  text-align: center;
}

.address-section[open] summary::before {
  content: '-';
}

.address-section summary:hover {
  background: rgba(255, 255, 255, 0.03);
  color: var(--text-primary);
}

.address-fields {
  padding: 20px 18px;
  border-top: 1px solid var(--glass-border);
}

.address-fields .form-group:last-child {
  margin-bottom: 0;
}

/* Submit Button */
.submit-btn {
  width: 100%;
  padding: 16px 24px;
  font-size: 15px;
  font-weight: 600;
  color: white;
  background: linear-gradient(135deg, var(--primary-color) 0%, #6366f1 100%);
  border: none;
  border-radius: var(--radius);
  cursor: pointer;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  position: relative;
  overflow: hidden;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.submit-btn::before {
  content: '';
  position: absolute;
  top: 0;
  left: -100%;
  width: 100%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  transition: left 0.5s ease;
}

.submit-btn:hover:not(:disabled)::before {
  left: 100%;
}

.submit-btn:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px var(--primary-glow);
}

.submit-btn:active:not(:disabled) {
  transform: translateY(0);
}

.submit-btn:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

.btn-loading {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.spinner {
  width: 20px;
  height: 20px;
  animation: spin 1s linear infinite;
}

@keyframes spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

/* Message Styles */
.message {
  margin-top: 24px;
  padding: 18px;
  border-radius: var(--radius);
  display: flex;
  align-items: flex-start;
  gap: 14px;
  backdrop-filter: blur(10px);
}

.message svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.message strong {
  display: block;
  margin-bottom: 4px;
  font-weight: 600;
}

.message p {
  font-size: 14px;
  margin: 0;
  opacity: 0.9;
}

.message.success {
  background: var(--success-bg);
  color: var(--success-color);
  border: 1px solid rgba(16, 185, 129, 0.3);
}

.message.error {
  background: var(--error-bg);
  color: var(--error-color);
  border: 1px solid rgba(239, 68, 68, 0.3);
}

/* Form Footer */
.form-footer {
  padding: 20px 32px 28px;
  text-align: center;
  border-top: 1px solid var(--glass-border);
}

.form-footer p {
  font-size: 12px;
  color: var(--text-muted);
}

.form-footer a {
  color: var(--primary-color);
  text-decoration: none;
}

.form-footer a:hover {
  text-decoration: underline;
}

/* Responsive Design */
@media (max-width: 620px) {
  .container {
    padding: 16px;
  }

  .form-wrapper {
    border-radius: 16px;
  }

  .form-header {
    padding: 32px 24px 28px;
  }

  .logo {
    max-width: 240px;
  }

  .form-header h1 {
    font-size: 22px;
  }

  form {
    padding: 24px;
  }

  .form-row {
    grid-template-columns: 1fr;
    gap: 0;
  }

  .form-footer {
    padding: 16px 24px 24px;
  }
}

/* Subtle Animation */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.form-wrapper {
  animation: fadeIn 0.5s ease-out;
}
