
:root {
  --bg: #f8fafc;
  --bg-card: #ffffff;
  --bg-card-hover: #f1f5f9;
  --border: #e2e8f0;
  --border-hover: #0284c7;
  --primary: #0284c7;
  --primary-glow: rgba(2, 132, 199, 0.2);
  --accent: #10b981;
  --text: #0f172a;
  --text-muted: #475569;
  --nav-bg: rgba(255, 255, 255, 0.96);
  --badge-bg: rgba(2, 132, 199, 0.1);
  --badge-text: #0284c7;
  --btn-grad: linear-gradient(135deg, #0284c7 0%, #0369a1 100%);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif; }
body { background: var(--bg); color: var(--text); line-height: 1.65; min-height: 100vh; display: flex; flex-direction: column; overflow-x: hidden; }
a { color: var(--primary); text-decoration: none; transition: all 0.2s; }
a:hover { color: #0369a1; }

.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 20px; }

/* Navbar - STRICT NO SCROLLBAR */
.navbar { position: sticky; top: 0; z-index: 1000; background: var(--nav-bg); backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); box-shadow: 0 1px 4px rgba(0,0,0,0.03); overflow: visible !important; }
.navbar-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; gap: 12px; }
.brand { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 1.15rem; color: var(--text); text-decoration: none; flex-shrink: 0; }
.brand img { width: 34px; height: 34px; border-radius: 8px; flex-shrink: 0; }
.brand .badge { font-size: 0.72rem; padding: 2px 8px; border-radius: 9999px; background: var(--badge-bg); color: var(--badge-text); border: 1px solid rgba(2,132,199,0.2); font-weight: 600; }

.nav-links { display: flex; align-items: center; gap: 4px; list-style: none; margin: 0; padding: 0; flex-wrap: wrap; overflow: visible !important; }
.nav-links a { color: var(--text-muted); font-size: 0.9rem; font-weight: 500; padding: 6px 11px; border-radius: 6px; transition: all 0.15s; white-space: nowrap; }
.nav-links a:hover, .nav-links a.active { color: var(--primary); background: rgba(2,132,199,0.08); font-weight: 600; }

.nav-actions { display: flex; align-items: center; gap: 8px; flex-shrink: 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font-weight: 600; font-size: 0.9rem; padding: 8px 16px; border-radius: 8px; cursor: pointer; transition: all 0.2s; border: none; white-space: nowrap; text-decoration: none; }
.btn-primary { background: var(--btn-grad); color: #fff !important; box-shadow: 0 4px 12px var(--primary-glow); }
.btn-primary:hover { transform: translateY(-1px); box-shadow: 0 6px 18px var(--primary-glow); }
.btn-outline { background: #fff; border: 1px solid var(--border); color: var(--text); }
.btn-outline:hover { border-color: var(--primary); color: var(--primary); background: #f8fafc; }

/* Directory Hero */
.portal-hero { padding: 48px 0 32px; text-align: center; background: linear-gradient(180deg, #e0f2fe 0%, #f8fafc 100%); border-bottom: 1px solid #e2e8f0; }
.portal-tag { display: inline-flex; align-items: center; gap: 6px; padding: 4px 14px; border-radius: 9999px; background: #fff; color: #0284c7; font-size: 0.82rem; font-weight: 600; margin-bottom: 16px; border: 1px solid #bae6fd; box-shadow: 0 2px 6px rgba(0,0,0,0.04); }
.portal-hero h1 { font-size: clamp(1.9rem, 3.5vw, 2.7rem); font-weight: 800; color: #0f172a; margin-bottom: 14px; letter-spacing: -0.02em; }
.portal-hero h1 .highlight { color: #0284c7; }
.portal-hero p.lead { font-size: 1.05rem; color: var(--text-muted); max-width: 800px; margin: 0 auto 24px; line-height: 1.7; }

/* Simulated Search & Status Bar */
.search-box { max-width: 620px; margin: 0 auto 20px; display: flex; align-items: center; background: #fff; border: 2px solid #0284c7; border-radius: 9999px; padding: 6px 8px 6px 20px; box-shadow: 0 4px 16px rgba(2,132,199,0.12); }
.search-box input { border: none; outline: none; width: 100%; font-size: 0.95rem; color: #0f172a; background: transparent; }
.search-box .search-btn { background: var(--btn-grad); color: #fff; border: none; padding: 8px 20px; border-radius: 9999px; font-weight: 600; font-size: 0.88rem; cursor: pointer; flex-shrink: 0; }

.status-bulletin { display: inline-flex; align-items: center; gap: 8px; background: #ecfdf5; border: 1px solid #a7f3d0; color: #065f46; font-size: 0.85rem; font-weight: 500; padding: 6px 16px; border-radius: 9999px; }
.status-dot { width: 8px; height: 8px; border-radius: 50%; background: #10b981; }

/* 4 Official Access Gateway Cards */
.gateways-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; margin: 36px 0; }
.gateway-card { background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 24px; box-shadow: 0 4px 12px rgba(0,0,0,0.04); transition: all 0.2s; display: flex; flex-direction: column; justify-content: space-between; position: relative; }
.gateway-card:hover { border-color: var(--primary); transform: translateY(-3px); box-shadow: 0 8px 24px rgba(2,132,199,0.15); }
.gw-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 12px; }
.gw-name { font-size: 1.15rem; font-weight: 700; color: #0f172a; }
.gw-ping { font-size: 0.78rem; font-weight: 700; padding: 3px 8px; border-radius: 6px; background: #ecfdf5; color: #059669; font-family: monospace; }
.gw-desc { font-size: 0.88rem; color: var(--text-muted); margin-bottom: 18px; line-height: 1.55; }
.gw-btn { width: 100%; text-align: center; }

/* Section Title */
.sec-header { margin: 40px 0 20px; display: flex; align-items: center; justify-content: space-between; border-bottom: 2px solid #e2e8f0; padding-bottom: 12px; }
.sec-header h2 { font-size: 1.35rem; font-weight: 800; color: #0f172a; display: flex; align-items: center; gap: 8px; }
.sec-header .tag-more { font-size: 0.85rem; color: var(--primary); font-weight: 600; }

/* Mirror Table */
.mirror-table-box { background: #fff; border: 1px solid var(--border); border-radius: 12px; overflow-x: auto; box-shadow: 0 2px 8px rgba(0,0,0,0.03); margin-bottom: 30px; }
.mirror-table { width: 100%; border-collapse: collapse; text-align: left; }
.mirror-table th, .mirror-table td { padding: 14px 16px; border-bottom: 1px solid #f1f5f9; font-size: 0.9rem; }
.mirror-table th { background: #f8fafc; color: #334155; font-weight: 700; }
.mirror-table tr:hover { background: #f8fafc; }

/* 4-Category Directory Grid */
.dir-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; margin-bottom: 40px; }
.dir-col { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 22px; box-shadow: 0 2px 8px rgba(0,0,0,0.03); }
.dir-col h3 { font-size: 1.05rem; font-weight: 700; margin-bottom: 14px; color: #0f172a; border-left: 3px solid var(--primary); padding-left: 8px; }
.dir-col ul { list-style: none; display: flex; flex-direction: column; gap: 10px; }
.dir-col li a { font-size: 0.9rem; color: var(--text-muted); display: flex; align-items: center; justify-content: space-between; }
.dir-col li a:hover { color: var(--primary); font-weight: 500; }

/* Bookmark Box */
.bookmark-card { background: #eff6ff; border: 1px solid #bfdbfe; border-radius: 12px; padding: 22px; text-align: center; margin: 30px 0; }
.bookmark-card h3 { font-size: 1.15rem; font-weight: 700; color: #1e3a8a; margin-bottom: 6px; }
.bookmark-card p { font-size: 0.92rem; color: #3b82f6; }

/* Rich Box */
.rich-box { max-width: 900px; margin: 0 auto; background: #fff; border: 1px solid var(--border); border-radius: 14px; padding: 36px; font-size: 1rem; line-height: 1.8; box-shadow: 0 2px 10px rgba(0,0,0,0.03); }
.rich-box h2 { font-size: 1.35rem; margin: 24px 0 12px; color: #0f172a; border-left: 4px solid var(--primary); padding-left: 12px; }
.rich-box h3 { font-size: 1.15rem; margin: 18px 0 10px; color: #0f172a; }
.rich-box p { margin-bottom: 16px; color: var(--text-muted); }
.rich-box ul, .rich-box ol { margin: 0 0 20px 24px; color: var(--text-muted); }
.rich-box li { margin-bottom: 8px; }

/* Footer - ONLY 6 SITES MUTUAL LINKS */
footer { margin-top: auto; border-top: 1px solid var(--border); background: #ffffff; padding: 44px 0 24px; font-size: 0.88rem; }
.footer-friendly { border: 1px solid var(--border); border-radius: 12px; padding: 18px; background: #f8fafc; margin-bottom: 28px; }
.footer-friendly .title { font-size: 0.92rem; font-weight: 700; margin-bottom: 10px; color: #0f172a; }
.footer-friendly .links-flex { display: flex; flex-wrap: wrap; gap: 8px 12px; }
.friendly-link { font-size: 0.85rem; color: var(--text-muted); padding: 5px 12px; background: #fff; border-radius: 6px; border: 1px solid var(--border); text-decoration: none; transition: all 0.2s; }
.friendly-link:hover { color: var(--primary); border-color: var(--primary); background: #f0f9ff; }
.friendly-link.current { border-color: var(--primary); color: #0284c7; font-weight: 600; background: #e0f2fe; }

.footer-main { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 32px; margin-bottom: 30px; }
.footer-about h3 { font-size: 1.05rem; margin-bottom: 10px; color: #0f172a; }
.footer-about p { color: var(--text-muted); font-size: 0.85rem; line-height: 1.6; }
.footer-col h4 { font-size: 0.92rem; font-weight: 700; margin-bottom: 12px; color: #0f172a; }
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 8px; }
.footer-col a { color: var(--text-muted); font-size: 0.85rem; }
.footer-col a:hover { color: var(--primary); }
.footer-copy { border-top: 1px solid var(--border); padding-top: 18px; text-align: center; color: var(--text-muted); font-size: 0.82rem; }

/* Jump Dock */
.jump-dock { position: fixed; right: 20px; bottom: 24px; display: flex; flex-direction: column; gap: 8px; z-index: 999; }
.dock-circle { width: 42px; height: 42px; border-radius: 50%; background: #fff; border: 1px solid var(--border); color: var(--text); display: flex; align-items: center; justify-content: center; box-shadow: 0 4px 14px rgba(0,0,0,0.1); text-decoration: none; cursor: pointer; transition: all 0.2s; }
.dock-circle.primary { background: var(--btn-grad); color: #fff; border: none; }
.dock-circle:hover { transform: scale(1.08); }

@media (max-width: 900px) {
  .footer-main { grid-template-columns: 1fr; gap: 20px; }
  .navbar-inner { height: auto; padding: 12px 0; flex-wrap: wrap; }
}
