/*
Theme Name: Symbol Hub
Author: TheWebReach
Description: Copy-first theme for a symbol copy-paste site. Big symbol box with copy and PNG download, tap-to-copy symbol grid with a collecting tray, verified code tables (Unicode, HTML, Alt, Mac, Word), symbol search, DefinedTerm, FAQ and breadcrumb schema, ad slots.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
License: GPL-2.0-or-later
Text Domain: sym
*/
@font-face { font-family: "Grotesk"; font-weight: 600; font-display: swap; src: url("assets/fonts/space-grotesk-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Grotesk"; font-weight: 700; font-display: swap; src: url("assets/fonts/space-grotesk-latin-700-normal.woff2") format("woff2"); }

/* A specimen-sheet look: navy ink, warm paper, marigold copy buttons, the symbol always the largest object. */
:root {
  --ink: #14213d;
  --ink-2: #4a5470;
  --paper: #faf8f2;
  --card: #ffffff;
  --line: #e6e1d3;
  --accent: #f2a516;       /* marigold: copy buttons, focus */
  --accent-ink: #14213d;
  --tint: #eef1f8;
  --wrap: 960px;
  --f-display: "Grotesk", "Segoe UI", system-ui, sans-serif;
  --f-body: system-ui, -apple-system, "Segoe UI", Roboto, "Noto Sans", "Noto Sans Devanagari", sans-serif;
  /* Symbols use the device's widest-coverage fonts. */
  --f-sym: "Segoe UI Symbol", "Segoe UI Emoji", "Noto Sans Symbols", "Noto Sans Symbols 2", "Noto Sans Math", "Apple Symbols", "Noto Sans", "Noto Sans Devanagari", "Noto Sans Gurmukhi", "Noto Sans Runic", system-ui, sans-serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 12px; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 400 17px/1.62 var(--f-body); }
a { color: #1f4fd1; text-underline-offset: 3px; }
a:hover { color: #b35c00; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px,1px,1px,1px); white-space: nowrap; }
.skip-link:focus { position: fixed; top: 8px; left: 8px; z-index: 100; width: auto; height: auto; clip: auto; background: var(--accent); color: var(--ink); padding: 8px 14px; border-radius: 8px; }
.wrap { max-width: var(--wrap); margin: 0 auto; padding-inline: 16px; }
h1, h2, h3 { font-family: var(--f-display); font-weight: 700; line-height: 1.15; letter-spacing: -.015em; text-wrap: balance; margin: 0 0 .5em; }
h1 { font-size: clamp(1.8rem, 1.3rem + 2.4vw, 2.75rem); }
h2 { font-size: clamp(1.3rem, 1.12rem + .9vw, 1.7rem); margin-top: 1.6em; }
h3 { font-size: 1.1rem; font-weight: 600; margin-top: 1.2em; }
p { margin: 0 0 1em; }
kbd { font: 600 .85em ui-monospace, Menlo, Consolas, monospace; background: #fff; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 5px; padding: 1px 6px; white-space: nowrap; }
code { font: .92em ui-monospace, Menlo, Consolas, monospace; background: var(--tint); padding: 1px 5px; border-radius: 5px; overflow-wrap: anywhere; }

/* Header */
.site-head { background: var(--ink); color: #fff; }
.bar { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 58px; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; text-decoration: none; min-width: 0; }
.brand:hover { color: #fff; }
.mark { display: grid; place-items: center; min-width: 40px; height: 34px; padding: 0 6px; border-radius: 9px; background: var(--accent); color: var(--ink); font: 700 1rem/1 var(--f-sym); }
.brand-name { font-family: var(--f-display); font-weight: 700; font-size: 1.22rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.head-find { color: #fff; font-size: .9rem; text-decoration: none; border: 1px solid rgba(255,255,255,.3); border-radius: 999px; padding: 5px 12px; white-space: nowrap; }
.head-find:hover { background: #fff; color: var(--ink); }
.chips { border-top: 1px solid rgba(255,255,255,.12); }
.chips ul { list-style: none; margin: 0 auto; padding: 8px 16px; display: flex; gap: 8px; overflow-x: auto; scrollbar-width: none; max-width: var(--wrap); }
.chips ul::-webkit-scrollbar { display: none; }
.chips a { display: block; white-space: nowrap; padding: 4px 12px; border-radius: 999px; color: #fff; text-decoration: none; font-size: .9rem; border: 1px solid rgba(255,255,255,.25); }
.chips a:hover, .chips a[aria-current="page"] { background: var(--accent); border-color: var(--accent); color: var(--ink); }

.crumbs { font-size: .88rem; color: var(--ink-2); margin: 18px 0 8px; }
.crumbs a { color: var(--ink-2); }
article { padding-bottom: 20px; }
.pg h1 { margin-top: 12px; }
.entry > p, .entry li, .sym-intro p { max-width: 72ch; }
.entry table { border-collapse: collapse; width: 100%; font-size: .95rem; margin: 0 0 1.2em; }
.entry th, .entry td { text-align: left; padding: 8px 10px; border-bottom: 1px solid var(--line); vertical-align: top; }
.entry th { background: var(--tint); font-weight: 600; }
.table-scroll { overflow-x: auto; }

/* Symbol box: hero glyph, actions, grid, tray */
.sym-box { background: var(--card); border: 1px solid var(--line); border-radius: 18px; padding: 16px; margin: 14px 0 26px; box-shadow: 0 12px 30px -20px rgba(20,33,61,.4); }
.sym-box > h2 { font-size: 1.08rem; margin: 0 0 12px; }
.sym-hero { display: grid; grid-template-columns: minmax(0, 190px) minmax(0, 1fr); gap: 16px; align-items: center; }
.sym-big { display: grid; place-items: center; aspect-ratio: 1; border-radius: 14px; background:
  linear-gradient(var(--tint) 1px, transparent 1px) 0 0 / 19px 19px, linear-gradient(90deg, var(--tint) 1px, transparent 1px) 0 0 / 19px 19px, #fff;
  border: 2px solid var(--ink); font: 400 clamp(4rem, 3rem + 6vw, 6.5rem)/1 var(--f-sym); color: var(--ink); overflow: hidden; text-align: center; }
.sym-big.long { font-size: clamp(2rem, 1.6rem + 2vw, 3rem); }
.sym-name { font: 700 1.15rem/1.3 var(--f-display); margin: 0 0 4px; }
.sym-code { color: var(--ink-2); font-size: .92rem; margin: 0 0 12px; }
.sym-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.sym-btn { border: 0; background: var(--accent); color: var(--accent-ink); font: 700 1rem var(--f-body); padding: 11px 22px; border-radius: 999px; cursor: pointer; }
.sym-btn:hover { filter: brightness(.95); }
.sym-btn.ghost { background: transparent; border: 2px solid var(--ink); padding: 9px 18px; }
@media (max-width: 520px) { .sym-hero { grid-template-columns: 1fr; } .sym-big { max-width: 200px; } }

.sym-grid { list-style: none; padding: 0; margin: 16px 0 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(92px, 1fr)); gap: 8px; }
.sym-grid li { max-width: none; }
.sym-tile { display: grid; justify-items: center; gap: 4px; width: 100%; height: 100%; padding: 10px 6px 8px; border: 1px solid var(--line); border-radius: 12px; background: #fff; cursor: pointer; color: var(--ink); }
.sym-tile:hover { border-color: var(--ink); background: #fffbf0; }
.sym-tile .g { font: 400 1.9rem/1.15 var(--f-sym); min-height: 2.2rem; display: grid; place-items: center; overflow-wrap: anywhere; }
.sym-tile .n { font-size: .72rem; line-height: 1.25; color: var(--ink-2); text-align: center; }
.sym-tile.on { outline: 2px solid var(--accent); }
.sym-tray { display: flex; gap: 8px; margin: 14px 0 0; align-items: stretch; }
.sym-tray input { flex: 1; min-width: 0; font: 1.25rem var(--f-sym); padding: 10px 12px; border: 2px solid var(--ink); border-radius: 12px; background: #fff; color: var(--ink); }
.sym-tray .sym-btn { padding: 10px 16px; }
.sym-hint { font-size: .85rem; color: var(--ink-2); margin: 8px 0 0; }

.sym-codes { margin: 14px 0 0; }
.sym-codes summary { cursor: pointer; font-weight: 600; padding: 6px 0; }
.sym-codes table { font-size: .88rem; }
.sym-codes td:first-child { font: 1.3rem var(--f-sym); text-align: center; }

/* Home search */
.sym-find { background: var(--ink); color: #fff; border-radius: 18px; padding: 18px; margin: 14px 0 26px; }
.sym-find h2 { color: #fff; margin: 0 0 10px; font-size: 1.15rem; }
.sym-find input { width: 100%; font: 500 1.15rem var(--f-body); padding: 13px 14px; border-radius: 12px; border: 0; color: var(--ink); }
.sym-find .sym-grid .sym-tile { border-color: transparent; }
.sym-find .sym-hint { color: #c9cfe0; }

/* Cards (hub children, related, home categories) */
.sym-cards { list-style: none; padding: 0; margin: 10px 0 0; display: grid; gap: 10px; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); }
.sym-cards li { max-width: none; }
.sym-card { display: flex; align-items: center; gap: 12px; padding: 10px 12px; background: #fff; border: 1px solid var(--line); border-radius: 14px; text-decoration: none; color: var(--ink); height: 100%; }
.sym-card:hover { border-color: var(--ink); color: var(--ink); }
.sym-card-g { display: grid; place-items: center; flex: 0 0 48px; height: 48px; border-radius: 10px; background: var(--tint); font: 1.6rem/1 var(--f-sym); overflow: hidden; }
.sym-card-t { font-weight: 600; line-height: 1.3; }

.sym-jump { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 8px; }
.sym-jump a { font-size: .86rem; padding: 3px 11px; border-radius: 999px; background: var(--tint); text-decoration: none; color: var(--ink); }
.sym-faq details { border-bottom: 1px solid var(--line); }
.sym-faq summary { cursor: pointer; list-style: none; padding: 12px 28px 12px 0; position: relative; }
.sym-faq summary::-webkit-details-marker { display: none; }
.sym-faq summary::after { content: "+"; position: absolute; right: 4px; top: 8px; font-size: 1.4rem; color: #b35c00; }
.sym-faq details[open] summary::after { content: "\2212"; }
.sym-faq summary h3 { display: inline; font: 600 1.02rem/1.4 var(--f-body); margin: 0; }
.sym-faq details > div { padding: 0 0 12px; }
.updated { color: var(--ink-2); font-size: .86rem; margin-top: 26px; }
.sym-ad { margin: 24px auto; text-align: center; min-height: 100px; }
.sym-ad:empty { display: none; }
.sym-toast { position: fixed; left: 50%; bottom: calc(18px + env(safe-area-inset-bottom, 0px)); transform: translate(-50%, 20px); background: var(--ink); color: #fff; padding: 9px 18px; border-radius: 999px; font-weight: 600; opacity: 0; pointer-events: none; transition: .2s; z-index: 90; font-family: var(--f-sym), var(--f-body); }
.sym-toast.on { opacity: 1; transform: translate(-50%, 0); }

.site-foot { background: var(--ink); color: #d5daea; margin-top: 50px; padding: 36px 0 24px; font-size: .9rem; }
.site-foot a { color: #fff; text-decoration: none; }
.site-foot a:hover { color: var(--accent); }
.foot-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); }
.foot-grid ul { list-style: none; padding: 0; margin: 8px 0 0; }
.foot-grid li { margin: 0 0 5px; }
.foot-title { font: 700 1rem var(--f-display); color: var(--accent); }
.foot-legal { border-top: 1px solid rgba(255,255,255,.15); margin-top: 26px; padding-top: 14px; display: flex; flex-wrap: wrap; gap: 8px 18px; color: #b6bdd3; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; } }
.sym-find li { display: grid; gap: 2px; }
.sym-open { text-align: center; font-size: .75rem; color: #c9cfe0; }
.sym-open:hover { color: var(--accent); }
