/* TorFresh dark coffee theme — larger typography and contained directory cards */
:root {
  --coffee: #17120f;
  --coffee-deep: #100d0b;
  --coffee-panel: #211a16;
  --green: #FFD700;
  --green-bright: #1fa337;
  --green-tint: rgba(66, 211, 146, .12);
  --white: #fffaf5;
  --text: #f8f5f1;
  --muted: #c1b8af;
  --line: rgba(255, 250, 245, .12);
  --content: 1120px;
  color-scheme: dark;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 82px; }
body {
  margin: 0; color: var(--text);
  background: radial-gradient(ellipse at 50% -15%, rgba(20,99,33,.12), transparent 44%), var(--coffee);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px; line-height: 1.65; -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
button { font: inherit; }
::selection { color: var(--coffee-deep); background: var(--green-bright); }
.site-header {
  position: sticky; top: 0; z-index: 20; height: 68px;
  border-bottom: 1px solid var(--line); background: rgba(23,18,15,.92); backdrop-filter: blur(16px);
}
.header-inner { max-width: var(--content); height: 100%; margin: 0 auto; padding: 0 24px; display: flex; align-items: center; justify-content: space-between; }
.brand { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font-size: 22px; font-weight: 850; letter-spacing: -.7px; transition: transform .2s, filter .2s; }
.brand:hover { transform: translateY(-1px); filter: drop-shadow(0 0 10px rgba(66,211,146,.2)); }
.brand-mark { width: 25px; height: 25px; color: var(--green); }
.brand-tor { color: var(--white); }
.brand-fresh { color: var(--green); }
.nav-links { display: flex; align-items: center; gap: 24px; }
.nav-links a { position: relative; padding: 7px 0; color: var(--muted); text-decoration: none; font-size: 15px; font-weight: 650; transition: color .2s; }
.nav-links a:first-child { color: var(--white); font-size: 16px; font-weight: 800; }
.nav-links a::after { position: absolute; right: 0; bottom: 1px; left: 0; height: 2px; content: ""; background: var(--green); transform: scaleX(0); transform-origin: left; transition: transform .2s; }
.nav-links a:hover { color: var(--green-bright); }
.nav-links a:hover::after { transform: scaleX(1); }
.intro { padding: 36px 20px 0; text-align: center; background: linear-gradient(180deg, rgba(42,33,27,.45), transparent 88%); }
.eyebrow { margin: 0 0 8px; color: var(--green-bright); font-size: 12px; font-weight: 850; letter-spacing: 2px; text-transform: uppercase; }
.intro h1 { margin: 0 auto; color: var(--green); font-size: clamp(30px,3.8vw,42px); line-height: 1.2; letter-spacing: -.9px; font-weight: 850; text-wrap: balance; }
.intro-copy { margin: 13px auto 0; color: var(--muted); font-size: 16px; }
.category-nav { max-width: var(--content); margin: 27px auto 0; display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; }
.category-pill { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; padding: 8px 17px; border: 1px solid rgba(66,211,146,.23); border-radius: 999px; background: rgba(66,211,146,.08); color: #bff8db; font-size: 13px; font-weight: 650; text-decoration: none; transition: background .18s,color .18s,border-color .18s,transform .18s,box-shadow .18s; }
.category-pill:hover,.category-pill:focus-visible { background: var(--green); border-color: var(--green); color: var(--coffee-deep); transform: translateY(-3px); box-shadow: 0 7px 20px rgba(66,211,146,.2); }
.category-pill.active { background: var(--green); border-color: var(--green); color: var(--coffee-deep); box-shadow: 0 4px 14px rgba(66,211,146,.14); }

/* =========================================
   TorFresh — Professional Advertisement Area
   ========================================= */

.ad-area {
  width: 100%;
  max-width: var(--content);
  margin: 28px auto 0;
  padding: 0 24px 34px;
  box-sizing: border-box;
}

.ad-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
  align-items: stretch;
}

/* Banner container */
.ad-slot {
  position: relative;
  min-width: 0;
  min-height: 90px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-sizing: border-box;

  border: 1px solid rgba(128, 235, 85, 0.18);
  border-radius: 12px;
  background: #171714;
  color: var(--green-bright);
  text-align: center;

  transition:
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

/* Subtle professional hover effect */
.ad-slot:hover {
  border-color: rgba(128, 235, 85, 0.55);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.24);
  transform: translateY(-2px);
}

/* Placeholder artwork */
.ad-slot svg {
  width: 24px;
  height: 24px;
  flex-shrink: 0;
}

.ad-slot small {
  color: #c4d8cc;
  font-size: 12px;
}

/* Advertiser link fills the banner container */
.ad-slot > a {
  display: flex;
  width: 100%;
  height: 100%;
  min-height: 90px;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  text-decoration: none;
}

/* Show the complete banner without cropping text or logos */
.ad-slot img {
  display: block;
  width: 100%;
  height: auto;
  max-height: 180px;
  object-fit: contain;
  object-position: center;
  margin: 0 auto;
}

/* Real advertisements */
.ad-slot.has-ad {
  padding: 0;
  background: #11110f;
  border-color: rgba(128, 235, 85, 0.14);
}

/* Keep linked banner images neatly contained */
.ad-slot.has-ad > a {
  padding: 0;
  overflow: hidden;
  border-radius: inherit;
}

/* Add-banner button */
.add-banner {
  width: 100%;
  min-height: 56px;
  margin-top: 18px;
  padding: 12px 18px;

  display: flex;
  align-items: center;
  justify-content: center;
  gap: 11px;
  box-sizing: border-box;

  border: 1px dashed rgba(128, 235, 85, 0.45);
  border-radius: 10px;
  background: rgba(128, 235, 85, 0.035);
  color: #bff8db;

  font-size: 14px;
  font-weight: 650;
  cursor: pointer;

  transition:
    color 0.18s ease,
    border-color 0.18s ease,
    background 0.18s ease,
    transform 0.18s ease;
}

.add-banner:hover {
  color: var(--green-bright);
  border-color: var(--green-bright);
  background: rgba(128, 235, 85, 0.08);
  transform: translateY(-1px);
}

.add-icon {
  display: inline-grid;
  place-items: center;
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--green);
  color: var(--coffee-deep);
  font-size: 20px;
  line-height: 1;
  transition: transform 0.2s ease;
}

.add-banner:hover .add-icon {
  transform: rotate(90deg);
}

.ad-help {
  margin: 10px 0 0;
  color: var(--muted);
  text-align: center;
  font-size: 12px;
  line-height: 1.5;
}

/* Tablet and mobile */
@media (max-width: 700px) {
  .ad-area {
    padding-right: 18px;
    padding-left: 18px;
  }

  .ad-grid {
    grid-template-columns: 1fr;
    gap: 14px;
  }

  .ad-slot img {
    max-height: none;
  }
}

@media (max-width: 400px) {
  .ad-area {
    padding-right: 12px;
    padding-left: 12px;
  }

  .ad-grid {
    gap: 12px;
  }

  .ad-slot {
    border-radius: 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .ad-slot,
  .add-banner,
  .add-icon {
    transition: none;
  }

  .ad-slot:hover,
  .add-banner:hover {
    transform: none;
  }
}

.site-notice {
  max-width: 900px;
  margin: 0 auto 28px;
  padding: 12px 18px;
  border: 1px solid rgba(20, 99, 33, 0.35);
  border-radius: 10px;
  background: rgba(20, 99, 33, 0.10);
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
  text-align: center;
}

.site-notice strong {
  color: var(--green-bright);
}
[hidden] { display: none !important; }
.directory-section { border-top: 1px solid var(--line); border-bottom: 1px solid rgba(255,250,245,.04); background: rgba(16,13,11,.38); }
.directory-grid { max-width: var(--content); margin: 0 auto; padding: 32px 24px 30px; display: grid; grid-template-columns: repeat(3,minmax(0,1fr)); gap: 22px; }
.directory-card {
  min-width: 0; padding: 22px 20px 20px; border: 1px solid rgba(66,211,146,.17); border-radius: 15px;
  background: linear-gradient(145deg,rgba(42,33,27,.98),rgba(29,24,20,.98));
  box-shadow: 0 9px 24px rgba(0,0,0,.26), inset 0 1px 0 rgba(255,250,245,.035);
  scroll-margin-top: 88px; transition: transform .22s,border-color .22s,box-shadow .22s;
}
.directory-card:hover { transform: translateY(-4px); border-color: rgba(66,211,146,.48); box-shadow: 0 17px 34px rgba(0,0,0,.34),0 0 0 1px rgba(66,211,146,.05); }
.directory-heading { display: flex; align-items: center; gap: 12px; margin-bottom: 15px; }
.directory-icon { flex: 0 0 44px; width: 44px; height: 44px; display: grid; place-items: center; border: 1px solid rgba(66,211,146,.16); border-radius: 50%; background: var(--green-tint); color: var(--green-bright); transition: color .2s,background .2s,transform .2s,box-shadow .2s; }
.directory-icon svg { width: 22px; height: 22px; }
.directory-card:hover .directory-icon { color: var(--coffee-deep); background: var(--green); transform: translateY(-2px) rotate(-4deg); box-shadow: 0 5px 16px rgba(66,211,146,.16); }
.directory-heading h2 { margin: 0; color: var(--green); font-size: 21px; line-height: 1.3; font-weight: 850; text-decoration: underline; text-decoration-color: rgba(66,211,146,.7); text-decoration-thickness: 1.5px; text-underline-offset: 5px; transition: color .2s; }
.directory-description {
  margin: 0 0 16px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.6;
}
.directory-card:hover .directory-heading h2 { color: var(--green-bright); }
.directory-list { margin: 0; padding: 0 0 0 2px; list-style: none; }
.directory-list li { margin: 8px 0; }
.directory-list a { display: inline-flex; align-items: baseline; gap: 8px; color: #f0eae4; font-size: 15px; line-height: 1.5; text-decoration: none; transition: color .16s,transform .16s; }
.directory-list a::before { content: "›"; color: var(--green); font-size: 20px; font-weight: 850; line-height: .7; transition: color .16s; }
.directory-list a:hover,.directory-list a:focus-visible { color: var(--green-bright); transform: translateX(3px); }
.directory-list a:hover::before { color: var(--green-bright); }
.directory-list a.link-offline { color: #FF160C; text-decoration: line-through; text-decoration-color: rgba(255, 107, 107, 0.7); }
.directory-list a.link-offline::before { color: #FF0000; }
.directory-list a.link-offline:hover, .directory-list a.link-offline:focus-visible { color: #ff9999; }
.directory-list a.link-offline::after { content: " (Offline)"; color: #EE4B2B; font-size: 11px; font-weight: 600; text-decoration: none; }
.directory-list a.link-outdated { color: #ffb454; }
.directory-list a.link-outdated::after { content: " (Caution)"; color: #C0C0C0; font-size: 11px; font-weight: 600; }
.about-section { padding: 26px 24px 50px; text-align: center; }
.about-section h2 { display: inline-block; margin: 0; padding: 0 16px 5px; border-bottom: 4px solid var(--green); border-radius: 0 0 3px 3px; color: var(--green); font-size: 26px; font-weight: 850; line-height: 1.3; text-decoration: underline; text-decoration-color: rgba(66,211,146,.65); text-underline-offset: 4px; }
.about-section p { max-width: 1200px; margin: 17px auto 0; color: var(--muted); font-size: 16px; }
.site-footer { padding: 20px 24px; border-top: 1px solid var(--line); background: var(--coffee-deep); color: #b9ada3; text-align: center; font-size: 13px; }
a:focus-visible,button:focus-visible { outline: 2px solid var(--green-bright); outline-offset: 4px; }
@media (max-width: 900px) {
  .directory-grid { grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
  .directory-card { padding: 20px 17px 18px; }
}
@media (max-width: 560px) {
  .site-header { height: 60px; }
  .header-inner { padding: 0 16px; }
  .brand { font-size: 20px; }
  .nav-links { gap: 15px; }
  .nav-links a,.nav-links a:first-child { font-size: 14px; }
  .intro { padding: 28px 16px 0; }
  .intro h1 { font-size: 29px; }
  .intro-copy { max-width: 330px; font-size: 15px; }
  .category-nav { gap: 7px; margin-top: 22px; }
  .category-pill { min-height: 36px; padding: 7px 12px; font-size: 12px; }
  .ad-area { padding: 0 14px 24px; margin-top: 20px; }
  .ad-grid { gap: 9px; }
  .ad-slot { min-height: 78px; border-radius: 8px; }
  .ad-slot svg { width: 20px; height: 20px; }
  .ad-slot small { font-size: 10px; }
  .add-banner { min-height: 50px; margin-top: 12px; font-size: 13px; }
  .directory-grid { padding: 24px 14px 24px; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 13px; }
  .directory-card { padding: 16px 12px 15px; border-radius: 12px; }
  .directory-heading { align-items: flex-start; gap: 8px; margin-bottom: 12px; }
  .directory-icon { flex-basis: 34px; width: 34px; height: 34px; }
  .directory-icon svg { width: 18px; height: 18px; }
  .directory-heading h2 { font-size: 17px; }
  .directory-list li { margin: 7px 0; }
  .directory-list a { font-size: 13px; gap: 5px; overflow-wrap: anywhere; }
  .about-section { padding: 23px 18px 38px; }
  .about-section h2 { font-size: 24px; }
  .about-section p { font-size: 15px; }
}
@media (max-width: 360px) {
  .directory-grid { grid-template-columns: 1fr; }
  .directory-card { padding: 20px 18px; }
}
@media (prefers-reduced-motion: reduce) {
  *,*::before,*::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}

.directory-description {
  font-size: 12px;
  line-height: 1.55;
  margin-bottom: 12px;
}

.skip-link {
  position: absolute;
  top: 0;
  left: -9999px;
  z-index: 1000;
  padding: 0.75rem 1rem;
  background: #fff;
  color: #111;
}

.skip-link:focus {
  left: 1rem;
  top: 1rem;
}
