/* ==========================================================================
   CAREVIA - Men's Health & Vitality Portal (Hrvatska)
   Sleek Darker Background with High-Contrast Whitehat Cards & Bio-Teal
   ========================================================================== */

:root {
  --primary-deep: #0b2545;
  --primary: #134074;
  --primary-light: #1d5899;
  --primary-gradient: linear-gradient(135deg, #0b2545 0%, #134074 50%, #008779 100%);
  
  --accent-teal: #00a896;
  --accent-mint: #02c39a;
  --accent-soft: rgba(230, 248, 245, 0.9);
  --accent-glow: rgba(0, 168, 150, 0.35);
  
  --coral-accent: #f77f00;
  --gold-warm: #d97706;
  --gold-soft: #fef3c7;
  
  --navy-darkest: #06101c;
  --navy-surface: #0e2238;
  --navy-border: rgba(255, 255, 255, 0.14);
  
  --text-main: #1e293b;
  --text-muted: #52637a;
  --text-light: #f8fafc;
  --text-teal: #0f766e;
  
  --bg-page: #0f1e2f;
  --bg-card: rgba(255, 255, 255, 0.96);
  --bg-card-solid: #ffffff;
  --bg-subtle: rgba(233, 242, 245, 0.9);
  --border: #d3e0e6;
  
  --error-red: #ef4444;
  --error-glow: 0 0 16px rgba(239, 68, 68, 0.65), 0 0 0 3px rgba(239, 68, 68, 0.35);
  --success-green: #10b981;
  --success-glow: 0 0 16px rgba(16, 185, 129, 0.5), 0 0 0 3px rgba(16, 185, 129, 0.2);
  
  --shadow-sm: 0 2px 6px rgba(6, 16, 28, 0.08);
  --shadow-md: 0 8px 24px rgba(6, 16, 28, 0.16);
  --shadow-lg: 0 16px 36px rgba(6, 16, 28, 0.22);
  --shadow-xl: 0 24px 48px rgba(6, 16, 28, 0.3);
  
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 20px;
  --radius-full: 9999px;
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --transition: 0.25s cubic-bezier(0.2, 0, 0, 1);
}

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

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

/* Body with Rich Darker Semi-Transparent Fixed Background Photo */
body {
  font-family: var(--font-family);
  background-color: var(--bg-page);
  background-image: 
    linear-gradient(rgba(10, 24, 40, 0.82), rgba(10, 24, 40, 0.86)),
    url('../assets/images/wellness_bg.jpg');
  background-attachment: fixed;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
  color: var(--text-main);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

main {
  flex: 1;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: inherit;
  text-decoration: none;
}

button, input, select, textarea {
  font: inherit;
}

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

/* Top Notification Banner */
.top-notice-bar {
  background: var(--navy-darkest);
  color: #94a3b8;
  font-size: 0.82rem;
  padding: 8px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.top-notice-bar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
}

.notice-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--accent-mint);
  font-weight: 700;
}

/* Header */
.main-header {
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.55rem;
  font-weight: 800;
  color: var(--primary-deep);
  letter-spacing: -0.5px;
}

.brand-logo .logo-icon {
  width: 38px;
  height: 38px;
  background: var(--primary-gradient);
  color: #ffffff;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.15rem;
  box-shadow: 0 4px 12px var(--accent-glow);
}

.brand-logo span span {
  color: var(--accent-teal);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-link {
  padding: 8px 14px;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  font-weight: 600;
  color: #475569;
  transition: all var(--transition);
}

.nav-link:hover {
  color: var(--primary);
  background: var(--accent-soft);
}

.nav-link.active {
  color: var(--primary-deep);
  background: var(--accent-soft);
  font-weight: 700;
}

.nav-cta-btn {
  background: var(--primary-gradient);
  color: #ffffff !important;
  padding: 10px 20px;
  border-radius: var(--radius-full);
  font-size: 0.88rem;
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 14px rgba(0, 168, 150, 0.3);
  transition: transform var(--transition), box-shadow var(--transition);
}

.nav-cta-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0, 168, 150, 0.45);
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  font-size: 1.4rem;
  color: var(--primary-deep);
  cursor: pointer;
  padding: 6px;
}

/* Page Hero Header */
.page-hero {
  padding: 46px 0 36px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.92) 0%, rgba(241, 246, 248, 0.85) 100%);
  border-bottom: 1px solid var(--border);
}

.page-hero-center {
  text-align: center;
  max-width: 800px;
  margin: 0 auto;
}

.badge-tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent-soft);
  color: var(--text-teal);
  font-size: 0.82rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  padding: 5px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 14px;
  border: 1px solid rgba(0, 168, 150, 0.25);
}

.hero-title {
  font-size: 2.25rem;
  font-weight: 800;
  line-height: 1.25;
  color: var(--primary-deep);
  margin-bottom: 16px;
  letter-spacing: -0.5px;
}

.hero-subtitle {
  font-size: 1.06rem;
  color: var(--text-muted);
  line-height: 1.65;
}

/* Home Split Hero */
.home-hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 36px;
  align-items: center;
  padding: 24px 0 16px;
}

.hero-trainer-preview {
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  border-radius: var(--radius-lg);
  padding: 26px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  text-align: center;
}

.hero-trainer-preview img {
  width: 140px;
  height: 140px;
  border-radius: 50%;
  margin: 0 auto 14px;
  object-fit: cover;
  border: 4px solid var(--accent-teal);
  box-shadow: 0 6px 18px rgba(0, 168, 150, 0.25);
}

/* Portal Nav Cards */
.portal-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin: 34px 0 50px;
}

.portal-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  padding: 30px 26px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  transition: all var(--transition);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.portal-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent-teal);
  box-shadow: var(--shadow-lg);
  background: #ffffff;
}

.portal-card-icon {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  background: var(--accent-soft);
  color: var(--accent-teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.35rem;
  margin-bottom: 18px;
}

.portal-card h3 {
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 8px;
}

.portal-card p {
  font-size: 0.92rem;
  color: var(--text-muted);
  line-height: 1.6;
  margin-bottom: 20px;
  flex-grow: 1;
}

.portal-card-link {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--primary);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: gap var(--transition);
}

.portal-card:hover .portal-card-link {
  gap: 10px;
  color: var(--accent-teal);
}

/* Content Cards & Sections */
.content-section {
  padding: 40px 0 60px;
}

.article-content-card {
  background: var(--bg-card);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-lg);
  padding: 40px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  margin-bottom: 30px;
}

.article-content-card h2 {
  font-size: 1.48rem;
  font-weight: 800;
  color: var(--primary-deep);
  margin: 32px 0 16px;
  letter-spacing: -0.3px;
}

.article-content-card h2:first-of-type {
  margin-top: 0;
}

.article-content-card p {
  font-size: 1.02rem;
  color: #334155;
  line-height: 1.75;
  margin-bottom: 18px;
}

.narrative-step-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-gradient);
  color: #ffffff;
  padding: 4px 12px;
  border-radius: var(--radius-full);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 10px;
}

.highlight-box {
  background: linear-gradient(135deg, rgba(230, 248, 245, 0.92) 0%, rgba(237, 249, 246, 0.96) 100%);
  border-left: 4px solid var(--accent-teal);
  padding: 22px 26px;
  border-radius: 0 var(--radius-md) var(--radius-md) 0;
  margin: 26px 0;
  font-style: italic;
  font-size: 1.05rem;
  color: var(--primary-deep);
}

/* Ingredients Grid */
.ingredients-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 20px;
  margin: 26px 0;
}

.ingredient-card {
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 22px;
  display: flex;
  align-items: flex-start;
  gap: 16px;
  box-shadow: var(--shadow-sm);
  transition: transform var(--transition);
}

.ingredient-card:hover {
  transform: translateY(-3px);
  border-color: var(--accent-teal);
  background: #ffffff;
}

.ing-icon {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent-teal);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}

.ing-info h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 6px;
}

.ing-info p {
  font-size: 0.88rem;
  color: var(--text-muted);
  line-height: 1.5;
  margin: 0;
}

/* Certificates Layout */
.cert-page-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
  margin: 24px 0 40px;
}

.cert-box {
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 30px;
  display: flex;
  align-items: flex-start;
  gap: 20px;
  box-shadow: var(--shadow-sm);
  transition: all var(--transition);
}

.cert-box:hover {
  border-color: var(--accent-teal);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  background: #ffffff;
}

.cert-badge-round {
  width: 56px;
  height: 56px;
  background: var(--primary-gradient);
  color: #ffffff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  flex-shrink: 0;
  box-shadow: 0 4px 12px var(--accent-glow);
}

.cert-content h3 {
  font-size: 1.18rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 4px;
}

.cert-code-tag {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--text-teal);
  background: var(--accent-soft);
  padding: 2px 10px;
  border-radius: var(--radius-full);
  margin-bottom: 8px;
}

.cert-content p {
  font-size: 0.9rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin: 0;
}

/* Dual User Edition */
.dual-section-header {
  margin: 36px 0 22px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.dual-section-header h3 {
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--primary-deep);
  display: flex;
  align-items: center;
  gap: 8px;
}

.reviews-grid-clean {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin-bottom: 40px;
}

.review-item-card {
  background: var(--bg-card);
  backdrop-filter: blur(8px);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.review-user-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px;
}

.avatar-initials {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: var(--primary-gradient);
  color: #ffffff;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
}

.review-stars-gold {
  color: #f59e0b;
  font-size: 0.88rem;
  margin-bottom: 8px;
}

.review-item-card p {
  font-size: 0.92rem;
  color: #334155;
  line-height: 1.6;
  margin-bottom: 16px;
  flex-grow: 1;
}

.review-location-tag {
  font-size: 0.8rem;
  color: var(--text-muted);
  font-weight: 500;
}

/* Order Form Page */
.order-page-wrapper {
  display: grid;
  grid-template-columns: 0.9fr 1.1fr;
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  border-radius: var(--radius-lg);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg);
  overflow: hidden;
  margin: 20px 0 50px;
}

.order-left-summary {
  background: var(--primary-gradient);
  color: #ffffff;
  padding: 44px 38px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.order-left-summary h3 {
  font-size: 1.65rem;
  font-weight: 800;
  margin-bottom: 12px;
}

.order-left-summary p {
  font-size: 0.94rem;
  color: #d1fae5;
  line-height: 1.6;
  margin-bottom: 20px;
}

.order-bottle-center {
  text-align: center;
  margin: 10px 0 20px;
}

.order-bottle-center img {
  max-height: 220px;
  margin: 0 auto;
  border-radius: var(--radius-md);
  box-shadow: 0 12px 28px rgba(0,0,0,0.35);
}

.order-check-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
  font-size: 0.88rem;
  color: #f0fdf4;
}

.order-check-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.order-check-list li i {
  color: var(--accent-mint);
}

.order-form-container {
  padding: 44px 38px;
}

.form-title {
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--primary-deep);
  margin-bottom: 6px;
}

.form-subtitle {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 24px;
}

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

.input-label {
  display: block;
  font-size: 0.88rem;
  font-weight: 700;
  color: var(--primary-deep);
  margin-bottom: 6px;
}

.input-box-wrapper {
  position: relative;
}

.input-box-wrapper i {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: #94a3b8;
  font-size: 1rem;
}

.text-input {
  width: 100%;
  padding: 13px 14px 13px 42px;
  border-radius: var(--radius-md);
  border: 1.5px solid var(--border);
  background: #f8fafc;
  font-size: 0.95rem;
  color: var(--text-main);
  transition: all var(--transition);
}

.text-input:focus {
  outline: none;
  background: #ffffff;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

/* Intense Red Glow for Invalid Phone */
.text-input.is-invalid {
  border-color: var(--error-red) !important;
  background: #fff5f5 !important;
  box-shadow: var(--error-glow) !important;
  animation: shake 0.3s ease-in-out;
}

.text-input.is-valid {
  border-color: var(--success-green) !important;
  background: #f0fdf4 !important;
  box-shadow: var(--success-glow) !important;
}

@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-4px); }
  75% { transform: translateX(4px); }
}

.field-hint {
  font-size: 0.78rem;
  margin-top: 5px;
  display: flex;
  align-items: center;
  gap: 5px;
  font-weight: 600;
}

.field-hint.error { color: var(--error-red); }
.field-hint.success { color: var(--success-green); }
.field-hint.info { color: var(--text-muted); }

.consultant-box {
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: var(--radius-md);
  padding: 14px 16px;
  margin-bottom: 24px;
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.consultant-box i {
  color: var(--accent-teal);
  font-size: 1.2rem;
  margin-top: 2px;
}

.consultant-box p {
  font-size: 0.82rem;
  color: #475569;
  line-height: 1.45;
  margin: 0;
}

.btn-submit-full {
  width: 100%;
  background: var(--primary-gradient);
  color: #ffffff;
  border: none;
  border-radius: var(--radius-md);
  padding: 16px 22px;
  font-size: 1.05rem;
  font-weight: 800;
  cursor: pointer;
  box-shadow: 0 6px 20px rgba(0, 168, 150, 0.3);
  transition: all var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.btn-submit-full:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 26px rgba(0, 168, 150, 0.45);
}

/* Expanded Rich Footer */
.site-footer {
  background: var(--navy-darkest);
  color: #94a3b8;
  padding: 60px 0 30px;
  font-size: 0.88rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  margin-top: auto;
}

.footer-top-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 36px;
  padding-bottom: 40px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.footer-col h4 {
  font-size: 1.05rem;
  font-weight: 700;
  color: #ffffff;
  margin-bottom: 18px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.footer-col h4 i {
  color: var(--accent-mint);
}

.footer-col p {
  font-size: 0.86rem;
  line-height: 1.6;
  color: #94a3b8;
  margin-bottom: 12px;
}

.footer-contact-list, .footer-links-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-contact-list li {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 0.86rem;
}

.footer-contact-list li i {
  color: var(--accent-teal);
  margin-top: 3px;
}

.footer-links-list a {
  color: #cbd5e1;
  transition: color var(--transition);
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.footer-links-list a:hover {
  color: var(--accent-mint);
}

.delivery-badge-pill {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  margin-bottom: 12px;
}

.delivery-badge-pill strong {
  color: #ffffff;
  display: block;
  font-size: 0.88rem;
  margin-bottom: 4px;
}

.footer-disclaimer-box {
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.05);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  margin: 28px 0;
  font-size: 0.78rem;
  line-height: 1.6;
  color: #64748b;
}

.footer-bottom-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 10px;
  font-size: 0.82rem;
}

.footer-security-seals {
  display: flex;
  align-items: center;
  gap: 16px;
}

.footer-security-seals span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: var(--accent-mint);
  font-weight: 600;
  font-size: 0.8rem;
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(7, 19, 34, 0.75);
  backdrop-filter: blur(4px);
  z-index: 2000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  opacity: 0;
  visibility: hidden;
  transition: all var(--transition);
}

.modal-backdrop.active {
  opacity: 1;
  visibility: visible;
}

.modal-dialog-box {
  background: #ffffff;
  border-radius: var(--radius-lg);
  max-width: 480px;
  width: 100%;
  padding: 36px;
  text-align: center;
  box-shadow: var(--shadow-xl);
  transform: translateY(15px);
  transition: transform var(--transition);
}

.modal-backdrop.active .modal-dialog-box {
  transform: translateY(0);
}

.modal-success-icon {
  width: 68px;
  height: 68px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--success-green);
  font-size: 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 16px;
}

/* Responsive */
@media (max-width: 960px) {
  .footer-top-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .home-hero-grid, .order-page-wrapper, .cert-page-grid {
    grid-template-columns: 1fr;
  }
  .portal-grid, .reviews-grid-clean {
    grid-template-columns: 1fr;
  }
  .ingredients-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .footer-top-grid {
    grid-template-columns: 1fr;
  }
  .mobile-menu-btn {
    display: block;
  }
  .nav-links {
    display: none;
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    background: #ffffff;
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 16px;
    box-shadow: var(--shadow-md);
  }
  .nav-links.open {
    display: flex;
  }
  .nav-link {
    width: 100%;
    text-align: center;
  }
  .hero-title {
    font-size: 1.7rem;
  }
  .article-content-card, .order-left-summary, .order-form-container {
    padding: 24px 18px;
  }
}
