/* Hanging File Desk — policy layout (Appily Ninetyeight) */

/* —— Hop —— */
.hf-hop {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--hf-ink);
  border-bottom: 3px solid var(--hf-rose);
}
.hf-hop-inner {
  max-width: 920px;
  margin: 0 auto;
  padding: 0.7rem 1.1rem;
  display: flex;
  align-items: center;
  gap: 1rem;
}
.hf-hop-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  text-decoration: none;
  color: #fff;
  flex-shrink: 0;
}
.hf-hop-brand strong {
  font-family: var(--hf-display);
  font-weight: 600;
  font-size: 1.05rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.hf-hop-mark {
  width: 1.25rem;
  height: 1.05rem;
  border-radius: 2px 2px 0 0;
  background: var(--hf-rose);
  box-shadow: 0 3px 0 var(--hf-teal);
  position: relative;
}
.hf-hop-mark::after {
  content: "";
  position: absolute;
  left: 20%;
  right: 20%;
  top: -4px;
  height: 5px;
  border-radius: 2px 2px 0 0;
  background: var(--hf-amber);
}
.hf-hop-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.85rem;
  margin-left: auto;
}
.hf-hop-links a {
  color: rgba(255,255,255,0.85);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  padding: 0.25rem 0;
  border-bottom: 2px solid transparent;
  transition: color 0.2s, border-color 0.2s;
}
.hf-hop-links a em {
  font-style: normal;
  display: inline-block;
  min-width: 1.1rem;
  padding: 0 0.28rem;
  margin-left: 0.12rem;
  border-radius: 999px;
  background: var(--hf-teal);
  color: #fff;
  font-size: 0.68rem;
  line-height: 1.35;
  text-align: center;
}
.hf-hop-links a:hover,
.hf-hop-links a[aria-current="page"] {
  color: #fff;
  border-bottom-color: var(--hf-amber);
}
.hf-hop-toggle {
  display: none;
  margin-left: auto;
  border: 2px solid #fff;
  background: transparent;
  color: #fff;
  font-family: var(--hf-ui);
  font-weight: 800;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 0.4rem 0.7rem;
  border-radius: 8px;
  cursor: pointer;
}
.hf-hop-sheet {
  display: none;
  flex-direction: column;
  gap: 0.35rem;
  padding: 0.5rem 1.1rem 1rem;
  background: #1C2834;
  border-top: 1px solid rgba(190, 18, 60, 0.35);
}
.hf-hop-sheet a {
  color: #fff;
  text-decoration: none;
  font-weight: 700;
  padding: 0.55rem 0.65rem;
  border-radius: 10px;
  background: rgba(255,255,255,0.05);
}
.hf-hop-sheet a[aria-current="page"] {
  background: rgba(190, 18, 60, 0.35);
  outline: 1px solid var(--hf-rose);
}
.hf-hop-sheet a em {
  font-style: normal;
  margin-left: 0.35rem;
  color: #5EEAD4;
}
.hf-hop.is-open .hf-hop-sheet { display: flex; }

@media (max-width: 720px) {
  .hf-hop-links { display: none; }
  .hf-hop-toggle { display: inline-block; }
}

/* —— Mast —— */
.hf-mast {
  max-width: 920px;
  margin: 0 auto;
  padding: 1.85rem 1.1rem 1rem;
  text-align: center;
}
.hf-mast-brand {
  margin: 0 0 0.4rem;
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--hf-mute);
}
.hf-mast-brand span { color: var(--hf-rose); }
.hf-mast h1 {
  margin: 0 0 0.5rem;
  font-family: var(--hf-display);
  font-weight: 700;
  font-size: clamp(1.85rem, 4.5vw, 2.6rem);
  line-height: 1.1;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--hf-ink);
}
.hf-mast p {
  margin: 0 auto 0.85rem;
  max-width: 36rem;
  font-size: 1.02rem;
  line-height: 1.5;
  color: var(--hf-mute);
  font-weight: 600;
}

/* —— File rail (policy type nav) —— */
.hf-rail {
  max-width: 920px;
  margin: 0 auto 1.35rem;
  padding: 0 1.1rem;
}
.hf-rail-label {
  margin: 0 0 0.55rem;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--hf-mute);
  text-align: center;
}
.hf-files {
  display: flex;
  flex-wrap: nowrap;
  gap: 0.35rem;
  overflow-x: auto;
  padding: 0.85rem 0.25rem 0.35rem;
  scrollbar-width: thin;
  scrollbar-color: var(--hf-rose) transparent;
  -webkit-overflow-scrolling: touch;
}
.hf-tab {
  position: relative;
  flex: 0 0 auto;
  min-width: 6.4rem;
  max-width: 8.5rem;
  padding: 0.85rem 0.75rem 0.7rem;
  text-decoration: none;
  color: var(--hf-ink);
  background: var(--hf-surface);
  border-radius: 10px 10px 4px 4px;
  border: 2px solid #C5D0DB;
  border-bottom: none;
  box-shadow: 0 -2px 0 var(--hf-tab-accent, var(--hf-teal)) inset;
  transform: translateY(6px);
  transition: transform 0.28s cubic-bezier(0.22, 1.15, 0.36, 1), background 0.2s, border-color 0.2s, color 0.2s;
}
.hf-tab:nth-child(1) { --hf-tab-accent: var(--hf-rose); }
.hf-tab:nth-child(2) { --hf-tab-accent: var(--hf-teal); }
.hf-tab:nth-child(3) { --hf-tab-accent: var(--hf-amber); }
.hf-tab:nth-child(4) { --hf-tab-accent: #0369A1; }
.hf-tab:nth-child(5) { --hf-tab-accent: #15803D; }
.hf-tab:nth-child(6) { --hf-tab-accent: #C2410C; }
.hf-tab em {
  display: block;
  font-style: normal;
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--hf-mute);
  margin-bottom: 0.2rem;
}
.hf-tab strong {
  display: block;
  font-family: var(--hf-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  line-height: 1.15;
  color: var(--hf-ink);
}
.hf-tab:hover {
  transform: translateY(2px);
  border-color: var(--hf-tab-accent, var(--hf-teal));
}
.hf-tab.is-active {
  transform: translateY(-4px);
  background: var(--hf-folder);
  border-color: var(--hf-folder);
  color: #fff;
  box-shadow:
    0 -3px 0 var(--hf-tab-accent, var(--hf-rose)) inset,
    0 8px 18px rgba(18, 26, 34, 0.18);
  z-index: 2;
}
.hf-tab.is-active em { color: #94A3B8; }
.hf-tab.is-active strong { color: #fff; }

/* —— Folder sleeve + document —— */
.hf-stage {
  max-width: 920px;
  margin: 0 auto;
  padding: 0 1.1rem 2.5rem;
}
.hf-sleeve {
  background: var(--hf-folder);
  border-radius: var(--hf-radius);
  padding: 0.85rem 0.85rem 1rem;
  box-shadow: var(--hf-shadow);
}
.hf-sleeve-bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.35rem 0.55rem 0.75rem;
}
.hf-sleeve-bar p {
  margin: 0;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: #94A3B8;
}
.hf-chip {
  display: inline-flex;
  align-items: baseline;
  gap: 0.4rem;
  padding: 0.35rem 0.7rem;
  border-radius: 8px;
  background: var(--hf-amber);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  opacity: 0;
  transform: scale(0.85) rotate(-3deg);
}
.hf-chip em {
  font-style: normal;
  font-size: 0.65rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  opacity: 0.9;
}
.hf-sleeve.is-live .hf-chip {
  animation: hf-chip-in 0.45s cubic-bezier(0.22, 1.3, 0.36, 1) 0.15s forwards;
}
@keyframes hf-chip-in {
  to { opacity: 1; transform: scale(1) rotate(0deg); }
}

.hf-doc {
  background: var(--hf-surface);
  border-radius: 10px;
  padding: 1.5rem 1.35rem 1.75rem;
  border-left: 5px solid var(--hf-teal);
  color: var(--hf-ink);
  opacity: 0;
  transform: translateY(10px);
}
.hf-sleeve.is-live .hf-doc {
  animation: hf-doc-in 0.5s ease 0.05s forwards;
}
@keyframes hf-doc-in {
  to { opacity: 1; transform: translateY(0); }
}

.hf-body {
  font-family: var(--hf-read);
  font-size: 1.05rem;
  line-height: 1.7;
  color: var(--hf-ink);
  max-width: 40rem;
}
.hf-body h2 {
  margin: 1.65rem 0 0.55rem;
  font-family: var(--hf-display);
  font-weight: 600;
  font-size: 1.2rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--hf-ink);
  line-height: 1.25;
  position: relative;
  padding-bottom: 0.35rem;
}
.hf-body h2:first-child { margin-top: 0; }
.hf-body h2::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 0;
  background: linear-gradient(90deg, var(--hf-rose), var(--hf-teal));
  border-radius: 2px;
}
.hf-body h2.is-marked::after {
  animation: hf-rule 0.55s ease forwards;
}
@keyframes hf-rule {
  to { width: 3.5rem; }
}
.hf-body p {
  margin: 0 0 0.85rem;
  color: var(--hf-ink);
}
.hf-body ul {
  margin: 0 0 0.95rem;
  padding-left: 1.2rem;
}
.hf-body li {
  margin-bottom: 0.4rem;
  color: var(--hf-ink);
}
.hf-body strong { color: var(--hf-ink); font-weight: 700; }
.hf-body a {
  color: var(--hf-teal-deep);
  font-weight: 700;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}
.hf-body a:hover { color: var(--hf-rose); }

.hf-colo {
  text-align: center;
  padding: 0.25rem 0 1.75rem;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--hf-mute);
}
.hf-colo a {
  color: var(--hf-rose);
  text-decoration: none;
  font-weight: 800;
}
.hf-colo a:hover { color: var(--hf-teal-deep); }

@media (min-width: 700px) {
  .hf-doc { padding: 1.85rem 2rem 2.1rem; }
  .hf-body { font-size: 1.08rem; }
}

@media (prefers-reduced-motion: reduce) {
  .hf-sleeve.is-live .hf-chip,
  .hf-sleeve.is-live .hf-doc,
  .hf-body h2.is-marked::after {
    animation: none !important;
  }
  .hf-sleeve.is-live .hf-chip,
  .hf-sleeve.is-live .hf-doc {
    opacity: 1;
    transform: none;
  }
  .hf-body h2.is-marked::after { width: 3.5rem; }
  .hf-tab { transition: none; }
}
