/* ==========================================================================
   mmp.css
   Shared design-system styles for the Manage My Policy redesign project.
   Reference: style_guide.html
   ========================================================================== */

/* ---- Fonts ---- */
@font-face {
  font-family: 'Termina';
  src: url('fonts/Termina-Bold.woff2') format('woff2'),
       url('fonts/Termina-Bold.woff') format('woff');
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: 'Poppins';
  src: url('fonts/Poppins-Regular.ttf') format('truetype');
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --navy: #112645;
  --orange: #F48120;
  --orange-hover: #E0731A;
  --light-gray: #F5F5F5;
  --shadow-gray: #E0E0E0;
  --error-red: #C0392B;
  --error-bg: #FCEDEB;
}

* { box-sizing: border-box; }

body {
  font-family: 'Poppins', sans-serif;
  color: #333;
}

.termina { font-family: 'Termina', sans-serif; font-weight: 700; }

h1.page-title { font-size: 44px; margin: 0 0 16px 0; }
@media (max-width: 991px) { h1.page-title { font-size: 36px; } }
@media (max-width: 767px) { h1.page-title { font-size: 28px; } }

/* ---- Nav ---- */
header.site-nav {
  padding: 16px 24px;
  box-shadow: 0 4px 10px var(--shadow-gray);
  background: #fff;
  position: sticky;
  top: 0;
  z-index: 1030;
}
.nav-link.custom-link { color: var(--navy); font-weight: 500; font-size: 15px; }
.nav-link.custom-link:hover { color: var(--orange-hover); }
.navbar-toggler-icon-custom span { display: block; width: 22px; height: 2px; background: var(--navy); border-radius: 2px; margin: 4px 0; }
/* Bootstrap's default focus ring is a box-shadow, not a border — border-0 alone
   doesn't remove it, so the hamburger shows an outline ring on click/tap. */
.navbar-toggler:focus { box-shadow: none; outline: none; }

/* "Get a Quote" nav link: filled button on desktop/tablet, plain text link
   (matching the other menu items) once collapsed into the mobile dropdown. */
.quote-link {
  background: var(--orange); color: #fff; font-weight: 700; font-size: 0.9375rem;
  padding: 10px 20px; border-radius: 4px; text-transform: uppercase;
  text-decoration: none; display: inline-block; letter-spacing: 0.04em;
}
.quote-link:hover { background: var(--orange-hover); color: #fff; }
@media (max-width: 991px) {
  .quote-link {
    background: none; color: var(--navy); font-weight: 500; font-size: 15px;
    padding: 0; text-transform: none; letter-spacing: normal; display: block;
  }
  .quote-link:hover { background: none; color: var(--orange-hover); }
}

/* ---- Buttons ---- */
.btn-alinsco {
  background: var(--orange);
  color: #fff;
  font-weight: 700;
  font-size: 0.9375rem;
  padding: 14px 24px;
  border-radius: 4px;
  border: none;
  text-transform: uppercase;
  min-width: 140px;
  letter-spacing: 0.04em;
}
.btn-alinsco:hover, .btn-alinsco:focus { background: var(--orange-hover); color: #fff; }
.btn-alinsco:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
@media (max-width: 767px) { .btn-alinsco { width: 100%; padding: 14px 0; min-width: 0; } }

/* Disabled state: flat gray, never a faded/opacity version of the orange button —
   a dimmed orange still reads as "the CTA, just dim" and invites a click attempt.
   All other properties (padding, radius, font-size, weight, min-width) stay unchanged. */
.btn-alinsco:disabled,
.btn-alinsco[aria-disabled="true"] {
  background: #CCCCCC;
  color: #888888;
  cursor: not-allowed;
}
.btn-alinsco:disabled:hover,
.btn-alinsco:disabled:focus,
.btn-alinsco[aria-disabled="true"]:hover,
.btn-alinsco[aria-disabled="true"]:focus {
  background: #CCCCCC;
  color: #888888;
}

/* ---- Form fields ---- */
.form-control-alinsco {
  border: 1px solid #ccc;
  border-radius: 4px;
  padding: 12px 14px;
  font-size: 15px;
  font-family: 'Poppins', sans-serif;
}
.form-control-alinsco:focus { border-color: #999; outline: none; box-shadow: none; }
.form-control-alinsco.is-invalid {
  border: 1.5px solid var(--error-red);
  /* Reset Bootstrap's built-in invalid-state icon — our own error icon already
     appears next to the message below the field, so the input itself only
     needs the red border, not a second icon. */
  background-image: none;
  padding-right: 14px;
}
.form-control-alinsco:disabled { background: #FAFAFA; color: #555; }

.form-label-alinsco { font-size: 14px; font-weight: 500; color: var(--navy); margin-bottom: 8px; display: block; }

.field-error-msg {
  display: none;
  color: var(--error-red);
  font-size: 12.5px;
  margin-top: 6px;
  align-items: flex-start;
  gap: 5px;
}
.field-error-msg.show { display: flex; }
.field-error-msg::before {
  content: "";
  flex-shrink: 0;
  margin-top: 1px;
  width: 13px;
  height: 13px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none'%3E%3Ccircle cx='12' cy='12' r='10' stroke='%23C0392B' stroke-width='2'/%3E%3Cline x1='12' y1='7' x2='12' y2='13' stroke='%23C0392B' stroke-width='2' stroke-linecap='round'/%3E%3Ccircle cx='12' cy='16.5' r='1' fill='%23C0392B'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
}
.err-icon { flex-shrink: 0; margin-top: 1px; }

/* ---- Checkbox ---- */
.form-check-alinsco {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 16px;
  background: var(--light-gray);
  border-radius: 6px;
}
.form-check-alinsco.has-error { background: var(--error-bg); border: 1px solid var(--error-red); }
.form-check-alinsco input[type="checkbox"] {
  appearance: none;
  -webkit-appearance: none;
  margin-top: 3px;
  width: 16px; height: 16px;
  flex-shrink: 0;
  border: 1px solid #767676;
  background-color: #fff;
  border-radius: 3px;
  cursor: pointer;
}
.form-check-alinsco.has-error input[type="checkbox"] { border-color: var(--error-red); }
.form-check-alinsco input[type="checkbox"]:checked {
  background-color: var(--orange);
  border-color: var(--orange);
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M3 8.5L6.5 12L13 4.5' stroke='%23112645' stroke-width='2' fill='none' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: center;
  background-size: 11px 11px;
}
.form-check-alinsco input[type="checkbox"]:focus-visible { outline: 2px solid var(--orange); outline-offset: 2px; }
.form-check-alinsco label { font-size: 0.84375rem; color: #444; line-height: 1.5; cursor: pointer; }

/* ---- Error banner (form-level) ---- */
.alert-alinsco-danger {
  background: var(--error-bg);
  border: 1.5px solid var(--error-red);
  color: var(--error-red);
  border-radius: 6px;
  padding: 12px 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}
.alert-alinsco-danger::before {
  content: "";
  flex-shrink: 0;
  margin-top: 1px;
  width: 18px;
  height: 18px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none'%3E%3Ccircle cx='12' cy='12' r='10' stroke='%23C0392B' stroke-width='2'/%3E%3Cline x1='12' y1='7' x2='12' y2='13' stroke='%23C0392B' stroke-width='2' stroke-linecap='round'/%3E%3Ccircle cx='12' cy='16.5' r='1' fill='%23C0392B'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-size: contain;
}
.alert-alinsco-danger a { color: var(--orange); font-weight: 600; text-decoration: none; }
.alert-alinsco-danger a:hover { color: var(--orange-hover); }

/* ---- Card / container ---- */
.card-alinsco {
  background: #fff;
  border: 1px solid var(--shadow-gray);
  border-radius: 8px;
  box-shadow: 0 8px 24px var(--shadow-gray);
  padding: 44px 48px;
}
@media (max-width: 767px) { .card-alinsco { padding: 28px 20px; } }

/* Narrower content-only card used by confirmation/info pages
   (Sign Up Confirmation, Forgot/Reset/Create Password Confirmation) */
.content-card-narrow {
  max-width: 620px;
  margin: 0 auto;
  text-align: left;
}
.content-card-narrow p { font-size: 15px; color: var(--navy); line-height: 1.6; margin: 0 0 20px 0; }
.content-card-narrow p:last-of-type { margin-bottom: 0; }
.content-card-narrow p.content-card-cta { margin-top: 28px; }
.text-mask-strong { font-weight: 600; }

/* ---- Links ---- */
.link-alinsco { color: var(--orange); font-weight: 600; text-decoration: underline; }
.link-alinsco:hover { color: var(--orange-hover); }
.link-navy { color: var(--navy); font-weight: 600; text-decoration: underline; }
.link-navy:hover { color: var(--orange-hover); }

/* ---- Login card (Login.aspx) ---- */
.login-card { max-width: 420px; margin: 0 auto; text-align: left; }
.forgot-link { text-align: right; margin: 12px 0 18px; }
.forgot-link a { font-size: 13px; }
.login-btn { display: block; width: auto; min-width: 140px; margin: 8px auto 0; }
@media (max-width: 767px) { .login-btn { width: 100%; padding: 14px 0; min-width: 0; } }
.signup-link { text-align: center; margin-top: 18px; font-size: 13.5px; color: var(--navy); }

/* ---- Mobile app promo section (Login.aspx) ---- */
.app-section { padding: 60px 20px; text-align: center; }
h2.app-heading { font-family: 'Termina', sans-serif; font-weight: 700; color: var(--navy); font-size: 40px; margin: 0 0 28px; }
@media (max-width: 991px) { h2.app-heading { font-size: 32px; } }
@media (max-width: 767px) { h2.app-heading { font-size: 24px; } }

.badges { display: flex; justify-content: center; gap: 16px; margin-bottom: 48px; flex-wrap: wrap; }
.store-badge img { height: 44px; display: block; }

.cards-row { display: flex; gap: 28px; justify-content: center; flex-wrap: wrap; max-width: 1240px; margin: 0 auto; }
.promo-card {
  background: var(--navy); border-radius: 8px; padding: 28px 24px 0; flex: 0 0 280px;
  width: 280px; text-align: center; color: #fff; overflow: hidden; display: flex; flex-direction: column;
}
.promo-card h3 { font-family: 'Termina', sans-serif; font-weight: 700; color: var(--orange); font-size: 20px; text-transform: uppercase; margin: 0 0 10px; letter-spacing: 0.02em; }
.promo-card p { font-size: 15px; color: #fff; line-height: 1.5; margin: 0 0 20px; }
.promo-card img { width: 65%; max-width: 165px; display: block; margin: auto auto 0; }

@media (max-width: 991px) { .promo-card { max-width: 45%; } }
@media (max-width: 767px) {
  .cards-row { flex-direction: column; align-items: center; }
  .promo-card { max-width: 100%; width: 100%; }
}

/* ---- Password rules panel + create/reset password grid ---- */
.password-grid {
  display: grid;
  grid-template-columns: 460px 300px;
  grid-template-rows: auto 1fr;
  gap: 32px;
  justify-content: center;
  max-width: 900px;
  margin: 0 auto;
}
.password-heading-col { grid-column: 1; grid-row: 1; text-align: center; }
.password-form-card {
  grid-column: 1; grid-row: 2;
  text-align: left;
}
.password-rules-panel {
  grid-column: 2; grid-row: 2;
  align-self: start;
  background: var(--light-gray);
  padding: 24px 28px;
  text-align: left;
  border-radius: 8px;
  border: 1px solid var(--shadow-gray);
}
.password-rules-panel h2 { font-family: 'Poppins', sans-serif; font-weight: 600; font-size: 15px; color: var(--navy); margin: 0 0 14px 0; }
.password-rules-panel ul { margin: 0; padding-left: 20px; }
.password-rules-panel li { font-size: 13.5px; color: var(--navy); margin-bottom: 8px; line-height: 1.4; }
.password-rules-panel li:last-child { margin-bottom: 0; }

.ack-text { font-size: 13px; color: var(--navy); line-height: 1.6; margin: 4px 0 22px; }
.ack-text a { color: var(--orange); text-decoration: underline; font-weight: 600; }
.ack-text a:hover { color: var(--orange-hover); }

.continue-btn-center { display: block; width: auto; margin: 0 auto; }

/* Expired/invalid activation or reset link state — replaces the entire
   form + rules panel (Createpassword.aspx, Resetpassword.aspx). */
.expired-link-banner {
  display: flex; align-items: flex-start; gap: 10px;
  background: var(--error-bg); border: 1.5px solid var(--error-red);
  border-radius: 6px; padding: 14px 16px; margin-bottom: 22px;
}
.expired-link-banner svg { flex-shrink: 0; margin-top: 1px; color: var(--error-red); }
.expired-link-banner span { color: var(--error-red); font-size: 13.5px; line-height: 1.5; }
.expired-link-text { font-size: 14px; color: var(--navy); line-height: 1.6; margin: 0 0 20px; }
.expired-link-cta { display: block; width: auto; min-width: 140px; margin: 0 auto; }

@media (max-width: 767px) {
  .password-grid { grid-template-columns: 1fr; grid-template-rows: auto auto auto; }
  .password-heading-col { grid-column: 1; grid-row: 1; }
  .password-form-card { grid-column: 1; grid-row: 2; }
  .password-rules-panel { grid-column: 1; grid-row: 3; margin-top: 24px; }
  .continue-btn-center { width: 100%; padding: 14px 0; min-width: 0; }
  .expired-link-cta { width: 100%; padding: 14px 0; min-width: 0; }
}
.hero-alinsco { background: var(--light-gray); padding: 60px 20px 70px; text-align: center; }
@media (max-width: 767px) { .hero-alinsco { padding: 40px 16px 50px; } }
