/* =================================================================
   Lex AI — Marketing page
   Platforma: Paragraf Lex
   Bootstrap 3.3.7 Compatible Version
   ================================================================= */


/* ========= 1. Design tokens ===================================== */
:root{
  --lex-ink:#0E2A47; --lex-blue:#2B6CB0; --lex-accent:#4FB3D9; --lex-accent-2:#4D87BF; --lex-gold:#C9A95C;
  --lex-ok:#2E7D5B; --lex-danger:#C24D52;
  --lex-bg:#F6F8FB; --lex-bg-2:#EDF2F7; --lex-line:#D9E1EC; --lex-text:#1A2B45; --lex-muted:#5A6A82;
}


/* ========= 2. Base (scoped to lex sections only) ================ */
/* Smooth scroll only for lex sections */
section.lex-section[id],
section.lex-hero[id]{scroll-margin-top:20px;}

/* Scoped typography - only affects lex sections */
.lex-hero,
.lex-section,
.ai-contact-form {
  font-family:'Inter',-apple-system,BlinkMacSystemFont,'Segoe UI',Roboto,Arial,sans-serif;
  -webkit-font-smoothing:antialiased;
}

/* Scoped link styles - only within lex sections */
.lex-hero a:not(.lex-btn),
.lex-section a:not(.lex-btn) {
  color:var(--lex-blue);
}
.lex-hero a:not(.lex-btn):hover,
.lex-hero a:not(.lex-btn):focus,
.lex-section a:not(.lex-btn):hover,
.lex-section a:not(.lex-btn):focus {
  color:var(--lex-ink);
  text-decoration:none;
}

/* Scoped heading styles - only within lex sections */
.lex-hero h1,
.lex-hero h2,
.lex-hero h3,
.lex-hero h4,
.lex-section h1,
.lex-section h2,
.lex-section h3,
.lex-section h4,
.ai-contact-form h1,
.ai-contact-form h2 {
  font-family:'Inter',sans-serif;
  letter-spacing:-.015em;
  color:var(--lex-ink);
  font-weight:700;
}


/* ========= 3. Primitives ======================================== */
h2.lex-h2{font-size:46px;line-height:1.15;margin:16px 0 18px;}
.lex-lede{font-size:19px;color:var(--lex-muted);line-height:1.6;}
.lex-accent{color:var(--lex-blue);}
.lex-eyebrow{display:inline-block;font-size:12px;letter-spacing:.14em;text-transform:uppercase;font-weight:600;color:var(--lex-blue);background:rgba(43,108,176,.08);padding:6px 12px;border-radius:999px;}

.lex-section{padding:80px 0;}
.lex-section--alt{background:#fff;}


/* ========= 4. Utilities ========================================= */
.lex-center{text-align:center;}
.lex-brand-ai{color:var(--lex-accent-2);}
.mt-2{margin-top:16px;}
.mt-4{margin-top:40px;}
.lex-cta-center{text-align:center;margin-top:32px;}
.material-icons.lex-icon-sm{font-size:18px;}


/* ========= 5. Buttons =========================================== */
.lex-btn{display:inline-flex;align-items:center;gap:8px;padding:14px 26px;border-radius:10px;font-weight:600;font-size:15px;transition:all .18s;border:1px solid transparent;cursor:pointer;}
.lex-btn--primary{background:var(--lex-ink);color:#fff;}
.lex-btn--primary:hover{background:var(--lex-blue);color:#fff;transform:translateY(-1px);box-shadow:0 12px 28px -10px rgba(43,108,176,.55);}


/* ========= 6. Hero ============================================== */
.lex-hero{position:relative;overflow:hidden;background:#fff;min-height:100vh;display:flex;align-items:center;padding:40px 0;}
.lex-hero > .container{width:100%;position:relative;z-index:2;}
.lex-hero__inner{position:relative;z-index:2;}

.lex-hero__logo{width:200px;height:200px;margin:0 auto -8px;display:flex;align-items:center;justify-content:center;}
.lex-hero__logo img{width:100%;height:100%;object-fit:contain;}
.lex-hero__brand{font-size:clamp(56px,8vw,96px);font-weight:800;color:var(--lex-ink);margin:0 0 6px;letter-spacing:-.03em;line-height:1;}
.lex-hero__by{margin:0 0 22px;font-size:13px;color:var(--lex-muted);letter-spacing:.04em;}
.lex-hero__by a{color:var(--lex-ink);text-decoration:none;font-weight:700;border-bottom:1px solid transparent;transition:border-color .2s,color .2s;}
.lex-hero__by a:hover{color:var(--lex-blue);border-bottom-color:var(--lex-blue);}

.lex-hero__title{font-size:clamp(28px,4.2vw,48px);line-height:1.15;margin:18px 0 10px;font-weight:800;letter-spacing:-.02em;}
.lex-hero__dot{color:var(--lex-accent);margin:0 8px;font-weight:500;display:inline-block;}
.lex-hero__tagline{font-size:clamp(22px,3vw,34px);font-weight:700;color:var(--lex-ink);margin:0 auto 26px;max-width:900px;line-height:1.25;letter-spacing:-.015em;}
.lex-hero__tagline .lex-accent{color:var(--lex-accent-2);}
.lex-hero__sub{font-size:21px;color:var(--lex-muted);max-width:900px;margin:0 auto 30px;line-height:1.55;}

.lex-hero__cta{display:flex;gap:12px;flex-wrap:wrap;justify-content:center;margin-bottom:42px;}
.lex-hero__cta .lex-btn{padding:18px 34px;font-size:17px;border-radius:12px;}
.lex-hero__trust{display:flex;gap:26px;justify-content:center;flex-wrap:wrap;color:var(--lex-muted);font-size:16px;margin-bottom:40px;}
.lex-hero__trust span{display:inline-flex;align-items:center;gap:8px;}
.lex-hero__trust .material-icons{font-size:20px;color:var(--lex-ok);}


/* ========= 7. Pillars — 3 stuba ================================= */
.lex-pillars{max-width:1440px;margin:40px auto 0;display:grid;grid-template-columns:repeat(3,1fr);gap:24px;}
.lex-pillar{background:#fff;border:1px solid var(--lex-line);border-radius:14px;padding:28px 26px;position:relative;overflow:hidden;transition:all .2s;}
.lex-pillar:hover{border-color:var(--lex-blue);transform:translateY(-4px);box-shadow:0 24px 50px -22px rgba(14,42,71,.25);}
.lex-pillar__num{position:absolute;top:18px;right:22px;font-size:52px;font-weight:800;color:var(--lex-bg-2);line-height:1;}
.lex-pillar__icon{width:48px;height:48px;border-radius:12px;background:linear-gradient(135deg,var(--lex-blue),var(--lex-accent));display:flex;align-items:center;justify-content:center;color:#fff;margin-bottom:18px;}
.lex-pillar__icon .material-icons{font-size:24px;}
.lex-pillar h3{font-size:18px;margin:0 0 8px;}
.lex-pillar p{color:var(--lex-muted);font-size:14px;margin:0;line-height:1.55;text-wrap:pretty;}
.lex-pillar__tag{display:inline-block;margin-top:14px;padding:4px 10px;font-size:11px;font-weight:600;color:var(--lex-gold);background:rgba(201,169,92,.1);border-radius:6px;text-transform:uppercase;letter-spacing:.08em;}


/* ========= 8. Structured output — 3 celine odgovora ============= */
.lex-structured{max-width:1440px;margin:0 auto;text-align:center;}
.lex-structured__copy{max-width:940px;margin:0 auto 56px;}
.lex-structured__copy h2{margin-top:0;}
.lex-structured__list{list-style:none;padding:0;margin:0;display:grid;grid-template-columns:repeat(3,1fr);gap:24px;text-align:left;}
.lex-structured__list li{background:#fff;border:1px solid var(--lex-line);border-radius:14px;padding:36px 32px;display:flex;flex-direction:column;gap:18px;box-shadow:0 20px 40px -28px rgba(14,42,71,.18);}
.lex-structured__list li > i.material-icons{color:var(--lex-blue);background:rgba(43,108,176,.08);width:52px;height:52px;border-radius:12px;display:flex;align-items:center;justify-content:center;font-size:26px;}
.lex-structured__list li > div{display:flex;flex-direction:column;gap:10px;}
.lex-structured__list li b{font-size:18px;color:var(--lex-ink);font-weight:700;}
.lex-structured__list li span{font-size:15px;line-height:1.6;color:var(--lex-muted);text-wrap:pretty;}


/* ========= 9. Comparison table ================================== */
.lex-compare-wrap{background:#fff;border-radius:16px;border:1px solid var(--lex-line);overflow-x:auto;box-shadow:0 20px 60px -30px rgba(14,42,71,.2);}
.lex-compare{width:100%;border-collapse:collapse;}
.lex-compare th,.lex-compare td{padding:18px 22px;text-align:left;border-bottom:1px solid var(--lex-line);font-size:15px;vertical-align:middle;}
.lex-compare thead th{background:#F8FAFD;font-weight:600;color:var(--lex-muted);font-size:12px;text-transform:uppercase;letter-spacing:.08em;}
.lex-compare thead th.lex-compare__us{background:linear-gradient(135deg,#0E2A47,#1E4A7E);color:#fff;text-align:center;}
.lex-compare thead th.lex-compare__them{text-align:center;}
.lex-compare__th-feature{width:34%;}
.lex-compare tbody td:first-child{font-weight:500;color:var(--lex-ink);}
.lex-compare tbody td.lex-cell--us{background:#F3F8FE;text-align:center;font-weight:600;color:var(--lex-ink);}
.lex-compare tbody td.lex-cell--them{text-align:center;color:var(--lex-muted);}
.lex-compare .material-icons{font-size:18px;vertical-align:-4px;}
.lex-compare .lex-ok{color:var(--lex-ok);}
.lex-compare .lex-no{color:var(--lex-danger);}
.lex-compare tbody td.lex-cell--us .lex-compare__line,
.lex-compare tbody td.lex-cell--them .lex-compare__line{display:block;font-size:13px;font-weight:500;color:var(--lex-muted);margin-top:4px;}
.lex-compare tbody td.lex-cell--them .lex-compare__line{font-weight:400;}
.lex-compare tr:last-child td{border-bottom:none;}


/* ========= 10. Pricing ========================================== */
.lex-pricing{display:grid;grid-template-columns:repeat(3,1fr);gap:20px;margin-top:24px;}
.lex-plan{background:#fff;border:1px solid var(--lex-line);border-radius:16px;padding:32px 28px;position:relative;display:flex;flex-direction:column;}
.lex-plan--featured{border-color:var(--lex-blue);box-shadow:0 24px 50px -22px rgba(43,108,176,.4);transform:translateY(-6px);}
.lex-plan__credits{font-size:14px;color:var(--lex-muted);margin-bottom:4px;text-transform:uppercase;letter-spacing:.08em;font-weight:600;}
.lex-plan__amount{font-size:48px;font-weight:800;color:var(--lex-ink);line-height:1;letter-spacing:-.02em;}
.lex-plan__currency{font-size:18px;vertical-align:top;color:var(--lex-muted);font-weight:600;margin-left:6px;}
.lex-plan__creditrow{display:flex;align-items:center;gap:12px;flex-wrap:wrap;margin:14px 0 18px;}
.lex-plan__creditcount{display:inline-flex;align-items:baseline;gap:6px;background:#EAF2FB;color:var(--lex-ink);font-weight:600;font-size:16px;padding:8px 14px;border-radius:999px;align-self:flex-start;}
.lex-plan__creditcount b{color:var(--lex-blue);font-size:22px;font-weight:800;line-height:1;}
.lex-plan--featured .lex-plan__creditcount{background:var(--lex-blue);color:#fff;}
.lex-plan--featured .lex-plan__creditcount b{color:#fff;}
.lex-plan__saving{font-size:13px;color:var(--lex-muted);font-weight:500;}
.lex-plan__saving b{color:var(--lex-blue);font-weight:700;}

.lex-freebadge{width:fit-content;max-width:100%;margin:0 auto 36px;display:flex;align-items:center;gap:18px;background:#fff;border:1px solid var(--lex-line);border-radius:14px;padding:20px 24px;box-shadow:0 12px 30px -18px rgba(14,42,71,.2);}
.lex-freebadge__ico{width:48px;height:48px;border-radius:12px;background:linear-gradient(135deg,var(--lex-gold),#DFC07F);display:flex;align-items:center;justify-content:center;color:#fff;flex-shrink:0;}
.lex-freebadge b{color:var(--lex-ink);font-size:16px;display:block;margin-bottom:2px;}
.lex-pricing__note{text-align:center;color:var(--lex-muted);font-size:13px;margin-top:24px;}


/* ========= 11. FAQ ======================= */
.lex-faq__item{background:#fff;border:1px solid var(--lex-line);border-radius:12px;margin-bottom:10px;overflow:hidden;}
.lex-faq__q{appearance:none;background:transparent;border:0;width:100%;text-align:left;font-family:inherit;padding:18px 22px;cursor:pointer;display:flex;align-items:center;justify-content:space-between;gap:14px;font-weight:600;color:var(--lex-ink);font-size:15px;}
.lex-faq__q:focus-visible{outline:2px solid var(--lex-blue);outline-offset:-2px;}
.lex-faq__q-text{flex:1;}
.lex-faq__toggle{width:28px;height:28px;border-radius:50%;background:var(--lex-bg);display:flex;align-items:center;justify-content:center;color:var(--lex-blue);flex-shrink:0;transition:transform .2s,background-color .2s,color .2s;}
.lex-faq__item.is-open .lex-faq__toggle{transform:rotate(45deg);background:var(--lex-ink);color:#fff;}
.lex-faq__a{padding:0 22px;max-height:0;overflow:hidden;transition:all .3s;color:var(--lex-muted);font-size:14px;line-height:1.65;}
.lex-faq__item.is-open .lex-faq__a{padding:0 22px 20px;max-height:500px;}


/* ========= 12. Contact form ===================================== */

/* Form section wrapper */
.ai-contact-form {
  background: transparent;
  padding: 80px 0;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Arial, sans-serif;
}

/* Logo and branding */
.hero-qupe__logo-wrapper {
  margin: 0 auto 24px;
  text-align: center;
}

.hero-qupe__logo {
  max-width: 160px;
  height: auto;
  display: inline-block;
}

.hero-qupe__accent {
  color: var(--lex-blue);
}

/* Section headings */
.ai-section-title {
  font-size: clamp(32px, 5vw, 48px);
  font-weight: 800;
  color: var(--lex-ink);
  margin: 0 0 12px;
  letter-spacing: -.02em;
  line-height: 1.2;
}

.ai-section-subtitle {
  font-size: 18px;
  color: var(--lex-muted);
  margin: 0 0 40px;
  line-height: 1.5;
}

/* Form container */
.ai-form-shell,
.lex-form-shell {
  background: #fff;
  border-radius: 16px;
  padding: 56px;
  border: 1px solid var(--lex-line);
  box-shadow: 0 30px 80px -40px rgba(14,42,71,.2);
  max-width: 100%;
}

/* Form wrapper */
.ai-form,
.lex-form {
  width: 100%;
}

.ai-form label,
.lex-form label {
  font-size: 14px;
  font-weight: 600;
  color: var(--lex-ink);
  margin-bottom: 8px;
  display: block;
}

.ai-form .required,
.lex-form .required {
  color: var(--lex-danger);
}

/* Input styles - compatible with Bootstrap 3.3.7 form-control */
.ai-form__input,
.lex-form__input {
  width: 100%;
  padding: 12px 16px;
  border: 1px solid var(--lex-line);
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  color: var(--lex-text);
  transition: border-color .15s, box-shadow .15s;
  background: #fff;
  line-height: 1.42857143; /* Bootstrap 3.3.7 line-height */
  display: block;
  height: auto;
  box-sizing: border-box;
}

.ai-form__input:focus,
.lex-form__input:focus {
  outline: none;
  border-color: var(--lex-blue);
  box-shadow: 0 0 0 3px rgba(43,108,176,.1);
}

/* Error state */
.ai-form__input.error,
.lex-form__input.error {
  border-color: var(--lex-danger);
}

.ai-form__input.error:focus,
.lex-form__input.error:focus {
  box-shadow: 0 0 0 3px rgba(194,77,82,.1);
}

/* Error message styling */
.error-message {
  display: none;
  color: var(--lex-danger);
  font-size: 13px;
  margin-top: 6px;
  font-weight: 500;
}

/* Form group spacing - compatible with Bootstrap 3.3.7 */
.ai-contact-form .form-group {
  margin-bottom: 20px;
}

.ai-form__row,
.lex-form__row {
  margin-bottom: 20px;
}

/* Submit button */
.ai-form__submit-btn,
.lex-form__submit {
  background: var(--lex-ink);
  color: #fff;
  border: none;
  padding: 16px 40px;
  border-radius: 10px;
  font-size: 16px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  transition: all .2s;
  font-family: inherit;
  line-height: 1.42857143;
  text-align: center;
  white-space: nowrap;
  vertical-align: middle;
  touch-action: manipulation;
  user-select: none;
}

.ai-form__submit-btn:hover,
.lex-form__submit:hover {
  background: var(--lex-blue);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px -8px rgba(43,108,176,.5);
}

.ai-form__submit-btn:active,
.lex-form__submit:active {
  transform: translateY(0);
}

.ai-form__submit-btn:disabled,
.lex-form__submit:disabled {
  opacity: 0.6;
  cursor: not-allowed;
  transform: none;
}

/* Contact info text */
.ai-form__contact-info,
.lex-form__note {
  margin-top: 20px;
  font-size: 14px;
  color: var(--lex-muted);
  line-height: 1.6;
}

.ai-form__contact-info a {
  color: var(--lex-blue);
  font-weight: 600;
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color .2s;
}

.ai-form__contact-info a:hover {
  border-bottom-color: var(--lex-blue);
}


/* ========= 13. Responsive ======================================= */
/* ≤ 900px — collapse multi-column grids */
@media (max-width:900px){
  .lex-pillars,.lex-structured__list,.lex-pricing{grid-template-columns:1fr;}
  .lex-hero__logo{width:130px;height:130px;}
  h2.lex-h2{font-size:32px;}
}

/* ≤ 720px — tighter paddings, smaller type */
@media (max-width:720px){
  .lex-hero__sub{font-size:16px;}
  .lex-section{padding:56px 0;}
  .lex-form-shell{padding:24px;}
}

/* REMOVED: Container width overrides to preserve Bootstrap 3.3.7 default behavior */
/* This prevents breaking the header/footer layout */


/* ========= 14. Bootstrap 3.3.7 Compatibility ==================== */
/* Ensure lex sections don't break existing Bootstrap grid */
.lex-section .row,
.lex-hero .row,
.ai-contact-form .row {
  margin-left: -15px;
  margin-right: -15px;
}

.lex-section .col-md-1,
.lex-section .col-md-2,
.lex-section .col-md-3,
.lex-section .col-md-4,
.lex-section .col-md-5,
.lex-section .col-md-6,
.lex-section .col-md-7,
.lex-section .col-md-8,
.lex-section .col-md-9,
.lex-section .col-md-10,
.lex-section .col-md-11,
.lex-section .col-md-12,
.lex-hero .col-md-10,
.ai-contact-form .col-md-6,
.ai-contact-form .col-md-10,
.ai-contact-form .col-md-12 {
  padding-left: 15px;
  padding-right: 15px;
}

/* Bootstrap form-control compatibility */
.ai-contact-form .form-control.ai-form__input {
  /* Override Bootstrap 3.3.7 defaults with our styles */
  height: auto;
  padding: 12px 16px;
  font-size: 15px;
  line-height: 1.42857143;
  border-radius: 8px;
  border: 1px solid var(--lex-line);
  box-shadow: none;
}

.ai-contact-form .form-control.ai-form__input:focus {
  border-color: var(--lex-blue);
  box-shadow: 0 0 0 3px rgba(43,108,176,.1);
}

/* Ensure form-group spacing works with Bootstrap */
.ai-contact-form .form-group {
  margin-bottom: 20px;
}

/* Bootstrap select compatibility */
.ai-contact-form select.form-control.ai-form__input {
  height: 45px;
  padding: 12px 16px;
}

/* Ensure text-center works in form */
.ai-contact-form .text-center {
  text-align: center;
}

/* Override Bootstrap button styles only for lex buttons */
.lex-btn.btn-default,
.lex-btn.btn-primary {
  background: var(--lex-ink);
  border-color: var(--lex-ink);
  color: #fff;
}

/* Responsive form padding */
@media (max-width: 768px) {
  .ai-form-shell,
  .lex-form-shell {
    padding: 32px 24px;
  }
  
  .ai-section-title {
    font-size: 28px;
  }
  
  .ai-contact-form {
    padding: 60px 0;
  }
}

@media (max-width: 480px) {
  .ai-form-shell,
  .lex-form-shell {
    padding: 24px 16px;
  }
  
  .ai-form__submit-btn,
  .lex-form__submit {
    width: 100%;
    justify-content: center;
  }
}

/* Ensure material icons render correctly */
.material-icons {
  font-family: 'Material Icons';
  font-weight: normal;
  font-style: normal;
  font-size: 24px;
  display: inline-block;
  line-height: 1;
  text-transform: none;
  letter-spacing: normal;
  word-wrap: normal;
  white-space: nowrap;
  direction: ltr;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  -moz-osx-font-smoothing: grayscale;
  font-feature-settings: 'liga';
}

/* Dropdown mesto compatibility */
.mesto-dropdown {
  position: relative;
}

.mesto-dropdown__list {
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  z-index: 1000;
  background: #fff;
  border: 1px solid var(--lex-line);
  border-top: none;
  border-radius: 0 0 8px 8px;
  max-height: 220px;
  overflow-y: auto;
  margin: 0;
  padding: 0;
  list-style: none;
  display: none;
  box-shadow: 0 4px 12px rgba(14,42,71,.12);
}

.mesto-dropdown__list li {
  padding: 10px 16px;
  cursor: pointer;
  font-size: 14px;
  transition: background-color .15s;
  color: var(--lex-text);
}

.mesto-dropdown__list li:hover,
.mesto-dropdown__list li.active {
  background: #f0f4ff;
  color: var(--lex-blue);
}

.mesto-dropdown__list li.no-results {
  color: var(--lex-muted);
  cursor: default;
}

.mesto-dropdown__list li.no-results:hover {
  background: transparent;
  color: var(--lex-muted);
}
