:root {
  --color-primary: #d48a8a; /* Dusty rose */
  --color-primary-hover: #b87575;
  --color-secondary: #f9d4c1; /* Soft peach */
  --color-bg: #faf7f5;
  --color-text: #2c2927;
  --color-text-light: #6e6763;
  --color-white: #ffffff;
  --color-error: #e53e3e;
  --font-serif: 'Playfair Display', serif;
  --font-sans: 'Inter', sans-serif;
  --radius-lg: 24px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --shadow-soft: 0 20px 40px rgba(44, 41, 39, 0.08);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  font-family: var(--font-sans);
  color: var(--color-text);
  background-color: var(--color-bg);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.hidden {
  display: none !important;
}

.page-wrapper {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem 1rem;
  overflow: hidden;
}

.background-image {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-size: cover;
  background-position: center;
  z-index: 0;
  filter: blur(8px);
  transform: scale(1.05); /* hide blur edges */
}

.background-overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(250, 247, 245, 0.85) 0%, rgba(249, 212, 193, 0.7) 100%);
  z-index: 1;
}

.main-content {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 520px;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.card {
  background: var(--color-white);
  border-radius: var(--radius-lg);
  padding: 3.5rem 3rem;
  box-shadow: var(--shadow-soft);
  width: 100%;
  text-align: center;
  margin-bottom: 2rem;
  border: 1px solid rgba(255,255,255,0.6);
  position: relative;
  overflow: hidden;
}

/* Subtle decorative element */
.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: linear-gradient(90deg, var(--color-secondary), var(--color-primary));
}

.header {
  margin-bottom: 2.5rem;
}

.eyebrow {
  display: inline-block;
  font-size: 0.875rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  color: var(--color-primary);
  margin-bottom: 1rem;
}

h1 {
  font-family: var(--font-serif);
  font-size: 2.75rem;
  line-height: 1.15;
  margin-bottom: 1rem;
  color: var(--color-text);
  font-weight: 600;
}

.subtitle {
  color: var(--color-text-light);
  font-size: 1.05rem;
}

.form {
  text-align: left;
}

.form-group {
  margin-bottom: 1.5rem;
}

label {
  display: block;
  font-size: 0.9rem;
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: var(--color-text);
}

input {
  width: 100%;
  padding: 1rem 1.25rem;
  font-family: inherit;
  font-size: 1rem;
  color: var(--color-text);
  background-color: var(--color-bg);
  border: 1px solid rgba(0,0,0,0.08);
  border-radius: var(--radius-md);
  transition: all 0.3s ease;
  outline: none;
}

input:focus {
  border-color: var(--color-primary);
  background-color: var(--color-white);
  box-shadow: 0 0 0 3px rgba(212, 138, 138, 0.15);
}

input::placeholder {
  color: #a8a29e;
}

.btn-primary {
  width: 100%;
  margin-top: 0.5rem;
  padding: 1rem 1.5rem;
  font-family: inherit;
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--color-white);
  background: var(--color-primary);
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.3s ease;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.btn-primary:hover {
  background: var(--color-primary-hover);
  transform: translateY(-2px);
  box-shadow: 0 10px 20px rgba(212, 138, 138, 0.2);
}

.btn-primary:disabled {
  opacity: 0.7;
  cursor: not-allowed;
  transform: none;
  box-shadow: none;
}

.btn-loader {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255,255,255,0.3);
  border-top-color: white;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  position: absolute;
}

@keyframes spin { 100% { transform: rotate(360deg); } }

.error-message {
  color: var(--color-error);
  font-size: 0.9rem;
  margin-top: 1rem;
  text-align: center;
  padding: 0.75rem;
  background: rgba(229, 62, 62, 0.1);
  border-radius: var(--radius-sm);
}

/* Result Section */
.success-header {
  margin-bottom: 2rem;
}

.icon-success {
  width: 56px;
  height: 56px;
  background: var(--color-secondary);
  color: var(--color-primary-hover);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
}

.icon-success svg {
  width: 28px;
  height: 28px;
}

.success-header h2 {
  font-family: var(--font-serif);
  font-size: 2.25rem;
  margin-bottom: 0.5rem;
}

.coupon-display {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.coupon-card {
  background: linear-gradient(135deg, var(--color-secondary) 0%, var(--color-primary) 100%);
  border-radius: var(--radius-md);
  padding: 2rem 1.5rem;
  width: 100%;
  color: var(--color-white);
  box-shadow: 0 12px 24px rgba(212, 138, 138, 0.25);
  margin-bottom: 1.25rem;
  position: relative;
  overflow: hidden;
}

/* Coupon dashed inner border */
.coupon-card::after {
  content: '';
  position: absolute;
  top: 10px; left: 10px; right: 10px; bottom: 10px;
  border: 1px dashed rgba(255,255,255,0.5);
  border-radius: calc(var(--radius-md) - 6px);
  pointer-events: none;
}

.coupon-amount {
  font-family: var(--font-serif);
  font-size: 1.5rem;
  font-style: italic;
  margin-bottom: 0.5rem;
  opacity: 0.9;
}

.coupon-code-wrapper {
  font-size: 2.5rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  font-family: var(--font-sans);
  text-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.expiry-text {
  font-size: 0.875rem;
  color: var(--color-text-light);
  margin-bottom: 1.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  font-weight: 500;
}

.btn-secondary {
  padding: 0.875rem 2rem;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 500;
  color: var(--color-primary);
  background: transparent;
  border: 1px solid var(--color-primary);
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-secondary:hover {
  background: var(--color-primary);
  color: var(--color-white);
}

.status-banner {
  background: var(--color-white);
  padding: 1rem 2rem;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  margin-bottom: 2rem;
  font-weight: 500;
  color: var(--color-primary);
  text-align: center;
}

#wbx-powered-by-slot {
  margin-top: 1rem;
}

@media (max-width: 600px) {
  .card {
    padding: 2.5rem 1.5rem;
  }
  h1 {
    font-size: 2.25rem;
  }
}