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

html {
  scroll-behavior: smooth;
}

body {
  background: #1a1a1a;
  color: #e8e2dc;
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  font-size: 15px;
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* ── Header ── */
.site-header {
  text-align: center;
  padding: 40px 20px 20px;
}

.logo {
  line-height: 0;
}

.logo-img {
  height: 48px;
  width: auto;
  opacity: 0.9;
}

/* ── Main ── */
.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 0 20px 60px;
  max-width: 640px;
  width: 100%;
  margin: 0 auto;
}

/* ── Intro ── */
.intro {
  text-align: center;
  margin-bottom: 40px;
  animation: fadeUp 0.35s ease both;
}

.intro.hidden {
  display: none;
}

.intro-label {
  display: inline-block;
  font-family: 'Montserrat', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #e8e2dc;
  opacity: 0.6;
  margin-bottom: 16px;
}

.intro h1 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
  font-size: 36px;
  color: #e8e2dc;
  margin-bottom: 16px;
  line-height: 1.3;
}

.intro-text {
  font-size: 14px;
  font-weight: 300;
  color: #e8e2dc;
  opacity: 0.7;
  max-width: 480px;
  margin: 0 auto;
  line-height: 1.7;
}

/* ── Form Container ── */
.form-container {
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid #333;
  padding: 50px 40px;
}

/* ── Steps ── */
.form-step {
  display: none;
}

.form-step.active {
  display: block;
  animation: fadeUp 0.35s ease both;
}

.form-step h2 {
  font-family: 'Cormorant Garamond', serif;
  font-weight: 300;
  font-size: 26px;
  color: #e8e2dc;
  margin-bottom: 32px;
}

/* ── Form Groups ── */
.form-group {
  margin-bottom: 28px;
}

.form-group label {
  display: block;
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-weight: 400;
  font-size: 15px;
  color: #e8e2dc;
  opacity: 0.8;
  margin-bottom: 8px;
}

/* ── Inputs & Selects ── */
input[type="text"],
input[type="email"],
input[type="tel"],
input[type="date"],
select {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid #444;
  color: #e8e2dc;
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  font-size: 14px;
  padding: 10px 0;
  outline: none;
  transition: border-bottom-color 0.25s ease;
  appearance: none;
  -webkit-appearance: none;
  border-radius: 0;
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
input[type="date"]:focus,
select:focus {
  border-bottom-color: #e8e2dc;
}

input::placeholder,
textarea::placeholder {
  color: #e8e2dc;
  opacity: 0.35;
}

/* Select arrow */
select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' stroke='%23e8e2dc' stroke-width='1.5' fill='none' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 4px center;
  padding-right: 24px;
  cursor: pointer;
}

select option {
  background: #1a1a1a;
  color: #e8e2dc;
}

/* Date input */
input[type="date"] {
  cursor: pointer;
}

input[type="date"]::-webkit-calendar-picker-indicator {
  filter: invert(0.9);
  cursor: pointer;
}

/* ── Textarea ── */
textarea {
  width: 100%;
  background: transparent;
  border: 1px solid #444;
  color: #e8e2dc;
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  font-size: 14px;
  padding: 12px;
  outline: none;
  resize: vertical;
  transition: border-color 0.25s ease;
  border-radius: 0;
  min-height: 80px;
}

textarea:focus {
  border-color: #e8e2dc;
}

/* ── Phone Wrapper ── */
.phone-wrapper {
  display: flex;
  gap: 12px;
  align-items: flex-end;
}

.country-code-select {
  width: 110px;
  flex-shrink: 0;
}

.phone-wrapper input[type="tel"] {
  flex: 1;
}

/* ── Validation States ── */
input.valid,
select.valid,
textarea.valid {
  border-bottom-color: #6b9e6f;
}

textarea.valid {
  border-color: #6b9e6f;
}

input.invalid,
select.invalid,
textarea.invalid {
  border-bottom-color: #c0504e;
}

textarea.invalid {
  border-color: #c0504e;
}

.error-msg {
  display: block;
  font-size: 12px;
  color: #c0504e;
  margin-top: 6px;
  min-height: 0;
  opacity: 0;
  transition: opacity 0.2s ease;
}

.error-msg.show {
  opacity: 1;
}

/* ── Section Headings ── */
.form-step h3 {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 400;
  color: #e8e2dc;
  margin: 36px 0 16px;
  padding-top: 16px;
  border-top: 1px solid #333;
}

.form-step h3:first-child {
  margin-top: 0;
  padding-top: 0;
  border-top: none;
}

/* ── Form Row (side by side) ── */
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
}

@media (max-width: 600px) {
  .form-row { grid-template-columns: 1fr; gap: 0; }
}

/* ── Package Details Card ── */
.package-details {
  margin-bottom: 28px;
  animation: fadeUp 0.35s ease both;
}

.package-card {
  border: 1px solid #444;
  padding: 24px;
  background: rgba(255, 255, 255, 0.03);
}

.package-header {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid #333;
}

.package-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 400;
  color: #e8e2dc;
}

.package-price {
  font-family: 'Montserrat', sans-serif;
  font-size: 20px;
  font-weight: 500;
  color: #e8e2dc;
  letter-spacing: 1px;
}

.package-includes {
  list-style: none;
  padding: 0;
}

.package-includes li {
  font-family: 'Montserrat', sans-serif;
  font-size: 13px;
  font-weight: 300;
  color: #e8e2dc;
  opacity: 0.8;
  padding: 6px 0;
  padding-left: 20px;
  position: relative;
  line-height: 1.5;
}

.package-includes li::before {
  content: '✓';
  position: absolute;
  left: 0;
  color: #6b9e6f;
  font-size: 12px;
}

/* ── Buttons ── */
.btn-row {
  margin-top: 36px;
  display: flex;
  justify-content: flex-end;
  gap: 14px;
}

.btn-row.two-buttons {
  justify-content: space-between;
}

.btn {
  font-family: 'Montserrat', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 3px;
  text-transform: uppercase;
  padding: 14px 32px;
  border: none;
  border-radius: 0;
  cursor: pointer;
  transition: all 0.25s ease;
  outline: none;
}

.btn-primary {
  background: #e8e2dc;
  color: #1a1a1a;
}

.btn-primary:hover {
  background: #fff;
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.btn-back {
  background: transparent;
  color: #e8e2dc;
  border: 1px solid #e8e2dc;
}

.btn-back:hover {
  background: #e8e2dc;
  color: #1a1a1a;
}

/* ── Success Page ── */
.success-page {
  text-align: center;
  padding: 20px 0;
}

.success-icon {
  width: 60px;
  height: 60px;
  border: 2px solid #e8e2dc;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
}

.success-page .intro-label {
  margin-bottom: 12px;
}

.success-page h2 {
  text-align: center;
  margin-bottom: 16px;
}

.success-text {
  font-size: 14px;
  font-weight: 300;
  color: #e8e2dc;
  opacity: 0.7;
  line-height: 1.7;
  max-width: 400px;
  margin: 0 auto;
}

.divider {
  width: 40px;
  height: 1px;
  background: #444;
  margin: 28px auto;
}

.signature {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 18px;
  color: #e8e2dc;
  margin-bottom: 4px;
}

.brand {
  font-family: 'Montserrat', sans-serif;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #e8e2dc;
  opacity: 0.5;
}

/* ── Footer ── */
.site-footer {
  text-align: center;
  padding: 30px 20px;
  font-family: 'Montserrat', sans-serif;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 2px;
  color: #e8e2dc;
  opacity: 0.4;
}

/* ── Contract Box ── */
.contract-box {
  background: rgba(255, 255, 255, 0.03);
  border-left: 2px solid #444;
  padding: 20px 24px;
  margin-bottom: 28px;
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 15px;
  line-height: 1.7;
  color: #e8e2dc;
  opacity: 0.8;
}

/* ── Checkboxes ── */
.checkbox-group {
  margin-bottom: 16px;
}

.checkbox-label {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  cursor: pointer;
  font-size: 13px;
  line-height: 1.6;
  color: #e8e2dc;
  opacity: 0.85;
}

.checkbox-label input[type="checkbox"] {
  display: none;
}

.checkbox-custom {
  flex-shrink: 0;
  width: 18px;
  height: 18px;
  border: 1px solid #555;
  background: rgba(255,255,255,0.05);
  margin-top: 2px;
  position: relative;
  transition: all 0.2s ease;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom {
  background: #e8e2dc;
  border-color: #e8e2dc;
}

.checkbox-label input[type="checkbox"]:checked + .checkbox-custom::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 5px;
  width: 5px;
  height: 9px;
  border: solid #1a1a1a;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.checkbox-label.checkbox-error {
  color: #e07c7c;
}

.checkbox-label.checkbox-error .checkbox-custom {
  border-color: #e07c7c;
}

.contract-link {
  color: #c9a96e;
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s ease;
}

.contract-link:hover {
  color: #e0c48a;
}

.section-divider {
  border: none;
  border-top: 1px solid rgba(255,255,255,0.08);
  margin: 28px 0;
}

.required {
  color: #c9a96e;
}

/* ── Signature Pad ── */
.signature-pad-wrapper {
  position: relative;
  border: 1px solid #444;
  background: rgba(255,255,255,0.03);
  margin-top: 8px;
  transition: border-color 0.25s ease;
}
.signature-pad-wrapper:hover {
  border-color: #666;
}
.signature-pad-wrapper canvas {
  width: 100%;
  height: 200px;
  display: block;
  cursor: crosshair;
  touch-action: none;
}
.signature-clear-btn {
  position: absolute;
  top: 8px;
  right: 8px;
  background: rgba(26,26,26,0.7);
  border: 1px solid #555;
  color: #999;
  font-family: 'Montserrat', sans-serif;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 2px;
  padding: 6px 14px;
  cursor: pointer;
  transition: all 0.25s ease;
}
.signature-clear-btn:hover {
  border-color: #e8e2dc;
  color: #e8e2dc;
}
.signature-error {
  color: #c0504e;
  font-size: 12px;
  margin-top: 8px;
}
.signature-pad-wrapper.has-error {
  border-color: #c0504e;
}
.signature-pad-wrapper.has-signature {
  border-color: #6b9e6f;
}
.signature-hint {
  font-size: 12px;
  font-weight: 300;
  color: #e8e2dc;
  opacity: 0.5;
  margin-bottom: 4px;
  font-style: italic;
}
.confirmation-text {
  font-family: 'Cormorant Garamond', serif;
  font-style: italic;
  font-size: 15px;
  line-height: 1.7;
  color: #e8e2dc;
  opacity: 0.7;
  border-left: 2px solid #444;
  padding: 12px 0 12px 20px;
  margin-bottom: 28px;
}

/* ── Verwendungszweck Checkboxes ── */
.checkbox-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 24px;
}

.checkbox-grid .checkbox-group {
  margin-bottom: 8px;
}

.checkbox-grid .checkbox-label {
  font-size: 13px;
}

@media (max-width: 600px) {
  .checkbox-grid {
    grid-template-columns: 1fr;
    gap: 4px;
  }
}

/* ── Animation ── */
@keyframes fadeUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* ── Mobile ── */
@media (max-width: 600px) {
  .form-container {
    padding: 30px 20px;
  }

  .intro h1 {
    font-size: 28px;
  }

  .form-step h2 {
    font-size: 22px;
  }

  .btn {
    padding: 12px 24px;
    font-size: 10px;
  }

  .phone-wrapper {
    gap: 8px;
  }

  .country-code-select {
    width: 100px;
  }
}
