/* 
 * Variables & Reset
 */
:root {
  --font-heading: 'EB Garamond', Garamond, serif;
  --font-body: 'Inter', sans-serif;
  
  --color-bg: #F5F3ED; /* Light cream characteristic of Lucky Saint */
  --color-brand-navy: #00587D; /* Updated primary blue */
  --color-brand-blue: #004664; /* Updated secondary/hover blue */
  --color-brand-gold: #D29D2B; /* Rich dark gold */
  --color-white: #ffffff;
  --color-entry-box: #f2f0f0; /* Requested entry box background */
  --color-text-body: #00587D;
  --color-text-muted: rgba(0, 88, 125, 0.85); /* Sligtly softened navy */
  --color-error: #D32F2F;
  --color-border: #E0DDD1;
  
  --radius-lg: 12px;
  --radius-md: 8px;
  --radius-sm: 4px;
  
  --transition: all 0.3s ease;
}

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

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

/* Background image */
.site-bg {
  display: block;
  position: fixed;
  top: 0; left: 0; width: 100%; height: 100%;
  background-image: url('https://offertabs.s3.amazonaws.com/offer/zu6z2n/site/media/6a43bafba4a339.98169581.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  z-index: -2;
  opacity: 0.6;
}

/* Mandatory Utility */
.hidden {
  display: none !important;
}

/* Layout */
.site-wrapper {
  display: flex;
  flex-direction: column;
  flex: 1;
  max-width: 800px;
  width: 100%;
  margin: 0 auto;
  padding: 3rem 1.5rem 3rem;
}

.main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
}

/* Clean White Cards */
.card {
  width: 100%;
  background: var(--color-entry-box);
  border: 1px solid var(--color-border);
  border-radius: var(--radius-lg);
  padding: 3.5rem 3rem;
  box-shadow: 0 15px 35px -5px rgba(0, 88, 125, 0.05), 0 5px 15px rgba(0, 0, 0, 0.02);
  margin-bottom: 2rem;
  animation: fadeIn 0.6s ease forwards;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(15px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Typography Details */
.hero-text {
  text-align: center;
  margin-bottom: 2.5rem;
}

.brand-logo {
  max-width: 100%;
  width: 320px;
  height: auto;
  margin: 0.5rem auto 1rem auto;
  display: block;
  mix-blend-mode: multiply;
}

.eyebrow {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--color-brand-gold);
  margin-bottom: 1rem;
}

h1, h2, h3 {
  font-family: var(--font-heading);
  line-height: 1.1;
  color: var(--color-brand-navy);
}

h1 {
  font-family: var(--font-heading);
  font-size: 3.5rem;
  font-weight: 800;
  margin-bottom: 1.25rem;
}

h2 {
  font-size: 2.5rem;
  margin-bottom: 1.25rem;
  text-align: center;
}

h3 {
  font-size: 1.75rem;
  margin-bottom: 1rem;
}

.highlight-text {
  font-family: var(--font-heading);
  color: var(--color-brand-gold);
  font-style: italic;
}

p {
  color: var(--color-text-muted);
  font-size: 1.1rem;
  margin-bottom: 1.5rem;
}

.text-center {
  text-align: center;
}

.hero-text p {
  max-width: 500px;
  margin: 0 auto;
}

/* Form Styles */
form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-brand-navy);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

input[type="text"],
input[type="email"] {
  width: 100%;
  padding: 1rem 1.25rem;
  font-family: var(--font-body);
  font-size: 16px;
  color: var(--color-brand-navy);
  background: var(--color-white); /* Updated to contrast with card bg */
  border: 1px solid var(--color-border);
  border-radius: var(--radius-sm);
  transition: var(--transition);
}

input[type="text"]:focus,
input[type="email"]:focus {
  outline: none;
  border-color: var(--color-brand-navy);
  box-shadow: 0 0 0 1px var(--color-brand-navy);
}

input::placeholder {
  color: #A0AEC0;
}

.error-box {
  background: #FFF5F5;
  border: 1px solid var(--color-error);
  color: var(--color-error);
  padding: 1rem;
  border-radius: var(--radius-sm);
  font-size: 0.95rem;
  text-align: center;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  font-weight: 600;
  cursor: pointer;
  border: none;
  transition: var(--transition);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  min-height: 54px;
}

.btn-primary {
  width: 100%;
  padding: 1.25rem;
  font-size: 1.1rem;
  background: var(--color-brand-navy);
  color: var(--color-white);
  border-radius: var(--radius-sm);
  margin-top: 1rem;
  box-shadow: 0 8px 15px rgba(0, 88, 125, 0.15);
}

.btn-primary:hover {
  transform: translateY(-2px);
  background: var(--color-brand-blue);
  box-shadow: 0 12px 20px rgba(0, 88, 125, 0.2);
}

.btn-primary:active {
  transform: translateY(0);
}

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

.btn-secondary {
  padding: 0.75rem 1.5rem;
  font-size: 0.9rem;
  background: var(--color-white);
  color: var(--color-brand-navy);
  border: 1px solid var(--color-brand-navy);
  border-radius: var(--radius-sm);
}

.btn-secondary:hover {
  background: #F5F3ED;
}

.btn-small {
  padding: 0.5rem 1.25rem;
  font-size: 0.85rem;
  background: var(--color-brand-navy);
  color: var(--color-white);
  border-radius: var(--radius-sm);
  min-height: 44px;
}

/* Slot Machine */
.slot-machine {
  background: var(--color-brand-navy);
  padding: 2rem;
  border-radius: var(--radius-lg);
  box-shadow: inset 0 5px 15px rgba(0,0,0,0.5), 0 10px 30px rgba(0, 88, 125, 0.3);
  margin: 1.5rem 0;
}

.reels {
  display: flex;
  gap: 1rem;
  background: #111;
  padding: 1.5rem;
  border-radius: var(--radius-md);
  margin-bottom: 1.5rem;
  border: 6px solid var(--color-brand-gold);
  box-shadow: inset 0 10px 30px rgba(0,0,0,0.8);
}

.reel {
  flex: 1;
  height: 140px;
  background: linear-gradient(180deg, #d4d4d4 0%, #ffffff 25%, #ffffff 75%, #d4d4d4 100%);
  border-radius: var(--radius-sm);
  overflow: hidden;
  position: relative;
  box-shadow: inset 0 5px 15px rgba(0,0,0,0.4), inset 0 -5px 15px rgba(0,0,0,0.4);
  border: 1px solid #777;
}

.reel::after {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0; bottom: 0;
  background: linear-gradient(180deg, rgba(0,0,0,0.4) 0%, rgba(255,255,255,0) 25%, rgba(255,255,255,0) 75%, rgba(0,0,0,0.4) 100%);
  pointer-events: none;
  z-index: 2;
}

.reel-strip {
  display: flex;
  flex-direction: column;
  z-index: 1;
  width: 100%;
}

.symbol {
  height: 140px;
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  box-sizing: border-box;
}

.symbol img {
  max-width: 90%;
  max-height: 90%;
  object-fit: contain;
  filter: drop-shadow(0 4px 6px rgba(0,0,0,0.15));
}

.symbol span {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--color-brand-navy);
  text-align: center;
  line-height: 1.2;
}

/* Results & Prizes */
.result-header {
  text-align: center;
  margin-bottom: 2rem;
}

.prize-box {
  background: var(--color-white);
  border: 2px dashed var(--color-brand-navy);
  border-radius: var(--radius-lg);
  padding: 2.5rem;
  text-align: center;
  margin-bottom: 2rem;
}

.prize-visual img {
  max-width: 200px;
  height: auto;
  margin: 0 auto 1.5rem auto;
  border-radius: var(--radius-sm);
  display: block;
  box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.prize-name-text {
  font-size: 1.75rem;
  margin-bottom: 1.5rem;
  color: var(--color-brand-navy);
}

.code-container, .qr-container {
  background: var(--color-bg);
  padding: 1.5rem;
  border-radius: var(--radius-sm);
  margin-bottom: 1.5rem;
  border: 1px solid var(--color-border);
}

.code-label {
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--color-text-muted);
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.code-flex {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  background: var(--color-white);
  padding: 0.5rem 0.5rem 0.5rem 1.25rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border);
}

.the-code {
  font-family: monospace;
  font-size: 1.25rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--color-brand-navy);
}

.qr-code-img {
  width: 160px;
  height: 160px;
  background: #fff;
  padding: 8px;
  border-radius: var(--radius-sm);
  display: block;
  margin: 0 auto;
  border: 1px solid var(--color-border);
}

.expiration-text {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-top: 1rem;
  font-weight: 600;
}

/* Share Box */
.share-box {
  background: var(--color-bg);
  border-left: 4px solid var(--color-brand-gold);
  padding: 2rem;
  border-radius: 0 var(--radius-lg) var(--radius-lg) 0;
}

.share-box h3 {
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.share-flex {
  display: flex;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

.share-flex input {
  flex: 1;
  padding: 0.75rem 1rem;
  background: var(--color-white);
  border: 1px solid var(--color-border);
  color: var(--color-text-body);
  border-radius: var(--radius-sm);
  font-size: 16px;
}

/* Powered By Placeholder */
#wbx-powered-by-slot {
  margin-top: auto;
  padding-top: 2rem;
  width: 100%;
}

/* Mobile Responsiveness */
@media (max-width: 600px) {
  .site-wrapper {
    padding: 1.5rem 1rem;
  }
  
  .card { 
    padding: 2.5rem 1.5rem; 
    border-radius: var(--radius-md);
  }
  
  h1 { font-size: 2.5rem; }
  h2 { font-size: 2rem; }
  
  .hero-text {
    margin-bottom: 2rem;
  }
  
  .brand-logo {
    width: 260px;
  }
  
  input[type="text"],
  input[type="email"] {
    padding: 1.125rem 1rem;
  }
  
  .btn-small, .btn-secondary {
    width: 100%;
  }

  .code-flex, .share-flex {
    flex-direction: column;
    align-items: stretch;
    padding: 1rem;
    gap: 0.75rem;
  }
  
  .the-code {
    text-align: center;
    font-size: 1.5rem;
    word-break: break-all;
  }
  
  .share-flex input {
    text-align: center;
    padding: 1.125rem 1rem;
  }

  .slot-machine { 
    padding: 1rem; 
  }
  
  .reels { 
    gap: 0.5rem; 
    padding: 1rem; 
    border-width: 4px; 
  }
  
  .reel, .symbol { 
    height: 100px; 
  }
  
  .symbol span { 
    font-size: 0.95rem; 
  }
}
