/* ═══════════════════════════════════════════════════════════════════
   shared/site.css  —  Global styles shared across all tool pages
   and the landing page.
   ═══════════════════════════════════════════════════════════════════ */

/* ── Smooth scroll (respects reduced motion) ─────────────────── */
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

/* ── Focus-visible ring (keyboard accessibility) ─────────────── */
:focus-visible {
  outline: 2px solid var(--accent, #4f8ef7);
  outline-offset: 2px;
  border-radius: 4px;
}
:focus:not(:focus-visible) { outline: none; }

/* ── Skip-to-content link ────────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 16px;
  z-index: 999;
  padding: 10px 20px;
  background: var(--accent, #4f8ef7);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 700;
  border-radius: 0 0 8px 8px;
  text-decoration: none;
  transition: top .2s;
}
.skip-link:focus {
  top: 0;
}

/* ── Tokens (must match each tool's :root for seamless blending) ── */
:root {
  --bg:        #0d1117;
  --surface:   #161b27;
  --surface2:  #1f2535;
  --border:    #2a3050;
  --accent:    #4f8ef7;
  --accent-lo: rgba(79,142,247,.22);
  --green:     #3ddc84;
  --red:       #ff5555;
  --gold:      #f5c842;
  --text:      #dde3f0;
  --text-dim:  #6b7a99;
  --font:      'Segoe UI', system-ui, sans-serif;
  --radius:    12px;
}

/* ── Site navigation bar (used by every tool page) ────────────── */
.site-nav {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 8px 0 4px;
  margin-bottom: 2px;
  border-bottom: 1px solid var(--border);
}

.site-nav-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none;
  padding: 5px 12px;
  border: 1px solid rgba(79,142,247,.35);
  border-radius: 7px;
  background: rgba(79,142,247,.08);
  transition: background .18s, box-shadow .18s;
}
.site-nav-back:hover {
  background: rgba(79,142,247,.18);
  box-shadow: 0 0 10px var(--accent-lo);
}
.site-nav-back:active { transform: scale(0.97); }

.site-nav-title {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: .08em;
  color: var(--text-dim);
}

/* ── Landing page layout ──────────────────────────────────────── */
.landing-header {
  display: flex;
  align-items: center;
  gap: 36px;
  padding: 48px 0 32px;
}

/* Big hero logo — sits to the left of the title block */
.landing-logo-hero {
  height: 150px;
  width: auto;
  flex-shrink: 0;
  /* drop-shadow gives depth without a visible box */
  filter: drop-shadow(0 4px 24px rgba(79, 142, 247, 0.25));
}

/* Title + tagline wrapper */
.landing-text {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.landing-header h1 {
  font-size: 3rem;
  font-weight: 800;
  background: linear-gradient(120deg, #4f8ef7 0%, #a78bfa 55%, #f5c842 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.1;
  margin: 0;
}

.landing-header p {
  font-size: 1.05rem;
  color: var(--text-dim);
  margin: 0;
  line-height: 1.5;
}

/* Collapse to vertical stack on narrow screens */
@media (max-width: 560px) {
  .landing-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 20px;
    padding: 48px 0 24px;
  }
  .landing-logo-hero { height: 110px; }
  .landing-header h1  { font-size: 2.2rem; }
}

/* ── Tool grid ────────────────────────────────────────────────── */
.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 18px;
  padding: 0 0 48px;
}

/* ── Tool card ────────────────────────────────────────────────── */
.tool-card {
  position: relative;
  display: flex;
  flex-direction: column;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  text-decoration: none;
  color: var(--text);
  transition: transform .22s, box-shadow .22s, border-color .22s;
}
.tool-card:hover {
  transform: translateY(-4px) scale(1.01);
  box-shadow: 0 12px 40px rgba(79,142,247,.22);
  border-color: rgba(79,142,247,.55);
}
.tool-card:hover .tool-card-thumb { filter: brightness(1.08); }

/* top accent stripe */
.tool-card::before {
  content: '';
  display: block;
  height: 3px;
  background: var(--card-accent, var(--accent));
  border-radius: var(--radius) var(--radius) 0 0;
}

.tool-card-thumb {
  width: 100%;
  height: 130px;
  object-fit: contain;
  background: var(--surface2);
  padding: 14px;
  border-bottom: 1px solid var(--border);
  transition: filter .22s;
}

/* placeholder thumb when no image is set */
.tool-card-thumb.placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 3rem;
  color: var(--text-dim);
}

.tool-card-body {
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
}

.tool-card-name {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text);
}

.tool-card-desc {
  font-size: 0.78rem;
  color: var(--text-dim);
  line-height: 1.55;
}

.tool-card-footer {
  margin-top: auto;
  padding-top: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.tool-card-tag {
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .07em;
  padding: 3px 9px;
  border-radius: 20px;
  background: var(--accent-lo);
  color: var(--accent);
}

.tool-card-tag.coming-soon {
  background: rgba(107,122,153,.15);
  color: var(--text-dim);
}

.tool-card-arrow {
  font-size: 1rem;
  color: var(--accent);
  transition: transform .18s;
}
.tool-card:hover .tool-card-arrow { transform: translateX(4px); }

/* ── "Coming soon" overlay ────────────────────────────────────── */
.tool-card.disabled {
  pointer-events: none;
  opacity: 0.55;
}

/* ── Landing footer ───────────────────────────────────────────── */
.landing-footer {
  padding: 32px 0 36px;
  font-size: 0.75rem;
  color: var(--text-dim);
  border-top: 1px solid var(--border);
}
.landing-footer p { text-align: center; margin-top: 24px; }
.footer-links {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 20px 16px;
  margin-bottom: 8px;
}
.footer-col h3 {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text, #dde3f0);
  margin: 0 0 6px;
}
.footer-col a {
  display: block;
  font-size: 0.72rem;
  color: var(--text-dim, #6b7a99);
  text-decoration: none;
  padding: 2px 0;
  transition: color 0.15s;
}
.footer-col a:hover { color: var(--accent, #4f8ef7); }

/* ── Tool page footer ────────────────────────────────────────── */
.tool-footer {
  margin-top: 40px;
  padding: 20px 0;
  border-top: 1px solid var(--border, #2a3050);
  text-align: center;
  font-size: 0.72rem;
  color: var(--text-dim, #6b7a99);
}
.tool-footer nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 6px 14px;
  margin-bottom: 12px;
}
.tool-footer nav a {
  color: var(--text-dim, #6b7a99);
  text-decoration: none;
  transition: color 0.15s;
}
.tool-footer nav a:hover { color: var(--accent, #4f8ef7); }
.tool-footer p { margin: 0; }

/* ── Fixed brand logo — top-left corner, every page ───────────── */
/*
   Two-step background removal (no transparent PNG needed):
     1. filter:invert(1)        → white-bg becomes black, brand
                                   darks become light/white
     2. mix-blend-mode:screen   → black (ex-white-bg) screened
                                   against the dark page ≈ invisible;
                                   light elements remain bright & visible
*/
.logo-fixed {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 300;
  display: block;
  line-height: 0;
  text-decoration: none;
  padding: 8px 18px 10px;
  /* Barely-there frosted backdrop — anchors the logo visually
     if it ever overlaps colourful content */
  background: rgba(13, 17, 23, 0.45);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  border-bottom-right-radius: 14px;
  border-right:  1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
  transition: background .2s;
}
.logo-fixed:hover {
  background: rgba(13, 17, 23, 0.82);
}
.logo-fixed img {
  height: 36px;
  width: auto;
  display: block;
  /* transparent PNG — no filter tricks needed */
  transition: opacity .2s;
}
.logo-fixed:hover img { opacity: 0.82; }
/* tiny home-icon badge on the logo */
.logo-fixed::after {
  content: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='10' viewBox='0 0 24 24' fill='none' stroke='%234fc3f7' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M3 9l9-7 9 7v11a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2z'/%3E%3Cpolyline points='9 22 9 12 15 12 15 22'/%3E%3C/svg%3E");
  position: absolute; bottom: 4px; right: 4px;
  display: flex; align-items: center; justify-content: center;
  width: 18px; height: 18px;
  background: rgba(13,17,23,0.85);
  border: 1px solid rgba(79,195,247,.35); border-radius: 4px;
  opacity: 0.65; transition: opacity .18s;
}
.logo-fixed:hover::after { opacity: 1; }

/* give tool-page nav a left indent so it never hides behind the logo */
.site-nav { padding-left: 10px; }

/* ── SEO content sections (About / How-to-use articles) ────────── */
.seo-about,
.seo-article {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px 36px;
  margin: 32px 0 0;
}

.seo-about h2,
.seo-article h2 {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text);
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.seo-about h3,
.seo-article h3 {
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  margin: 22px 0 8px;
  text-transform: uppercase;
  letter-spacing: .07em;
}

.seo-about p,
.seo-article p {
  font-size: 0.875rem;
  color: var(--text-dim);
  line-height: 1.78;
  margin: 0 0 10px;
}

.seo-about ul,
.seo-article ul {
  list-style: none;
  padding: 0;
  margin: 8px 0 12px;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

.seo-about li,
.seo-article li {
  font-size: 0.875rem;
  color: var(--text-dim);
  line-height: 1.65;
  padding-left: 18px;
  position: relative;
}

.seo-about li::before,
.seo-article li::before {
  content: '›';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-weight: 700;
}

.seo-about strong,
.seo-article strong {
  color: var(--text);
  font-weight: 600;
}

@media (max-width: 600px) {
  .seo-about,
  .seo-article { padding: 22px 18px; }
}

/* ── Developer card ───────────────────────────────────────────── */
.dev-card {
  display: flex;
  align-items: center;
  gap: 28px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 32px;
  margin: 24px 0 0;
  position: relative;
  overflow: hidden;
}

/* LinkedIn-to-accent gradient top stripe */
.dev-card::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(90deg, #0a66c2 0%, #4f8ef7 55%, #a78bfa 100%);
}

.dev-photo-wrap { flex-shrink: 0; }

.dev-photo {
  width: 92px;
  height: 92px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center top;
  border: 3px solid #0a66c2;
  box-shadow: 0 0 0 4px rgba(10,102,194,0.20),
              0 4px 20px rgba(10,102,194,0.25);
  display: block;
}

.dev-info {
  display: flex;
  flex-direction: column;
  gap: 5px;
}

.dev-label {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .12em;
  color: var(--text-dim);
  margin-bottom: 2px;
}

.dev-name {
  font-size: 1.12rem;
  font-weight: 800;
  color: var(--text);
  line-height: 1.2;
}

.dev-title {
  font-size: 0.83rem;
  color: var(--accent);
  font-weight: 500;
}

.dev-degree {
  font-size: 0.76rem;
  color: var(--text-dim);
  font-style: italic;
}

.dev-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 6px;
}

.dev-tags span {
  font-size: 0.63rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .06em;
  padding: 3px 10px;
  border-radius: 20px;
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text-dim);
}

.dev-linkedin {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 10px;
  padding: 8px 18px;
  background: #0a66c2;
  color: #fff;
  border-radius: 8px;
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 700;
  width: fit-content;
  transition: background .18s, box-shadow .18s, transform .18s;
}
.dev-linkedin:hover {
  background: #004182;
  box-shadow: 0 4px 18px rgba(10,102,194,0.40);
  transform: translateY(-1px);
}
.dev-linkedin svg { flex-shrink: 0; }

@media (max-width: 600px) {
  .dev-card {
    flex-direction: column;
    align-items: flex-start;
    padding: 22px 18px;
    gap: 16px;
  }
  .dev-photo { width: 76px; height: 76px; }
}
