/* ==========================================================================
   CSS VARIABLES & RESET
   ========================================================================== */
:root {
  /* Brand Palette */
  --c-maroon: #7f1d1d;
  --c-maroon-dark: #450a0a;
  --c-orange: #ea580c;
  --c-orange-light: #f97316;
  --c-mustard: #ca8a04;
  --c-charcoal: #1c1917;
  --c-charcoal-light: #292524;
  --c-paper: #f5f0e6;
  --c-white: #ffffff;
  
  /* Typography */
  --font-heading: 'Arvo', serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'Space Mono', monospace;

  /* Form & UI styling */
  --radius-lg: 16px;
  --radius-md: 12px;
  --radius-sm: 8px;
  --transition: all 0.3s ease;
  --shadow-sm: 0 2px 4px rgba(0,0,0,0.05);
  --shadow-md: 0 10px 25px -5px rgba(28, 25, 23, 0.1), 0 8px 10px -6px rgba(28, 25, 23, 0.1);
  --shadow-lg: 0 25px 50px -12px rgba(28, 25, 23, 0.25);
}

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

body {
  font-family: var(--font-body);
  color: var(--c-charcoal);
  background-color: var(--c-paper);
  background-image: url('https://offertabs.s3.amazonaws.com/offer/265esg/site/media/69f110973619c3.54841784.jpg');
  background-size: cover;
  background-attachment: fixed;
  background-blend-mode: multiply;
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  line-height: 1.2;
  margin-bottom: 0.5em;
  color: var(--c-charcoal);
}

.hidden {
  display: none !important;
}

/* ==========================================================================
   LAYOUT
   ========================================================================== */
.page-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

.content-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 0 20px;
  width: 100%;
}

.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  padding-bottom: 40px;
}

/* ==========================================================================
   STATUS BANNERS
   ========================================================================== */
.status-banner {
  background-color: var(--c-maroon);
  color: var(--c-white);
  text-align: center;
  padding: 12px 20px;
  font-weight: 600;
  font-size: 1rem;
  z-index: 100;
}
.status-banner.error { background-color: #dc2626; }
.status-banner.success { background-color: #16a34a; }

/* ==========================================================================
   HERO SECTION
   ========================================================================== */
.hero {
  position: relative;
  padding: 80px 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  overflow: hidden;
  margin-bottom: -60px; /* Overlap form */
}

.hero-bg {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background-image: url('https://offertabs.s3.amazonaws.com/offer/265esg/site/media/69f11096c7a011.13907822.jpg');
  background-size: cover;
  background-position: center;
  z-index: 1;
}

.hero-overlay {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  background: linear-gradient(180deg, rgba(28,25,23,0.7) 0%, rgba(28,25,23,0.9) 100%);
  z-index: 2;
}

.hero-content {
  position: relative;
  z-index: 3;
  max-width: 800px;
  margin: 0 auto;
  padding-bottom: 60px;
}

.brand-tag {
  display: inline-block;
  background-color: var(--c-orange);
  color: var(--c-white);
  padding: 6px 16px;
  border-radius: 99px;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 24px;
}

.hero h1 {
  color: var(--c-white);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 700;
  margin-bottom: 12px;
  text-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.hero .subtitle {
  color: var(--c-mustard);
  font-family: var(--font-body);
  font-size: clamp(1.1rem, 2vw, 1.5rem);
  font-weight: 400;
  margin-bottom: 40px;
}

.prize-card {
  display: inline-flex;
  align-items: center;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  padding: 16px 24px;
  border-radius: var(--radius-lg);
  max-width: 600px;
  text-align: left;
  gap: 20px;
}

.prize-icon {
  background: var(--c-maroon);
  color: var(--c-white);
  width: 48px; height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.prize-text strong {
  display: block;
  color: var(--c-orange);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 4px;
}

.prize-text p {
  color: var(--c-white);
  font-size: 1rem;
  line-height: 1.4;
}

/* ==========================================================================
   FORM SECTION
   ========================================================================== */
.form-section {
  position: relative;
  z-index: 10;
  margin-bottom: 60px;
}

.form-card {
  background-color: var(--c-white);
  border-radius: var(--radius-lg);
  padding: 40px;
  box-shadow: var(--shadow-lg);
  border-top: 6px solid var(--c-maroon);
}

.form-header {
  text-align: center;
  margin-bottom: 32px;
}

.form-header h3 {
  font-size: 2rem;
  color: var(--c-charcoal);
  margin-bottom: 8px;
}

.form-header p {
  color: #57534e;
  font-size: 1.1rem;
}

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

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

.input-group {
  margin-bottom: 24px;
}

label {
  display: block;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--c-charcoal);
  margin-bottom: 8px;
}

input[type="text"],
input[type="email"],
input[type="number"],
textarea,
select {
  width: 100%;
  padding: 14px 16px;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--c-charcoal);
  background-color: #fafaf9;
  border: 1px solid #d6d3d1;
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

input:focus,
textarea:focus,
select:focus {
  outline: none;
  border-color: var(--c-orange);
  box-shadow: 0 0 0 3px rgba(234, 88, 12, 0.15);
  background-color: var(--c-white);
}

input::placeholder,
textarea::placeholder {
  color: #a8a29e;
}

textarea {
  resize: vertical;
  min-height: 100px;
}

.mono-input {
  font-family: var(--font-mono) !important;
}

/* Custom Select */
.select-wrapper {
  position: relative;
}

select {
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
  padding-right: 40px;
  cursor: pointer;
}

.select-wrapper::after {
  content: "";
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 12px;
  height: 8px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2378716c' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
  pointer-events: none;
}

/* File Upload */
.file-upload-box {
  border: 2px dashed #d6d3d1;
  background-color: #fafaf9;
  border-radius: var(--radius-sm);
  padding: 30px 20px;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 12px;
}

.file-upload-box:hover, .file-upload-box.dragover {
  border-color: var(--c-orange);
  background-color: rgba(234, 88, 12, 0.05);
}

.file-upload-box svg {
  color: var(--c-orange);
}

.file-upload-box span {
  font-weight: 500;
  color: #57534e;
}

.file-upload-box input[type="file"] {
  position: absolute;
  top: 0; left: 0; width: 100%; height: 100%;
  opacity: 0;
  cursor: pointer;
}

/* Buttons */
.btn-primary, .btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 16px 32px;
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 1.1rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: var(--transition);
  border: none;
  width: 100%;
}

.btn-primary {
  background-color: var(--c-maroon);
  color: var(--c-white);
}

.btn-primary:hover {
  background-color: var(--c-maroon-dark);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(127, 29, 29, 0.3);
}

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

.btn-secondary {
  background-color: #e7e5e4;
  color: var(--c-charcoal);
  width: auto;
}
.btn-secondary:hover {
  background-color: #d6d3d1;
}

/* Loader */
.loader {
  width: 20px;
  height: 20px;
  border: 3px solid rgba(255,255,255,0.3);
  border-radius: 50%;
  border-top-color: #fff;
  animation: spin 1s ease-in-out infinite;
  margin-left: 10px;
}

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

/* ==========================================================================
   SUCCESS & SHARE
   ========================================================================== */
.success-card {
  text-align: center;
  padding: 60px 40px;
}

.success-icon {
  width: 80px; height: 80px;
  background-color: #f0fdf4;
  color: #16a34a;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 24px;
}

.success-card h3 {
  font-size: 2.5rem;
  color: var(--c-charcoal);
}

.success-card p {
  font-size: 1.1rem;
  color: #57534e;
  max-width: 500px;
  margin: 0 auto 30px;
}

.share-panel {
  background-color: #fafaf9;
  border: 1px solid #e7e5e4;
  padding: 24px;
  border-radius: var(--radius-md);
  margin-top: 30px;
}

.share-panel h4 {
  font-family: var(--font-body);
  font-size: 1.2rem;
  color: var(--c-orange);
  margin-bottom: 8px;
}

.share-input-wrap {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.share-input-wrap input {
  margin-bottom: 0;
  background-color: var(--c-white);
}

/* ==========================================================================
   GALLERY PREVIEW CAROUSEL
   ========================================================================== */
.gallery-preview {
  max-width: 1200px;
  margin: 0 auto 60px;
  padding: 0 20px;
}

.gallery-header {
  text-align: center;
  margin-bottom: 30px;
}

.gallery-header h3 {
  font-size: 2rem;
  color: var(--c-charcoal);
}

.gallery-header p {
  color: #57534e;
}

.carousel-container {
  width: 100%;
  overflow-x: auto;
  padding-bottom: 20px;
  scrollbar-width: thin;
  scrollbar-color: var(--c-orange) #e7e5e4;
}

.carousel-container::-webkit-scrollbar {
  height: 8px;
}
.carousel-container::-webkit-scrollbar-track {
  background: #e7e5e4;
  border-radius: 4px;
}
.carousel-container::-webkit-scrollbar-thumb {
  background-color: var(--c-orange);
  border-radius: 4px;
}

.carousel-track {
  display: inline-flex;
  gap: 24px;
  padding: 10px 4px;
}

.recipe-tile {
  width: 280px;
  flex-shrink: 0;
  background: var(--c-white);
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  transition: var(--transition);
  border: 1px solid rgba(0,0,0,0.05);
}

.recipe-tile:hover {
  transform: translateY(-5px);
  box-shadow: var(--shadow-lg);
}

.tile-img {
  width: 100%;
  height: 200px;
  background-size: cover;
  background-position: center;
  border-bottom: 4px solid var(--c-mustard);
}

.tile-info {
  padding: 20px;
}

.cuisine-tag {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--c-maroon);
  background: rgba(127, 29, 29, 0.1);
  padding: 4px 10px;
  border-radius: 4px;
  margin-bottom: 12px;
  letter-spacing: 0.05em;
}

.tile-info h4 {
  font-family: var(--font-body);
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 12px;
}

.tile-meta {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #78716c;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ==========================================================================
   POWERED BY
   ========================================================================== */
#wbx-powered-by-slot {
  margin: 0 auto;
  padding: 20px 0;
  width: 100%;
}
