/* ==========================================================
   Teekay Kares — site styles
   Colors and fonts match the original Wix site.
   ========================================================== */
:root {
  --navy: #141c2d;
  --navy-2: #111827;
  --blue: #294b96;
  --blue-2: #4682b4;
  --purple: #7f6eb7;
  --purple-2: #6c5ba8;
  --lavender: #eef0f8;
  --mist: #f5f7fc;
  --sky: #d6e4f2;
  --ink: #141c2d;
  --text: #3b4255;
  --muted: #6b7280;
  --white: #ffffff;
  --line: #dfe3ee;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(20, 28, 45, 0.08);
  --shadow-lg: 0 20px 50px rgba(20, 28, 45, 0.16);
  --hero-grad: linear-gradient(90deg, #7f6eb7 8%, #3a58a4 48%, #5b8fc4 92%);
  --serif: "Playfair Display", Georgia, serif;
  --sans: "Lato", "Helvetica Neue", Arial, sans-serif;
  --maxw: 1180px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--sans);
  font-weight: 300;
  color: var(--text);
  background: var(--white);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--blue); }
h1, h2, h3, h4 { font-family: var(--serif); color: var(--ink); line-height: 1.2; margin: 0 0 .5em; font-weight: 500; }
h1 { font-size: clamp(2.2rem, 5vw, 3.75rem); }
h2 { font-size: clamp(1.8rem, 3.6vw, 2.5rem); }
h3 { font-size: 1.3rem; }
p { margin: 0 0 1em; }
.container { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 24px; }
.center { text-align: center; }
.muted { color: var(--muted); }
.lead { font-size: 1.2rem; max-width: 760px; margin-left: auto; margin-right: auto; }
.skip-link { position: absolute; left: -999px; top: 0; background: var(--white); padding: 8px 14px; z-index: 999; }
.skip-link:focus { left: 8px; top: 8px; }
.icon svg { width: 100%; height: 100%; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--navy);
  box-shadow: 0 2px 12px rgba(0,0,0,.25);
}
.site-header .container { display: flex; align-items: center; justify-content: space-between; min-height: 84px; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; }
.brand img { width: 52px; height: 52px; object-fit: contain; }
.brand-name {
  font-family: var(--serif); font-size: 1.6rem; line-height: 1;
  background: linear-gradient(90deg, #a597de, #7fb0dd);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.brand-tag { display: block; font-size: .72rem; letter-spacing: .04em; color: #a9b6d6; font-style: italic; margin-top: 4px; }
.nav ul { list-style: none; display: flex; gap: 4px; margin: 0; padding: 0; }
.nav a {
  display: block; padding: 10px 16px; border-radius: 4px;
  color: #e6e9f2; text-decoration: none; font-size: .95rem; letter-spacing: .06em;
  transition: background .2s, color .2s;
}
.nav a:hover { background: rgba(255,255,255,.08); }
.nav a.active { background: var(--blue); color: var(--white); }
.nav-toggle { display: none; background: none; border: 0; color: var(--white); width: 44px; height: 44px; cursor: pointer; padding: 8px; }

@media (max-width: 1060px) {
  .nav-toggle { display: block; }
  .nav { position: fixed; inset: 84px 0 auto 0; background: var(--navy); max-height: 0; overflow: hidden; transition: max-height .3s ease; }
  .nav.open { max-height: 480px; }
  .nav ul { flex-direction: column; padding: 8px 16px 20px; }
  .nav a { padding: 14px 16px; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 14px 28px; border-radius: 6px; border: 2px solid transparent;
  font-family: var(--sans); font-size: 1rem; font-weight: 400; letter-spacing: .06em;
  text-decoration: none; cursor: pointer; transition: transform .15s, box-shadow .2s, background .2s;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn-primary { background: var(--blue); color: var(--white); }
.btn-primary:hover { background: #22407f; }
.btn-purple { background: var(--purple); color: var(--white); }
.btn-outline-light { background: rgba(255,255,255,.08); border-color: var(--white); color: var(--white); }
.btn-outline-light:hover { background: var(--white); color: var(--purple-2); }
.btn-row { display: flex; gap: 16px; flex-wrap: wrap; justify-content: center; }

/* ---------- Sections ---------- */
.section { padding: 90px 0; }
.section-sm { padding: 60px 0; }
.bg-mist { background: var(--mist); }
.bg-lavender { background: linear-gradient(180deg, #eef0f8, #e6ebf6); }
.bg-navy { background: var(--navy); color: #cfd6e6; }
.bg-navy h2, .bg-navy h3 { color: var(--white); }
.bg-purple { background: linear-gradient(120deg, #8a79c4, #7f6eb7 50%, #6f8fc6); color: var(--white); }
.bg-purple h2 { color: var(--white); }
.section-title { text-align: center; margin-bottom: 50px; }
.section-title p { max-width: 680px; margin: 0 auto; }

/* Gradient page hero (inner pages) */
.page-hero {
  background: var(--hero-grad);
  color: var(--white);
  text-align: center;
  padding: 110px 0 100px;
  position: relative; overflow: hidden;
}
.page-hero::after {
  content: ""; position: absolute; inset: 0;
  background: radial-gradient(circle at 80% 20%, rgba(255,255,255,.18), transparent 45%);
  pointer-events: none;
}
.page-hero h1 { color: var(--white); font-family: var(--sans); font-weight: 700; letter-spacing: -.02em; }
.page-hero p { font-size: 1.3rem; max-width: 820px; margin: 0 auto; }

/* Home hero */
.home-hero { background: linear-gradient(90deg, #f3f4fa, #e6ecf6 60%, #d6e4f2); padding: 80px 0 0; text-align: center; }
.gradient-text {
  background: linear-gradient(90deg, #7f6eb7, #294b96 60%, #4682b4);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.home-hero .lead { color: var(--muted); margin-bottom: 40px; }
.slideshows { display: grid; grid-template-columns: repeat(4, 1fr); }
.slideshow { position: relative; aspect-ratio: 4 / 4.2; overflow: hidden; background: #cfd6e6; }
.slideshow img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity 1.2s ease, transform 6s ease; transform: scale(1.04); }
.slideshow img.show { opacity: 1; transform: scale(1); }
@media (max-width: 760px) { .slideshows { grid-template-columns: repeat(2, 1fr); } }

/* Feature trio */
.features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; text-align: center; }
.feature .icon-badge { margin: 0 auto 18px; }
.feature h3 { font-family: var(--sans); font-weight: 700; font-size: 1.5rem; }
.icon-badge {
  width: 64px; height: 64px; border-radius: 50%;
  background: linear-gradient(135deg, #8a79c4, #6c5ba8);
  color: var(--white); display: grid; place-items: center; padding: 16px;
  box-shadow: 0 8px 20px rgba(127,110,183,.35);
}
@media (max-width: 860px) { .features { grid-template-columns: 1fr; } }

/* Service tiles (home, dark) */
.tiles { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.tile {
  border: 2px solid var(--purple); border-radius: 10px; padding: 28px 22px;
  background: rgba(255,255,255,.02); transition: transform .2s, background .2s, border-color .2s;
}
.tile:hover { transform: translateY(-6px); background: rgba(127,110,183,.12); border-color: #a597de; }
.tile .icon { display: block; width: 48px; height: 48px; color: #e6e9f2; margin-bottom: 18px; }
.tile h3 { font-family: var(--sans); color: #a597de !important; font-size: 1.15rem; font-weight: 700; }
.tile p { color: #cfd6e6; font-size: .97rem; margin: 0; }
@media (max-width: 960px) { .tiles { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .tiles { grid-template-columns: 1fr; } }

/* Services detail cards */
.services-hero { background: var(--hero-grad); padding: 80px 0; }
.services-hero .container { display: grid; grid-template-columns: 1.1fr 1fr; align-items: center; }
.services-hero img { border-radius: 4px; box-shadow: var(--shadow-lg); width: 100%; aspect-ratio: 16/10; object-fit: cover; }
.services-hero .panel { background: var(--white); padding: 56px 48px; margin-left: -80px; box-shadow: var(--shadow-lg); border-radius: 4px; }
.services-hero .panel h1 { font-size: clamp(2rem, 4vw, 3rem); }
@media (max-width: 860px) {
  .services-hero .container { grid-template-columns: 1fr; }
  .services-hero .panel { margin: -40px 16px 0; padding: 36px 28px; }
}
.service-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 36px; }
.service-card {
  background: var(--white); border-radius: var(--radius); padding: 40px; box-shadow: var(--shadow);
  border: 1px solid var(--line); transition: transform .2s, box-shadow .2s;
}
.service-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.service-card .head { display: flex; align-items: center; gap: 18px; margin-bottom: 18px; }
.service-card .head h3 { margin: 0; }
.ring { width: 58px; height: 58px; flex: none; border-radius: 50%; background: #eceaf7; color: var(--purple-2); display: grid; place-items: center; padding: 15px; }
.service-card h4 { font-family: var(--sans); font-size: 1rem; font-weight: 700; margin: 18px 0 8px; color: var(--ink); }
.checks { list-style: none; padding: 0; margin: 0; display: grid; gap: 8px; }
.checks li { position: relative; padding-left: 28px; }
.checks li::before {
  content: ""; position: absolute; left: 0; top: .45em; width: 16px; height: 16px; border-radius: 50%;
  background: var(--purple) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='white' stroke-width='3.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12l5 5L20 7'/%3E%3C/svg%3E") center/10px no-repeat;
}
@media (max-width: 860px) { .service-grid { grid-template-columns: 1fr; } .service-card { padding: 28px; } }

/* CTA band */
.cta { text-align: center; }
.cta p { font-size: 1.15rem; max-width: 680px; margin: 0 auto 30px; }

/* About */
.director { background: linear-gradient(160deg, #2a3348, #1f2740); padding: 80px 0; }
.director .container { display: grid; grid-template-columns: 360px 1fr; gap: 50px; align-items: start; }
.director-photo { border-radius: 6px; overflow: hidden; box-shadow: var(--shadow-lg); border: 3px solid rgba(255,255,255,.85); }
.director-photo img { width: 100%; aspect-ratio: 483/695; object-fit: cover; }
.director-caption { color: #e6e9f2; text-align: center; margin-top: 18px; }
.director-caption .role { text-transform: uppercase; letter-spacing: .18em; font-size: .8rem; color: #a597de; }
.director-caption .name { font-family: var(--serif); font-size: 1.25rem; color: var(--white); }
.letter { background: #f5f6fb; border-radius: 60px 6px 6px 6px; padding: 44px 48px; box-shadow: var(--shadow-lg); }
.letter h2 { font-size: 2rem; }
.letter .sign { font-family: var(--serif); font-style: italic; color: var(--ink); }
@media (max-width: 900px) {
  .director .container { grid-template-columns: 1fr; }
  .director-photo { max-width: 340px; margin: 0 auto; }
  .letter { padding: 32px 26px; border-radius: 36px 6px 6px 6px; }
}
.info-cards { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.info-card { background: var(--white); border-radius: var(--radius); padding: 32px; box-shadow: var(--shadow); border-top: 4px solid var(--purple); }
.info-card h3 { font-family: var(--sans); font-weight: 700; font-size: 1.1rem; display: flex; align-items: center; gap: 10px; }
.info-card h3 .icon { width: 24px; height: 24px; color: var(--purple); }
@media (max-width: 860px) { .info-cards { grid-template-columns: 1fr; } }
.split { display: grid; grid-template-columns: 1fr 1fr; gap: 60px; align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow-lg); width: 100%; max-height: 560px; object-fit: cover; }
.eyebrow { text-transform: uppercase; letter-spacing: .18em; font-size: .8rem; color: var(--purple-2); font-weight: 700; margin-bottom: 10px; display: block; }
@media (max-width: 860px) { .split { grid-template-columns: 1fr; gap: 36px; } }
.values-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.value-card { background: rgba(255,255,255,.06); border: 1px solid rgba(255,255,255,.14); border-radius: var(--radius); padding: 34px; }
.value-card h3 { color: #a597de !important; }
.value-card ul { margin: 0; padding-left: 18px; }
@media (max-width: 860px) { .values-grid { grid-template-columns: 1fr; } }

/* Assisted living gallery */
.gallery { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.gallery button { padding: 0; border: 0; background: none; cursor: zoom-in; border-radius: 10px; overflow: hidden; aspect-ratio: 1; }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.gallery button:hover img { transform: scale(1.06); }
.gallery button:first-child { grid-column: span 2; grid-row: span 2; }
@media (max-width: 760px) { .gallery { grid-template-columns: repeat(2, 1fr); } }
.feature-list { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.feature-list li { background: var(--white); border-radius: 12px; padding: 18px 20px 18px 54px; position: relative; box-shadow: var(--shadow); }
.feature-list li .icon { position: absolute; left: 18px; top: 18px; width: 22px; height: 22px; color: var(--purple); }
@media (max-width: 760px) { .feature-list { grid-template-columns: 1fr; } }
.map { border: 0; width: 100%; height: 420px; border-radius: var(--radius); box-shadow: var(--shadow); }

/* Lightbox */
.lightbox { position: fixed; inset: 0; background: rgba(10,14,25,.92); display: none; align-items: center; justify-content: center; z-index: 200; padding: 40px; }
.lightbox.open { display: flex; }
.lightbox img { max-height: 85vh; max-width: 90vw; border-radius: 8px; box-shadow: 0 20px 60px rgba(0,0,0,.5); }
.lightbox button { position: absolute; background: rgba(255,255,255,.12); border: 0; color: var(--white); width: 52px; height: 52px; border-radius: 50%; font-size: 1.6rem; cursor: pointer; }
.lightbox button:hover { background: rgba(255,255,255,.25); }
.lb-close { top: 20px; right: 20px; }
.lb-prev { left: 20px; top: 50%; transform: translateY(-50%); }
.lb-next { right: 20px; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; bottom: 20px; left: 0; right: 0; text-align: center; color: #cfd6e6; font-size: .9rem; }

/* Careers */
.perks { display: grid; grid-template-columns: repeat(4, 1fr); gap: 24px; }
.perk { text-align: center; background: var(--white); border-radius: var(--radius); padding: 32px 22px; box-shadow: var(--shadow); }
.perk .icon-badge { margin: 0 auto 16px; }
.perk h3 { font-family: var(--sans); font-weight: 700; font-size: 1.1rem; }
.perk p { margin: 0; }
@media (max-width: 960px) { .perks { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 520px) { .perks { grid-template-columns: 1fr; } }
.jobs { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; }
.job { background: var(--white); border: 1px solid var(--line); border-left: 5px solid var(--purple); border-radius: 12px; padding: 30px; box-shadow: var(--shadow); }
.job h3 { margin-bottom: 8px; }
.job .apply-link { display: inline-block; margin-top: 14px; font-weight: 700; text-decoration: none; }
@media (max-width: 860px) { .jobs { grid-template-columns: 1fr; } }
.steps { counter-reset: step; list-style: none; padding: 0; margin: 0 0 24px; display: grid; gap: 14px; }
.steps li { counter-increment: step; position: relative; padding-left: 50px; min-height: 36px; padding-top: 4px; }
.steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 34px; height: 34px; border-radius: 50%; background: var(--purple); color: var(--white); display: grid; place-items: center; font-weight: 700; }

/* Two-column aside layout used on careers/referrals */
.two-col { display: grid; grid-template-columns: 1fr 1.25fr; gap: 40px; align-items: start; }
@media (max-width: 960px) { .two-col { grid-template-columns: 1fr; } }
.card { background: var(--white); border-radius: var(--radius); padding: 36px; box-shadow: var(--shadow); border: 1px solid var(--line); }
.card + .card { margin-top: 24px; }
.contact-lines { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.contact-lines li { display: flex; align-items: center; gap: 12px; }
.contact-lines .icon { width: 22px; height: 22px; color: var(--purple); flex: none; }

/* ---------- Forms ---------- */
.form-card { background: var(--white); border-radius: var(--radius); padding: 44px; box-shadow: var(--shadow-lg); border: 1px solid var(--line); }
.form-card h2 { font-size: 1.9rem; }
@media (max-width: 600px) { .form-card { padding: 28px 20px; } }
fieldset { border: 0; padding: 0; margin: 0 0 28px; }
legend { font-family: var(--serif); font-size: 1.25rem; color: var(--ink); margin-bottom: 14px; padding-bottom: 8px; border-bottom: 2px solid #eceaf7; width: 100%; }
.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 600px) { .grid-2 { grid-template-columns: 1fr; } }
.field { display: flex; flex-direction: column; gap: 6px; margin-bottom: 18px; }
.grid-2 .field { margin-bottom: 0; }
.grid-2 + .field, .grid-2 + .grid-2 { margin-top: 18px; }
label, .label { font-weight: 700; font-size: .92rem; color: var(--ink); }
.req { color: #c0392b; }
input[type=text], input[type=email], input[type=tel], input[type=number], select, textarea {
  font: inherit; font-weight: 400; color: var(--ink);
  border: 1.5px solid #cfd5e3; border-radius: 8px; padding: 12px 14px; background: #fbfcff; width: 100%;
  transition: border-color .2s, box-shadow .2s;
}
textarea { min-height: 130px; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--purple); box-shadow: 0 0 0 4px rgba(127,110,183,.18); background: var(--white); }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #c0392b; }
.field .error { color: #c0392b; font-size: .85rem; display: none; }
.field.invalid .error { display: block; }
.checkbox-group { display: grid; grid-template-columns: 1fr 1fr; gap: 10px 18px; }
@media (max-width: 600px) { .checkbox-group { grid-template-columns: 1fr; } }
.check { display: flex; align-items: center; gap: 10px; font-weight: 400; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--purple); }
.hp { position: absolute !important; left: -9999px !important; }
.form-status { margin-top: 18px; padding: 14px 18px; border-radius: 8px; display: none; }
.form-status.ok { display: block; background: #e8f6ee; color: #1d6b3f; border: 1px solid #b6e2c6; }
.form-status.err { display: block; background: #fdecec; color: #8f2a2a; border: 1px solid #f2c0c0; }
button[disabled] { opacity: .65; cursor: wait; }
.form-note { font-size: .85rem; color: var(--muted); margin-top: 12px; }

/* Contact page */
.contact-grid { display: grid; grid-template-columns: 1fr 1.3fr; gap: 40px; }
@media (max-width: 900px) { .contact-grid { grid-template-columns: 1fr; } }
.contact-item { display: flex; gap: 16px; margin-bottom: 26px; }
.contact-item .ring { width: 52px; height: 52px; padding: 14px; }
.contact-item h3 { font-family: var(--sans); font-weight: 700; font-size: 1.05rem; margin: 0 0 4px; }
.contact-item p { margin: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--navy-2); color: #b9c2d6; padding: 70px 0 30px; }
.footer-grid { display: grid; grid-template-columns: 1.3fr 1fr 1fr 1.3fr; gap: 40px; }
.site-footer h3 { color: var(--white); font-size: 1.5rem; }
.footer-brand { font-family: var(--serif); font-size: 2rem; margin-bottom: 12px; display: inline-block; }
.site-footer ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.site-footer a { color: #b9c2d6; text-decoration: none; transition: color .2s; }
.site-footer a:hover { color: var(--white); }
.footer-contact li { display: flex; gap: 12px; align-items: flex-start; }
.footer-contact .icon { width: 20px; height: 20px; color: #a597de; flex: none; margin-top: 3px; }
.footer-bottom { border-top: 1px solid rgba(255,255,255,.1); margin-top: 50px; padding-top: 24px; text-align: center; font-size: .92rem; }
.footer-bottom p { margin: 4px 0; }
@media (max-width: 960px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }

/* ---------- Floating chat ---------- */
.chat-fab { position: fixed; right: 22px; bottom: 22px; z-index: 90; }
.chat-btn {
  display: flex; align-items: center; gap: 10px; background: var(--blue); color: var(--white);
  border: 0; border-radius: 40px; padding: 14px 24px; font: 400 1.05rem var(--serif);
  box-shadow: var(--shadow-lg); cursor: pointer;
}
.chat-btn .icon { width: 22px; height: 22px; }
.chat-panel {
  position: absolute; right: 0; bottom: 70px; width: 300px; background: var(--white); border-radius: 16px;
  box-shadow: var(--shadow-lg); padding: 22px; display: none; border: 1px solid var(--line);
}
.chat-panel.open { display: block; animation: pop .2s ease; }
.chat-panel h3 { font-size: 1.15rem; margin-bottom: 6px; }
.chat-panel a { display: flex; align-items: center; gap: 10px; padding: 12px; border-radius: 10px; text-decoration: none; color: var(--ink); background: var(--mist); margin-top: 10px; font-weight: 400; }
.chat-panel a:hover { background: #eceaf7; }
.chat-panel .icon { width: 20px; height: 20px; color: var(--purple); }
@keyframes pop { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

/* ---------- Reveal on scroll ---------- */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .7s ease, transform .7s ease; }
.reveal.in { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .slideshow img { transition: none; }
  html { scroll-behavior: auto; }
}
