/* Appily Fiftythree — Horizon masthead + Atlas footer */

.af-announce {
  background: var(--ts-ink);
  color: #E8EEF4;
  border-bottom: 3px solid var(--ts-wine);
}
.af-announce-track {
  width: min(var(--container), calc(100% - 32px));
  margin-inline: auto;
  min-height: 38px;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 18px;
  font-size: 12px;
}
.af-announce-mark {
  font-family: var(--font-display);
  font-weight: 700;
  letter-spacing: .08em;
  color: var(--ts-wine);
}
.af-announce-msg {
  margin: 0;
  text-align: center;
  letter-spacing: .02em;
  opacity: .92;
}
.af-announce-meta {
  display: flex; gap: 14px; align-items: center;
  justify-content: flex-end;
  opacity: .85;
}
.af-announce-meta a:hover { color: #fff; }

/* Masthead — brand center, split nav + utils */
.af-masthead {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(243, 245, 248, .92);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
}
.af-masthead.is-scrolled,
.af-masthead:focus-within {
  border-bottom-color: var(--ts-line);
  box-shadow: 0 10px 30px rgba(21, 32, 43, .05);
}
.af-masthead-inner {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 16px;
  padding: 18px 0 14px;
  position: relative;
}

.af-menu-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  border: 1px solid var(--ts-line);
  background: #fff;
  padding: 10px 12px;
  border-radius: var(--radius);
  cursor: pointer;
  color: var(--ts-ink);
}
.af-menu-lines {
  display: flex; flex-direction: column; gap: 5px; width: 18px;
}
.af-menu-lines i {
  display: block; height: 1.5px; background: currentColor;
  transition: transform .25s var(--ease-out), opacity .2s;
}
.af-menu-toggle.is-open .af-menu-lines i:first-child {
  transform: translateY(3.25px) rotate(45deg);
}
.af-menu-toggle.is-open .af-menu-lines i:last-child {
  transform: translateY(-3.25px) rotate(-45deg);
}
.af-menu-label {
  font-size: 11px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase;
}

.af-side-nav {
  display: flex; flex-wrap: wrap; gap: 4px 18px; align-items: center;
}
.af-side-link {
  font-size: 12px; font-weight: 500; letter-spacing: .04em;
  color: var(--ts-muted);
  position: relative;
  padding: 4px 0;
}
.af-side-link::after {
  content: '';
  position: absolute; left: 0; right: 100%; bottom: 0;
  height: 1.5px; background: var(--ts-wine);
  transition: right .3s var(--ease-out);
}
.af-side-link:hover,
.af-side-link.is-active { color: var(--ts-ink); }
.af-side-link:hover::after,
.af-side-link.is-active::after { right: 0; }

.af-brand {
  display: flex; align-items: center; gap: 12px;
  justify-self: center;
  text-align: left;
}
.af-brand-mark {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  background: var(--ts-ink);
  color: #fff;
  font-family: var(--font-display);
  font-size: 1.05rem; font-weight: 700;
  letter-spacing: -.02em;
  clip-path: polygon(12% 0, 100% 0, 88% 100%, 0 100%);
}
.af-brand-text { display: flex; flex-direction: column; line-height: 1; }
.af-brand-top {
  font-family: var(--font-body);
  font-size: 11px; font-weight: 600;
  letter-spacing: .28em; text-transform: uppercase;
  color: var(--ts-grove);
}
.af-brand-bottom {
  font-family: var(--font-display);
  font-size: clamp(1.55rem, 2.6vw, 2rem);
  font-weight: 600;
  letter-spacing: -.02em;
  color: var(--ts-ink);
  margin-top: 4px;
}

.af-utils {
  justify-self: end;
  display: flex; align-items: center; gap: 8px;
}
.af-search {
  display: flex; align-items: center;
  width: min(220px, 28vw);
  border: 1px solid var(--ts-line);
  background: #fff;
  border-radius: var(--radius);
  overflow: hidden;
}
.af-search input {
  flex: 1; border: 0; outline: 0;
  padding: 10px 12px; background: transparent; font-size: 13px;
}
.af-search button {
  border: 0; background: transparent; padding: 0 12px;
  color: var(--ts-muted); cursor: pointer; display: grid; place-items: center;
}
.af-search button:hover { color: var(--ts-ink); }
.af-util-btn {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  border: 1px solid var(--ts-line);
  background: #fff;
  color: var(--ts-ink);
  border-radius: var(--radius);
  position: relative;
  transition: border-color .2s, background .2s, color .2s;
}
.af-util-btn:hover,
.af-util-btn.is-active {
  border-color: var(--ts-ink);
  background: var(--ts-ink);
  color: #fff;
}
.af-cart-count {
  position: absolute; top: -6px; right: -6px;
  min-width: 18px; height: 18px; padding: 0 4px;
  border-radius: 999px;
  background: var(--ts-wine); color: #fff;
  font-size: 10px; font-weight: 700;
  display: grid; place-items: center;
}

/* Member Pass account control */
@keyframes af-account-spin {
  to { transform: rotate(360deg); }
}
@keyframes af-account-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.35); opacity: .45; }
}
.af-account-btn {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: 1px solid rgba(184, 92, 56, .35);
  background:
    radial-gradient(circle at 30% 25%, rgba(232, 196, 180, .45), transparent 45%),
    linear-gradient(160deg, #fff 0%, #F3F5F8 100%);
  color: var(--ts-ink);
  overflow: visible;
  transition:
    border-color .25s ease,
    background .25s ease,
    color .25s ease,
    transform .3s cubic-bezier(.22, 1, .36, 1),
    box-shadow .3s ease;
}
.af-account-btn:hover,
.af-account-btn.is-active {
  border-color: var(--ts-wine);
  background:
    radial-gradient(circle at 30% 25%, rgba(232, 196, 180, .35), transparent 50%),
    linear-gradient(160deg, #15202B 0%, #1A4A52 100%);
  color: #F4F7FA;
  transform: translateY(-2px);
  box-shadow: 0 10px 22px -14px rgba(21, 32, 43, .55);
}
.af-account-btn.is-signed {
  border-color: rgba(42, 111, 122, .45);
}
.af-account-btn.is-signed:hover,
.af-account-btn.is-signed.is-active {
  border-color: #7DCFB6;
}
.af-account-orb {
  position: relative;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
}
.af-account-ring {
  position: absolute;
  inset: 0;
  border-radius: 50%;
  border: 1.5px dashed rgba(184, 92, 56, .55);
  animation: af-account-spin 10s linear infinite;
  pointer-events: none;
}
.af-account-btn:hover .af-account-ring,
.af-account-btn.is-active .af-account-ring {
  border-color: rgba(232, 196, 180, .75);
  animation-duration: 4.5s;
}
.af-account-btn.is-signed .af-account-ring {
  border-style: solid;
  border-color: rgba(42, 111, 122, .55);
}
.af-account-face {
  position: relative;
  z-index: 1;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: linear-gradient(145deg, var(--ts-wine), #9A4528);
  color: #fff;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25);
}
.af-account-btn:hover .af-account-face,
.af-account-btn.is-active .af-account-face {
  background: linear-gradient(145deg, #E8C4B4, var(--ts-wine));
  color: #15202B;
}
.af-account-btn.is-signed .af-account-face {
  background: linear-gradient(145deg, var(--ts-grove), #1A4A52);
}
.af-account-btn.is-signed:hover .af-account-face,
.af-account-btn.is-signed.is-active .af-account-face {
  background: linear-gradient(145deg, #7DCFB6, var(--ts-grove));
  color: #15202B;
}
.af-account-initial {
  font-family: var(--font-display);
  font-size: 11px;
  font-weight: 700;
  line-height: 1;
  letter-spacing: .02em;
}
.af-account-sil {
  position: relative;
  width: 12px;
  height: 12px;
  display: block;
}
.af-account-head,
.af-account-torso {
  position: absolute;
  left: 50%;
  background: currentColor;
  display: block;
}
.af-account-head {
  top: 0;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  transform: translateX(-50%);
}
.af-account-torso {
  bottom: 0;
  width: 10px;
  height: 6px;
  border-radius: 6px 6px 2px 2px;
  transform: translateX(-50%);
}
.af-account-live {
  position: absolute;
  right: 2px;
  bottom: 2px;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #CDD4DE;
  border: 2px solid #fff;
  box-sizing: content-box;
  transition: background .2s ease;
}
.af-account-live.is-on {
  background: #7DCFB6;
  animation: af-account-pulse 1.8s ease-out infinite;
}
.af-account-btn:hover .af-account-live,
.af-account-btn.is-active .af-account-live {
  border-color: #1B2430;
}

@media (prefers-reduced-motion: reduce) {
  .af-account-ring,
  .af-account-live.is-on {
    animation: none !important;
  }
  .af-account-btn:hover,
  .af-account-btn.is-active {
    transform: none;
  }
}

/* Floating dock under masthead */
.af-dock {
  padding-bottom: 14px;
}
.af-dock-inner { position: relative; }
.af-dock-nav {
  background: var(--ts-ink);
  color: #E8EEF4;
  border-radius: var(--radius);
  min-height: 48px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: var(--shadow-soft);
}
.af-dock-links {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 4px 6px; padding: 4px 10px;
}
.af-dock-link {
  padding: 10px 14px;
  font-size: 11px; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase;
  color: rgba(232, 238, 244, .72);
  border-radius: var(--radius-sm);
  transition: color .2s, background .2s;
}
.af-dock-link:hover,
.af-dock-link.is-active {
  color: #fff;
  background: rgba(184, 92, 56, .28);
}

/* Mobile drawer reuse */
.ts-nav-backdrop {
  position: fixed; inset: 0; background: rgba(21, 32, 43, .45);
  opacity: 0; pointer-events: none; transition: opacity .25s; z-index: 50;
}
.ts-nav-backdrop.is-open { opacity: 1; pointer-events: auto; }
.ts-nav-drawer {
  display: none;
}
.ts-nav-drawer-head,
.ts-nav-drawer-body,
.ts-nav-drawer-foot { padding: 20px 22px; }
.ts-nav-drawer-brand strong {
  display: block; font-family: var(--font-display); font-size: 1.4rem;
}
.ts-nav-drawer-brand span { color: var(--ts-muted); font-size: 12px; }
.ts-nav-close {
  border: 1px solid var(--ts-line); background: #fff;
  width: 40px; height: 40px; border-radius: var(--radius); cursor: pointer; font-size: 22px;
}
.ts-nav-drawer-kicker {
  font-size: 11px; letter-spacing: .16em; text-transform: uppercase; color: var(--ts-muted);
}
.ts-nav-links { display: flex; flex-direction: column; gap: 4px; }
.ts-nav-link {
  display: flex; justify-content: space-between; align-items: center;
  padding: 14px 0; border-bottom: 1px solid var(--ts-line);
  font-size: 1.05rem; font-weight: 500;
}
.ts-nav-link.is-active { color: var(--ts-wine); }
.ts-drawer-action {
  display: block; padding: 12px 0; font-weight: 600;
}
.ts-drawer-action-muted { color: var(--ts-muted); font-weight: 500; font-size: 13px; }

/* Legacy class bridges used by other pages */
.ts-header, .ts-navbar, .ts-announce { display: contents; }
.ts-logo { display: none; }

/* Newsletter band */
.af-letter {
  background:
    linear-gradient(115deg, rgba(184, 92, 56, .12), transparent 45%),
    linear-gradient(0deg, var(--ts-surface), #F7F9FC);
  border-top: 1px solid var(--ts-line);
  padding: 56px 0;
}
.af-letter-grid {
  display: grid;
  grid-template-columns: 1.1fr .9fr;
  gap: 32px;
  align-items: end;
}
.af-letter-kicker {
  margin: 0 0 8px;
  font-size: 11px; font-weight: 600; letter-spacing: .18em;
  text-transform: uppercase; color: var(--ts-wine);
}
.af-letter-copy h2 {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-size: clamp(1.8rem, 3vw, 2.4rem);
  font-weight: 600; line-height: 1.15;
}
.af-letter-copy p { margin: 0; color: var(--ts-muted); max-width: 42ch; }
.af-letter-form {
  display: flex; gap: 0;
  border: 1px solid var(--ts-ink);
  background: #fff;
}
.af-letter-form input {
  flex: 1; border: 0; outline: 0; padding: 16px 18px; background: transparent;
}
.af-letter-form button {
  border: 0; background: var(--ts-ink); color: #fff;
  padding: 0 22px; font-size: 11px; font-weight: 700;
  letter-spacing: .14em; text-transform: uppercase; cursor: pointer;
}
.af-letter-form button:hover { background: var(--ts-wine); }

/* Footer */
.af-footer {
  background: var(--ts-charcoal);
  color: rgba(232, 238, 244, .86);
  position: relative;
  overflow: hidden;
}
.af-footer::before {
  content: '53';
  position: absolute;
  right: -2%; bottom: -12%;
  font-family: var(--font-display);
  font-size: clamp(10rem, 22vw, 18rem);
  font-weight: 700; line-height: 1;
  color: rgba(255, 255, 255, .03);
  pointer-events: none;
}
.af-footer-top {
  position: relative;
  display: grid;
  grid-template-columns: 1.1fr 1.6fr;
  gap: 40px;
  padding: 64px 0 40px;
}
.af-footer-brand {
  display: flex; gap: 16px; align-items: flex-start;
}
.af-footer-mark {
  width: 52px; height: 52px;
  display: grid; place-items: center;
  background: var(--ts-wine); color: #fff;
  font-family: var(--font-display); font-weight: 700;
  clip-path: polygon(12% 0, 100% 0, 88% 100%, 0 100%);
  flex-shrink: 0;
}
.af-footer-word {
  display: block;
  font-family: var(--font-display);
  font-size: 1.6rem; font-weight: 600;
  color: #fff; margin-bottom: 10px;
  text-transform: lowercase;
}
.af-footer-brand p {
  margin: 0; color: rgba(232, 238, 244, .62); max-width: 34ch; font-size: 14px;
}
.af-footer-cols {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}
.af-footer-col h4 {
  margin: 0 0 14px;
  font-size: 11px; letter-spacing: .16em; text-transform: uppercase;
  color: rgba(232, 238, 244, .5); font-weight: 600;
}
.af-footer-col a,
.af-footer-col p {
  display: block; margin: 0 0 10px;
  color: rgba(232, 238, 244, .82); font-size: 14px;
}
.af-footer-col a:hover { color: #fff; }
.af-footer-hours { color: rgba(232, 238, 244, .5) !important; font-size: 13px !important; }
.af-footer-base {
  position: relative;
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; flex-wrap: wrap;
  padding: 18px 0 28px;
  border-top: 1px solid rgba(255, 255, 255, .08);
  font-size: 12px; color: rgba(232, 238, 244, .5);
}
.af-footer-badge {
  border: 1px solid rgba(184, 92, 56, .55);
  color: #E8C4B4;
  padding: 6px 10px;
  letter-spacing: .08em; text-transform: uppercase;
  font-size: 10px; font-weight: 600;
}

/* Legacy newsletter hide if present */
.ts-newsletter { display: none; }
.ts-footer { display: none; }

@media (max-width: 980px) {
  .af-side-nav { display: none; }
  .af-menu-toggle { display: inline-flex; }
  .af-masthead-inner {
    grid-template-columns: auto 1fr auto;
  }
  .af-brand { justify-self: start; }
  .af-search { display: none; }
  .af-dock-links { display: none; }
  .af-dock-nav {
    background: transparent;
    box-shadow: none;
    min-height: 0;
    justify-content: stretch;
  }
  .ts-nav.af-dock-nav {
    position: fixed;
    inset: 0 auto 0 0;
    width: min(360px, 88vw);
    z-index: 60;
    transform: translateX(-105%);
    transition: transform .3s var(--ease-out);
    background: #fff;
    color: var(--ts-ink);
    border-radius: 0;
    align-items: stretch;
  }
  .ts-nav.af-dock-nav.is-open { transform: translateX(0); }
  .ts-nav-drawer {
    display: flex; flex-direction: column;
    width: 100%; height: 100%;
    background: #fff;
  }
  .af-letter-grid,
  .af-footer-top { grid-template-columns: 1fr; }
  .af-footer-cols { grid-template-columns: 1fr 1fr; }
  .af-announce-track { grid-template-columns: 1fr; text-align: center; padding: 8px 0; gap: 4px; }
  .af-announce-mark, .af-announce-meta { display: none; }
}

@media (max-width: 560px) {
  .af-brand-mark { width: 38px; height: 38px; font-size: .9rem; }
  .af-brand-bottom { font-size: 1.35rem; }
  .af-footer-cols { grid-template-columns: 1fr; }
  .af-letter-form { flex-direction: column; }
  .af-letter-form button { padding: 14px; }
}
