/* ==========================================================================
   Water Credit Registration - Design System & Stylesheet
   Theme: Sky Blue & White Nature Water Theme with Layered Waves
   ========================================================================== */

:root {
  --sky-primary: #0284c7;
  --sky-primary-dark: #0369a1;
  --sky-secondary: #0ea5e9;
  --sky-light: #38bdf8;
  --sky-lightest: #e0f2fe;
  --sky-bg: #f0f9ff;
  --sky-card-border: #bae6fd;

  --nature-green: #10b981;
  --nature-green-dark: #059669;
  --nature-green-light: #d1fae5;

  --white: #ffffff;
  --card-bg: #ffffff;
  --text-main: #0f172a;
  --text-muted: #64748b;
  --text-light: #94a3b8;

  --water-gradient: linear-gradient(135deg, #0284c7 0%, #0ea5e9 60%, #38bdf8 100%);
  --water-gradient-hover: linear-gradient(135deg, #0369a1 0%, #0284c7 60%, #0ea5e9 100%);
  --hero-gradient: linear-gradient(180deg, #e0f2fe 0%, #f0f9ff 50%, #ffffff 100%);
  --accent-gold: #f59e0b;

  --card-shadow: 0 10px 25px -5px rgba(2, 132, 199, 0.1), 0 8px 10px -6px rgba(2, 132, 199, 0.05);
  --card-shadow-hover: 0 20px 30px -10px rgba(2, 132, 199, 0.18), 0 10px 10px -5px rgba(2, 132, 199, 0.08);
  --btn-shadow: 0 4px 14px 0 rgba(14, 165, 233, 0.39);

  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-pill: 9999px;

  --transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --font-family: 'Mukta', 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-family);
  background-color: #0369a1;
  background: url('../assets/images/pond_background.jpg') no-repeat center top fixed;
  background-size: cover;
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
  overflow-x: hidden;
}

/* Semi-transparent nature overlay to keep scenery visible while ensuring text contrast */
body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, rgba(2, 132, 199, 0.25) 0%, rgba(224, 242, 254, 0.5) 35%, rgba(240, 249, 255, 0.8) 100%);
  backdrop-filter: blur(2px);
  -webkit-backdrop-filter: blur(2px);
  z-index: 0;
  pointer-events: none;
}

/* App Container - Centered Mobile-Friendly Presentation Width */
.app-container {
  max-width: 580px;
  width: 100%;
  margin: 0 auto;
  padding: 1.25rem 1rem 6rem;
  flex: 1;
  position: relative;
  z-index: 2;
}

/* ==========================================================================
   Header & Navbar
   ========================================================================== */
.app-header {
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1.5px solid rgba(186, 230, 253, 0.8);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 20px -2px rgba(2, 132, 199, 0.12);
}

.header-content {
  max-width: 580px;
  margin: 0 auto;
  padding: 0.65rem 1rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.brand-wrapper {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  cursor: pointer;
  text-decoration: none;
}

.brand-logo-drop {
  width: 38px;
  height: 38px;
  background: var(--water-gradient);
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 10px rgba(14, 165, 233, 0.4);
  position: relative;
  overflow: hidden;
  flex-shrink: 0;
}

.brand-logo-drop::after {
  content: '';
  position: absolute;
  top: 5px;
  left: 5px;
  width: 10px;
  height: 10px;
  background: rgba(255, 255, 255, 0.6);
  border-radius: 50%;
}

.brand-logo-icon {
  transform: rotate(45deg);
  font-size: 1.1rem;
}

.brand-text h1 {
  font-size: 1.15rem;
  font-weight: 800;
  color: var(--sky-primary-dark);
  line-height: 1.2;
}

.brand-text p {
  font-size: 0.72rem;
  color: var(--text-muted);
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

@media (max-width: 480px) {
  .brand-text p {
    display: none;
  }
  .brand-text h1 {
    font-size: 1.05rem;
  }
  .header-content {
    padding: 0.5rem 0.75rem;
  }
  .btn-lang-toggle {
    padding: 0.35rem 0.7rem;
    font-size: 0.8rem;
  }
}

/* Language Toggle Button */
.btn-lang-toggle {
  background: var(--sky-lightest);
  border: 1.5px solid var(--sky-card-border);
  color: var(--sky-primary-dark);
  font-size: 0.85rem;
  font-weight: 700;
  padding: 0.45rem 0.9rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.35rem;
  transition: var(--transition);
  box-shadow: 0 2px 6px rgba(2, 132, 199, 0.1);
}

.btn-lang-toggle:hover {
  background: var(--sky-primary);
  color: var(--white);
  border-color: var(--sky-primary);
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.35);
  transform: translateY(-1px);
}

/* Cloud Sync Status Badge */
.cloud-sync-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.28rem 0.65rem;
  border-radius: var(--radius-pill);
  background: #f1f5f9;
  border: 1px solid #cbd5e1;
  color: #475569;
  cursor: pointer;
  transition: var(--transition);
}

.cloud-sync-badge .sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #94a3b8;
  display: inline-block;
}

.cloud-sync-badge.online {
  background: #ecfdf5;
  border-color: #a7f3d0;
  color: #065f46;
}

.cloud-sync-badge.online .sync-dot {
  background: #10b981;
  box-shadow: 0 0 6px #10b981;
}

.cloud-sync-badge.syncing {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1e40af;
}

.cloud-sync-badge.syncing .sync-dot {
  background: #3b82f6;
  animation: pulseSync 1s infinite alternate;
}

@keyframes pulseSync {
  from { opacity: 0.3; transform: scale(0.8); }
  to { opacity: 1; transform: scale(1.2); }
}

@media (max-width: 480px) {
  .cloud-sync-badge .sync-label {
    display: none;
  }
  .cloud-sync-badge {
    padding: 0.35rem;
  }
}

.admin-header-link {
  font-size: 0.78rem;
  color: var(--text-muted);
  text-decoration: none;
  padding: 0.35rem 0.55rem;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  gap: 0.25rem;
  transition: var(--transition);
}

.admin-header-link:hover {
  color: var(--sky-primary);
  background: var(--sky-lightest);
}

/* ==========================================================================
   Home Screen (Reference Approved Design)
   ========================================================================== */
.home-card {
  background: rgba(255, 255, 255, 0.97);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-radius: 28px;
  border: 1.5px solid rgba(186, 230, 253, 0.95);
  box-shadow: 0 25px 50px -12px rgba(2, 132, 199, 0.28), 0 10px 20px -5px rgba(2, 132, 199, 0.12);
  padding: 2.25rem 1.6rem 2.25rem;
  text-align: center;
  position: relative;
  overflow: hidden;
  transition: var(--transition);
  margin-top: 0.5rem;
}

/* Large Blue Water-Drop Logo */
.hero-water-drop-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 1.15rem;
}

.hero-water-drop-svg {
  width: 82px;
  height: 102px;
  display: block;
  filter: drop-shadow(0 12px 20px rgba(2, 132, 199, 0.42));
  animation: gentleFloat 4s ease-in-out infinite;
}

@keyframes gentleFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

/* Headings */
.home-title-group {
  margin-bottom: 1.6rem;
}

.home-title-en {
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--sky-primary-dark);
  letter-spacing: -0.5px;
  line-height: 1.2;
}

.home-title-mr {
  font-size: 1.85rem;
  font-weight: 800;
  color: var(--sky-primary);
  line-height: 1.25;
  margin: 0.15rem 0 0.35rem;
}

.home-tagline {
  font-size: 0.92rem;
  color: var(--text-muted);
  max-width: 440px;
  margin: 0 auto;
  line-height: 1.45;
}

/* Three Feature Sections */
.feature-sections-box {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  margin-bottom: 1.75rem;
  text-align: left;
}

.feature-item-row {
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  padding: 0.9rem 1rem;
  background: var(--sky-bg);
  border: 1.2px solid var(--sky-card-border);
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.feature-item-row:hover {
  background: var(--sky-lightest);
  border-color: var(--sky-secondary);
  transform: translateY(-2px);
  box-shadow: 0 6px 16px rgba(14, 165, 233, 0.12);
}

.feature-item-icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.4rem;
  flex-shrink: 0;
  box-shadow: 0 4px 10px rgba(14, 165, 233, 0.15);
}

.feature-item-icon.blue-tint {
  background: linear-gradient(135deg, #e0f2fe 0%, #bae6fd 100%);
}
.feature-item-icon.cyan-tint {
  background: linear-gradient(135deg, #ecfdf5 0%, #a7f3d0 100%);
}
.feature-item-icon.teal-tint {
  background: linear-gradient(135deg, #eff6ff 0%, #bfdbfe 100%);
}

.feature-item-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--sky-primary-dark);
  line-height: 1.2;
}

.feature-item-sub {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--sky-secondary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.2rem;
}

.feature-item-desc {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* Two Prominent Action Buttons */
.home-action-buttons {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
  position: relative;
  z-index: 5;
}

.btn-hero-register {
  width: 100%;
  padding: 1.05rem 1.5rem;
  font-size: 1.15rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  background: var(--water-gradient);
  color: var(--white);
  box-shadow: 0 8px 24px -4px rgba(14, 165, 233, 0.5);
  border: none;
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-hero-register:hover {
  background: var(--water-gradient-hover);
  transform: translateY(-2px);
  box-shadow: 0 12px 28px -4px rgba(14, 165, 233, 0.65);
}

.btn-hero-view {
  width: 100%;
  padding: 0.95rem 1.5rem;
  font-size: 1.05rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  background: var(--white);
  color: var(--sky-primary-dark);
  border: 2px solid var(--sky-primary);
  cursor: pointer;
  transition: var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.btn-hero-view:hover {
  background: var(--sky-lightest);
  border-color: var(--sky-secondary);
  color: var(--sky-primary);
  transform: translateY(-2px);
  box-shadow: 0 4px 14px rgba(2, 132, 199, 0.15);
}

/* Subtle Bottom Wave inside Card */
.card-bottom-wave-accent {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  line-height: 0;
  pointer-events: none;
  z-index: 1;
}

.card-bottom-wave-accent svg {
  width: 100%;
  height: 38px;
  display: block;
}

@media (min-width: 768px) {
  .features-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

.feature-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--sky-card-border);
  padding: 1.5rem;
  box-shadow: var(--card-shadow);
  transition: var(--transition);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  position: relative;
  overflow: hidden;
}

.feature-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--card-shadow-hover);
  border-color: var(--sky-secondary);
}

.feature-card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--water-gradient);
}

.feature-icon-wrapper {
  width: 52px;
  height: 52px;
  border-radius: var(--radius-md);
  background: var(--sky-lightest);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin-bottom: 1rem;
  box-shadow: 0 4px 12px rgba(14, 165, 233, 0.15);
}

.feature-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--sky-primary-dark);
  margin-bottom: 0.15rem;
}

.feature-subtitle {
  font-size: 0.8rem;
  color: var(--sky-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 0.6rem;
}

.feature-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.5;
}

/* ==========================================================================
   Registration Form View (Reference Right Side: 4-Step Wizard)
   ========================================================================== */
.form-shell-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1.5px solid var(--sky-card-border);
  box-shadow: var(--card-shadow-hover);
  overflow: hidden;
  margin-top: 1.5rem;
}

/* Blue Header on Registration Card */
.form-card-header {
  background: var(--water-gradient);
  color: var(--white);
  padding: 1.25rem 1.5rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  position: relative;
}

.form-header-title-group {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.form-header-icon {
  font-size: 1.75rem;
}

.form-header-title-group h3 {
  font-size: 1.35rem;
  font-weight: 700;
  line-height: 1.2;
}

.form-header-title-group p {
  font-size: 0.85rem;
  opacity: 0.9;
}

.btn-header-back {
  background: rgba(255, 255, 255, 0.2);
  border: 1px solid rgba(255, 255, 255, 0.4);
  color: var(--white);
  padding: 0.4rem 0.85rem;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  transition: var(--transition);
}

.btn-header-back:hover {
  background: rgba(255, 255, 255, 0.35);
}

/* Stepper Progress Bar */
.stepper-container {
  padding: 1.25rem 1.5rem 0.75rem;
  background: var(--sky-bg);
  border-bottom: 1px solid var(--sky-card-border);
}

.stepper-track {
  position: relative;
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.5rem;
}

.stepper-line-bg {
  position: absolute;
  top: 50%;
  left: 0;
  width: 100%;
  height: 4px;
  background: #cbd5e1;
  transform: translateY(-50%);
  z-index: 1;
  border-radius: var(--radius-pill);
}

.stepper-line-fill {
  position: absolute;
  top: 50%;
  left: 0;
  height: 4px;
  background: var(--sky-primary);
  transform: translateY(-50%);
  z-index: 2;
  border-radius: var(--radius-pill);
  transition: width 0.35s ease;
}

.stepper-node {
  position: relative;
  z-index: 3;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--white);
  border: 2.5px solid #cbd5e1;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.9rem;
  transition: var(--transition);
}

.stepper-node.active {
  background: var(--sky-primary);
  border-color: var(--sky-primary);
  color: var(--white);
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.25);
  transform: scale(1.08);
}

.stepper-node.completed {
  background: var(--nature-green);
  border-color: var(--nature-green);
  color: var(--white);
}

.stepper-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 0.35rem;
}

.stepper-label-text {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--text-muted);
  text-align: center;
  width: 75px;
}

.stepper-node.active + .stepper-label-text {
  color: var(--sky-primary-dark);
}

/* Wizard Step Panes */
.wizard-step-pane {
  display: none;
  padding: 1.5rem;
  animation: fadeIn 0.3s ease-in-out;
}

.wizard-step-pane.active {
  display: block;
}

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

/* Form Groups & Inputs */
.form-section-title {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--sky-primary-dark);
  margin-bottom: 0.4rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.form-section-desc {
  font-size: 0.875rem;
  color: var(--text-muted);
  margin-bottom: 1.25rem;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 600px) {
  .form-grid.two-col {
    grid-template-columns: 1fr 1fr;
  }
  .form-grid.three-col {
    grid-template-columns: repeat(3, 1fr);
  }
}

.form-group {
  margin-bottom: 1rem;
  position: relative;
}

.form-group label {
  display: block;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-main);
  margin-bottom: 0.35rem;
}

.form-group label .req {
  color: #ef4444;
  margin-left: 2px;
}

.form-control {
  width: 100%;
  padding: 0.8rem 1rem;
  font-size: 0.95rem;
  font-family: var(--font-family);
  background: var(--white);
  border: 1.5px solid #cbd5e1;
  border-radius: var(--radius-md);
  color: var(--text-main);
  transition: var(--transition);
  outline: none;
}

.form-control:focus {
  border-color: var(--sky-secondary);
  box-shadow: 0 0 0 3px rgba(14, 165, 233, 0.2);
}

.form-control.input-error {
  border-color: #ef4444;
  background-color: #fef2f2;
}

.field-error-msg {
  color: #ef4444;
  font-size: 0.78rem;
  font-weight: 600;
  margin-top: 0.3rem;
}

.checkbox-group {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.35rem;
  font-size: 0.85rem;
  color: var(--text-muted);
  cursor: pointer;
}

.checkbox-group input[type="checkbox"] {
  width: 18px;
  height: 18px;
  accent-color: var(--sky-primary);
  cursor: pointer;
}

/* Radio Cards (Pond Status) */
.radio-cards-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.6rem;
  margin-top: 0.35rem;
}

.radio-card {
  position: relative;
  border: 1.5px solid #cbd5e1;
  border-radius: var(--radius-md);
  padding: 0.75rem 0.5rem;
  text-align: center;
  cursor: pointer;
  transition: var(--transition);
  background: var(--white);
}

.radio-card input[type="radio"] {
  position: absolute;
  opacity: 0;
}

.radio-card:has(input[type="radio"]:checked) {
  border-color: var(--sky-primary);
  background: var(--sky-lightest);
  box-shadow: 0 2px 8px rgba(14, 165, 233, 0.15);
}

.radio-card-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-main);
}

/* Capacity Calculator Result Badge */
.capacity-badge-box {
  background: var(--sky-lightest);
  border: 1.5px solid var(--sky-card-border);
  border-radius: var(--radius-md);
  padding: 0.85rem 1rem;
  margin-top: 0.5rem;
  display: none;
  font-size: 0.95rem;
  color: var(--sky-primary-dark);
}

.badge-credits {
  background: #fef3c7;
  color: #b45309;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-pill);
  font-weight: 700;
  display: inline-block;
  margin-left: 0.3rem;
}

/* ==========================================================================
   GPS Section
   ========================================================================== */
.gps-capture-card {
  background: var(--sky-bg);
  border: 1.5px dashed var(--sky-secondary);
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  text-align: center;
  margin-bottom: 1.25rem;
}

.btn-gps-capture {
  background: var(--water-gradient);
  color: var(--white);
  padding: 0.9rem 1.6rem;
  font-size: 1.05rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  box-shadow: var(--btn-shadow);
  transition: var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

.btn-gps-capture:hover {
  transform: scale(1.03);
  box-shadow: 0 6px 20px rgba(14, 165, 233, 0.45);
}

.btn-gps-capture.loading {
  opacity: 0.75;
  cursor: wait;
}

.gps-status {
  margin-top: 0.75rem;
  font-size: 0.875rem;
  font-weight: 600;
}

.gps-status.status-loading { color: var(--sky-primary); }
.gps-status.status-success { color: var(--nature-green-dark); }
.gps-status.status-error { color: #ef4444; }
.gps-status.status-info { color: var(--sky-primary-dark); }

.accuracy-badge {
  display: inline-block;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 700;
  margin-left: 0.4rem;
}

.acc-high { background: #d1fae5; color: #065f46; }
.acc-med { background: #fef3c7; color: #92400e; }
.acc-low { background: #fee2e2; color: #991b1b; }

.map-container {
  height: 220px;
  width: 100%;
  border-radius: var(--radius-md);
  border: 1px solid var(--sky-card-border);
  margin-top: 1rem;
  overflow: hidden;
  background: #e2e8f0;
  position: relative;
  z-index: 5;
}

.map-fallback-card {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 100%;
  gap: 1rem;
  padding: 1rem;
}

.map-crosshair {
  font-size: 2.5rem;
}

/* Leaflet Custom Marker */
.custom-water-marker .marker-pin {
  width: 36px;
  height: 42px;
  background: var(--sky-primary);
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.3);
}

.custom-water-marker .marker-drop {
  transform: rotate(45deg);
  font-size: 1.2rem;
}

/* ==========================================================================
   Photo Uploader Section
   ========================================================================== */
.photo-slots-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 600px) {
  .photo-slots-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.photo-slot-card {
  border: 1.5px solid var(--sky-card-border);
  border-radius: var(--radius-lg);
  padding: 1rem;
  background: var(--sky-bg);
  transition: var(--transition);
}

.photo-slot-header {
  margin-bottom: 0.6rem;
}

.photo-slot-header h5 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--sky-primary-dark);
}

.photo-slot-header p {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.photo-dropzone {
  border: 2px dashed #93c5fd;
  border-radius: var(--radius-md);
  background: var(--white);
  min-height: 140px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  transition: var(--transition);
}

.photo-dropzone:hover {
  border-color: var(--sky-primary);
  background: var(--sky-lightest);
}

.photo-dropzone.has-photo {
  border-style: solid;
  border-color: var(--nature-green);
}

.photo-placeholder {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 1rem;
  text-align: center;
}

.photo-upload-icon {
  font-size: 2rem;
  color: var(--sky-secondary);
}

.photo-upload-text {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--sky-primary);
}

.photo-preview-img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  display: none;
}

.photo-slot-actions {
  display: none;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.btn-photo-action {
  flex: 1;
  padding: 0.4rem 0.6rem;
  font-size: 0.78rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid #cbd5e1;
  background: var(--white);
  cursor: pointer;
  transition: var(--transition);
}

.btn-photo-action.remove {
  color: #ef4444;
  border-color: #fca5a5;
}

.btn-photo-action.remove:hover {
  background: #fef2f2;
}

.photo-badge {
  position: absolute;
  top: 6px;
  right: 6px;
  background: var(--nature-green);
  color: var(--white);
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.2rem 0.5rem;
  border-radius: var(--radius-pill);
  display: none;
  z-index: 5;
}

/* ==========================================================================
   Review & Submit Pane
   ========================================================================== */
.review-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 600px) {
  .review-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.review-card {
  background: var(--sky-bg);
  border: 1.5px solid var(--sky-card-border);
  border-radius: var(--radius-md);
  padding: 1rem;
}

.review-card.highlight-card {
  background: #f0fdf4;
  border-color: #86efac;
}

.review-card.full-width {
  grid-column: 1 / -1;
}

.review-card-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.6rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.06);
  padding-bottom: 0.4rem;
}

.review-card-header h4 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--sky-primary-dark);
}

.review-card-body p {
  font-size: 0.85rem;
  margin-bottom: 0.3rem;
  color: var(--text-main);
}

.highlight-val {
  font-size: 1.05rem;
  font-weight: 800;
  color: var(--sky-primary);
}

.credits-pill {
  background: #fef3c7;
  color: #b45309;
  padding: 0.2rem 0.6rem;
  border-radius: var(--radius-pill);
  font-weight: 700;
  display: inline-block;
}

.review-thumbnails-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 0.6rem;
  margin-top: 0.5rem;
}

.review-thumb-item {
  text-align: center;
}

.review-thumb-item img {
  width: 100%;
  height: 80px;
  object-fit: cover;
  border-radius: var(--radius-sm);
  border: 1px solid var(--sky-card-border);
}

.thumb-empty {
  height: 80px;
  background: #e2e8f0;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.thumb-caption {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--text-muted);
  margin-top: 0.2rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.declaration-box {
  background: #fffbeb;
  border: 1.5px solid #fde68a;
  border-radius: var(--radius-md);
  padding: 1rem;
  margin: 1.25rem 0;
}

/* Wizard Footer Navigation Bar */
.wizard-footer-nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  background: var(--sky-bg);
  border-top: 1px solid var(--sky-card-border);
}

/* ==========================================================================
   Success Screen & Private Link Box
   ========================================================================== */
.success-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1.5px solid var(--nature-green);
  box-shadow: var(--card-shadow-hover);
  padding: 2.25rem 1.5rem;
  text-align: center;
  margin-top: 1.5rem;
}

.success-icon-drop {
  width: 72px;
  height: 72px;
  background: var(--water-gradient);
  border-radius: 50% 50% 50% 0;
  transform: rotate(-45deg);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.5rem;
  box-shadow: 0 10px 20px rgba(14, 165, 233, 0.35);
}

.success-icon-drop span {
  transform: rotate(45deg);
  font-size: 2.25rem;
}

.success-card h2 {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--sky-primary-dark);
  margin-bottom: 0.35rem;
}

.success-card .success-sub {
  font-size: 1rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.reg-id-display-box {
  background: var(--sky-lightest);
  border: 2px dashed var(--sky-primary);
  border-radius: var(--radius-lg);
  padding: 1rem;
  display: inline-block;
  margin-bottom: 1.5rem;
}

.reg-id-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--sky-primary);
  text-transform: uppercase;
}

.reg-id-val {
  font-size: 1.75rem;
  font-weight: 800;
  color: var(--sky-primary-dark);
  letter-spacing: 1px;
}

.success-sync-banner {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  padding: 0.45rem 1.1rem;
  border-radius: var(--radius-pill);
  font-size: 0.85rem;
  font-weight: 700;
  margin: 0 auto 1.5rem;
  background: #ecfdf5;
  border: 1.5px solid #a7f3d0;
  color: #065f46;
}

.success-sync-banner.pending {
  background: #eff6ff;
  border-color: #bfdbfe;
  color: #1e40af;
}

.success-sync-banner.local {
  background: #f8fafc;
  border-color: #cbd5e1;
  color: #475569;
}

.success-metrics-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
  max-width: 480px;
  margin: 0 auto 1.5rem;
}

.succ-metric-item {
  background: var(--sky-bg);
  border: 1px solid var(--sky-card-border);
  border-radius: var(--radius-md);
  padding: 0.75rem;
}

.succ-metric-val {
  display: block;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--sky-primary-dark);
}

.succ-metric-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.private-link-box {
  background: #f8fafc;
  border: 1.5px solid #cbd5e1;
  border-radius: var(--radius-lg);
  padding: 1.25rem;
  max-width: 580px;
  margin: 0 auto 1.75rem;
  text-align: left;
}

.private-link-header {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 0.35rem;
}

.private-link-notice {
  font-size: 0.8rem;
  color: var(--text-muted);
  margin-bottom: 0.75rem;
  line-height: 1.4;
}

.private-link-input-row {
  display: flex;
  gap: 0.5rem;
}

.private-link-input-row input {
  flex: 1;
  font-size: 0.85rem;
  background: var(--white);
  border: 1px solid #cbd5e1;
  border-radius: var(--radius-md);
  padding: 0.6rem 0.85rem;
  color: var(--text-main);
}

.success-action-btns {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  max-width: 480px;
  margin: 0 auto;
}

@media (min-width: 480px) {
  .success-action-btns {
    flex-direction: row;
  }
}

/* ==========================================================================
   View Registration Info Modal / Screen
   ========================================================================== */
.view-info-search-box {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--sky-card-border);
  padding: 1.5rem;
  box-shadow: var(--card-shadow);
  margin-top: 1.5rem;
  text-align: center;
}

.search-input-group {
  display: flex;
  flex-direction: column;
  gap: 0.6rem;
  max-width: 520px;
  margin: 1.25rem auto 0;
}

@media (min-width: 480px) {
  .search-input-group {
    flex-direction: row;
  }
}

.search-input-group input {
  flex: 1;
}

.empty-results-box {
  padding: 2.5rem 1rem;
  text-align: center;
  color: var(--text-muted);
}

.empty-results-box .empty-icon {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 0.5rem;
}

/* Printable Farmer Slip */
.farmer-reg-card {
  background: var(--white);
  border-radius: var(--radius-lg);
  border: 1.5px solid var(--sky-card-border);
  box-shadow: var(--card-shadow-hover);
  padding: 1.75rem;
  margin-top: 1.5rem;
}

.farmer-slip-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 2px solid var(--sky-lightest);
  padding-bottom: 1rem;
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.slip-brand {
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.slip-logo {
  font-size: 2rem;
}

.slip-brand h3 {
  font-size: 1.25rem;
  color: var(--sky-primary-dark);
}

.slip-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
}

.slip-meta {
  text-align: right;
}

.slip-id {
  display: block;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--sky-primary);
}

.status-tag {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-pill);
  font-size: 0.75rem;
  font-weight: 700;
  margin-top: 0.25rem;
}

.status-pending { background: #fef3c7; color: #92400e; }
.status-verified { background: #e0f2fe; color: #0369a1; }
.status-approved { background: #d1fae5; color: #065f46; }

.slip-credits-banner {
  background: var(--water-gradient);
  color: var(--white);
  border-radius: var(--radius-md);
  padding: 1rem 1.5rem;
  display: flex;
  justify-content: space-around;
  align-items: center;
  margin-bottom: 1.5rem;
  box-shadow: var(--btn-shadow);
}

.slip-credits-banner .banner-item {
  text-align: center;
}

.slip-credits-banner .b-label {
  display: block;
  font-size: 0.75rem;
  opacity: 0.9;
}

.slip-credits-banner .b-val {
  font-size: 1.4rem;
  font-weight: 800;
}

.banner-divider {
  width: 1px;
  height: 36px;
  background: rgba(255, 255, 255, 0.4);
}

.slip-details-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

@media (min-width: 600px) {
  .slip-details-grid {
    grid-template-columns: 1fr 1fr;
  }
}

.slip-box {
  background: var(--sky-bg);
  border: 1px solid var(--sky-card-border);
  border-radius: var(--radius-md);
  padding: 1rem;
}

.slip-box.full-span {
  grid-column: 1 / -1;
}

.slip-box h5 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--sky-primary-dark);
  margin-bottom: 0.5rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.05);
  padding-bottom: 0.35rem;
}

.slip-box p {
  font-size: 0.85rem;
  margin-bottom: 0.35rem;
}

.slip-photos-section {
  margin-top: 1.25rem;
}

.slip-photos-section h5 {
  font-size: 0.95rem;
  font-weight: 700;
  color: var(--sky-primary-dark);
  margin-bottom: 0.5rem;
}

.slip-photos-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem;
}

@media (min-width: 600px) {
  .slip-photos-grid {
    grid-template-columns: repeat(4, 1fr);
  }
}

.slip-photo-box {
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--sky-card-border);
  background: var(--sky-bg);
  text-align: center;
}

.slip-photo-box img {
  width: 100%;
  height: 110px;
  object-fit: cover;
}

.slip-photo-box span {
  display: block;
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.3rem 0.2rem;
  color: var(--text-muted);
}

.slip-footer-actions {
  display: flex;
  justify-content: flex-end;
  gap: 0.75rem;
  margin-top: 1.5rem;
  padding-top: 1rem;
  border-top: 1px solid var(--sky-card-border);
}

/* ==========================================================================
   Admin Portal View & PIN Authentication
   ========================================================================== */
.admin-auth-card {
  max-width: 440px;
  margin: 1.5rem auto;
  background: rgba(255, 255, 255, 0.98);
  backdrop-filter: blur(16px);
  border-radius: 28px;
  border: 1.5px solid rgba(186, 230, 253, 0.95);
  box-shadow: 0 25px 50px -12px rgba(2, 132, 199, 0.28), 0 10px 20px -5px rgba(2, 132, 199, 0.12);
  padding: 2.25rem 1.75rem;
  text-align: center;
}

.auth-icon-shield {
  width: 72px;
  height: 72px;
  margin: 0 auto 1.25rem;
  background: var(--water-gradient);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2.2rem;
  box-shadow: 0 8px 24px rgba(14, 165, 233, 0.35);
  animation: pulseShield 3s ease-in-out infinite;
}

@keyframes pulseShield {
  0%, 100% { transform: scale(1); box-shadow: 0 8px 24px rgba(14, 165, 233, 0.35); }
  50% { transform: scale(1.05); box-shadow: 0 12px 30px rgba(14, 165, 233, 0.55); }
}

.admin-auth-card h3 {
  font-size: 1.45rem;
  font-weight: 800;
  color: var(--sky-primary-dark);
  margin-bottom: 0.35rem;
}

.auth-subtitle {
  font-size: 0.85rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
  line-height: 1.4;
}

.pin-input-wrap {
  position: relative;
  display: flex;
  align-items: center;
}

.pin-field {
  font-size: 1.5rem !important;
  letter-spacing: 6px;
  text-align: center;
  padding: 0.75rem 2.8rem 0.75rem 1rem !important;
  font-weight: 700;
  color: var(--sky-primary-dark);
  border: 2px solid #cbd5e1;
  border-radius: var(--radius-lg);
  transition: var(--transition);
}

.pin-field:focus {
  border-color: var(--sky-primary);
  box-shadow: 0 0 0 4px rgba(14, 165, 233, 0.2);
}

.btn-toggle-eye {
  position: absolute;
  right: 12px;
  background: transparent;
  border: none;
  font-size: 1.15rem;
  cursor: pointer;
  padding: 4px;
  color: var(--text-muted);
}

.auth-error-msg {
  color: #dc2626;
  font-size: 0.82rem;
  font-weight: 600;
  margin-top: 0.5rem;
  text-align: center;
}

.auth-action-row {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
  margin-top: 1.5rem;
}

.btn {
  font-family: var(--font-family);
  font-size: 1rem;
  font-weight: 700;
  border-radius: var(--radius-pill);
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.75rem 1.4rem;
  transition: var(--transition);
  text-decoration: none;
  border: none;
}

.btn-primary {
  background: var(--water-gradient);
  color: #ffffff !important;
  box-shadow: 0 4px 15px rgba(14, 165, 233, 0.4);
}

.btn-primary:hover {
  box-shadow: 0 6px 20px rgba(14, 165, 233, 0.55);
  transform: translateY(-1px);
}

.btn-secondary {
  background: #ffffff;
  color: var(--sky-primary-dark) !important;
  border: 1.5px solid var(--sky-primary);
  box-shadow: 0 2px 8px rgba(2, 132, 199, 0.08);
}

.btn-secondary:hover {
  background: var(--sky-lightest);
  border-color: var(--sky-primary-dark);
}

.btn-block {
  width: 100%;
  display: flex;
  justify-content: center;
  padding: 0.85rem 1rem;
}

.shake-error {
  animation: shakeAuth 0.5s ease-in-out;
}

@keyframes shakeAuth {
  0%, 100% { transform: translateX(0); }
  20%, 60% { transform: translateX(-10px); }
  40%, 80% { transform: translateX(10px); }
}

.admin-officer-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  color: #065f46;
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.25rem 0.65rem;
  border-radius: var(--radius-pill);
  margin-bottom: 0.4rem;
}

.btn-danger-soft {
  background: #fef2f2;
  border: 1.5px solid #fecaca;
  color: #b91c1c;
  padding: 0.45rem 0.85rem;
  border-radius: var(--radius-md);
  font-size: 0.82rem;
  font-weight: 700;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  transition: var(--transition);
}

.btn-danger-soft:hover {
  background: #fee2e2;
  border-color: #fca5a5;
  color: #991b1b;
}

.admin-header-actions {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.admin-card {
  background: var(--white);
  border-radius: var(--radius-xl);
  border: 1.5px solid var(--sky-card-border);
  box-shadow: var(--card-shadow);
  padding: 1.5rem;
  margin-top: 1.5rem;
}

.admin-header-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.admin-header-row h3 {
  font-size: 1.35rem;
  color: var(--sky-primary-dark);
  font-weight: 800;
}

.admin-metrics-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}

.admin-metric-card {
  background: var(--sky-bg);
  border: 1px solid var(--sky-card-border);
  border-radius: var(--radius-md);
  padding: 0.75rem;
  text-align: center;
}

.admin-metric-card .val {
  display: block;
  font-size: 1.3rem;
  font-weight: 800;
  color: var(--sky-primary-dark);
}

.admin-metric-card .lbl {
  font-size: 0.75rem;
  color: var(--text-muted);
  font-weight: 600;
}

.admin-filters-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
  margin-bottom: 1rem;
}

.admin-filters-bar input,
.admin-filters-bar select {
  font-size: 0.85rem;
  padding: 0.5rem 0.75rem;
  border-radius: var(--radius-md);
  border: 1.5px solid #cbd5e1;
}

.admin-filters-bar input {
  flex: 1;
  min-width: 200px;
}

.table-responsive {
  overflow-x: auto;
  border-radius: var(--radius-md);
  border: 1px solid var(--sky-card-border);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.85rem;
  text-align: left;
}

.admin-table th {
  background: var(--sky-lightest);
  color: var(--sky-primary-dark);
  font-weight: 700;
  padding: 0.75rem;
  border-bottom: 1.5px solid var(--sky-card-border);
}

.admin-table td {
  padding: 0.75rem;
  border-bottom: 1px solid #e2e8f0;
}

.admin-table tr:hover {
  background: #f8fafc;
}

.action-btn-group {
  display: flex;
  gap: 0.35rem;
}

.btn-action {
  border: none;
  background: #f1f5f9;
  padding: 0.35rem 0.55rem;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: 0.85rem;
  transition: var(--transition);
}

.btn-action:hover {
  background: var(--sky-lightest);
}

/* ==========================================================================
   Animated Layered Footer Water Waves
   ========================================================================== */
.footer-wave-wrapper {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  overflow: hidden;
  line-height: 0;
  pointer-events: none;
  z-index: 1;
}

.wave-svg {
  position: relative;
  display: block;
  width: calc(100% + 1.3px);
  height: 90px;
}

.wave-layer-1 {
  fill: rgba(14, 165, 233, 0.12);
  animation: waveMotion1 12s cubic-bezier(0.36, 0.45, 0.63, 0.53) infinite;
}

.wave-layer-2 {
  fill: rgba(2, 132, 199, 0.18);
  animation: waveMotion2 8s cubic-bezier(0.36, 0.45, 0.63, 0.53) -2s infinite;
}

.wave-layer-3 {
  fill: rgba(56, 189, 248, 0.25);
  animation: waveMotion3 6s cubic-bezier(0.36, 0.45, 0.63, 0.53) -1s infinite;
}

@keyframes waveMotion1 {
  0% { transform: translateX(0); }
  50% { transform: translateX(-25px); }
  100% { transform: translateX(0); }
}

@keyframes waveMotion2 {
  0% { transform: translateX(0); }
  50% { transform: translateX(30px); }
  100% { transform: translateX(0); }
}

@keyframes waveMotion3 {
  0% { transform: translateX(0); }
  50% { transform: translateX(-15px); }
  100% { transform: translateX(0); }
}

/* ==========================================================================
   Print Styles
   ========================================================================== */
@media print {
  body {
    background: #ffffff !important;
    background-image: none !important;
  }
  .app-header,
  .hero-section,
  .footer-wave-wrapper,
  .no-print,
  .wizard-footer-nav,
  .btn-header-back {
    display: none !important;
  }
  .app-container {
    max-width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  .printable-slip {
    box-shadow: none !important;
    border: 1px solid #000 !important;
  }
}
