/* gemdat.org home page (2026 redesign). Everything is scoped under .gdhome. */

/* undo legacy globals from gemdat.css inside the home page */
.gdhome h1,.gdhome h2,.gdhome h3,.gdhome h4{margin:0;line-height:1.2;text-align:left;font-family:var(--font)}
.gdhome ul{margin:0;padding:0;font-family:var(--font);font-size:inherit}
.gdhome li{list-style:none}
.gdhome img{display:block;max-width:100%;border:0}
.gdhome table{border-collapse:collapse}
.gdhome input,.gdhome select,.gdhome button{font-family:var(--font)}
body.gdx .gdhome a.btn{color:var(--ink);text-decoration:none}
body.gdx .gdhome a.btn.primary{color:#fff}
.gdhome .sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0)}
.gdhome .wrap{max-width:1600px;margin:0 auto;padding:0 16px}
.gdhome .top{padding-top:16px}

/* ---------- layout ---------- */
.gdhome .layout{display:grid;grid-template-columns:minmax(0,1fr) 320px;gap:16px;padding-top:16px;padding-bottom:32px}
.gdhome .top{padding-top:16px}
.gdhome .col{display:flex;flex-direction:column;gap:16px;min-width:0}
.gdhome .panel{background:var(--panel);border:1px solid var(--line);border-radius:var(--radius);min-width:0}
.gdhome .ph{display:flex;align-items:baseline;gap:12px;padding:12px 16px;border-bottom:1px solid var(--line);flex-wrap:wrap}
.gdhome .ph h2{font-size:16px;font-weight:700}
.gdhome .ph .sub{color:var(--ink-3);font-size:12.5px}
.gdhome .ph .tools{margin-left:auto;display:flex;gap:10px;align-items:center;flex-wrap:wrap;font-size:12.5px}
.gdhome .pb{padding:14px 16px}
.gdhome .more{font-size:12.5px;font-weight:600}
.gdhome .btn{display:inline-flex;align-items:center;gap:6px;font:inherit;font-size:12.5px;font-weight:600;padding:6px 10px;border-radius:var(--radius);border:1px solid var(--line-2);background:var(--panel);color:var(--ink);cursor:pointer;text-decoration:none}
.gdhome .btn:hover{border-color:var(--brand-2);text-decoration:none}
.gdhome .btn.primary{background:var(--brand);border-color:var(--brand);color:#fff}
.gdhome .chip{display:inline-flex;align-items:center;gap:6px;color:var(--ink-2)}
.gdhome .chip input{accent-color:var(--brand)}
.gdhome /* ---------- colour explorer ---------- */
.cx{display:grid;grid-template-columns:minmax(0,1fr) 340px;gap:0}
.gdhome .cx-grid{padding:14px 16px;border-right:1px solid var(--line);min-width:0}
.gdhome .cx-scroll{padding-bottom:2px}
.gdhome .cgrid{display:grid;grid-template-columns:150px repeat(26,minmax(8px,1fr));gap:2px}
.gdhome .cgrid .hl{position:sticky;left:0;z-index:4;background:var(--panel);font-size:11px;color:var(--ink-3);text-align:right;padding-right:8px;align-self:center;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.gdhome .cgrid .hue{height:10px;border-radius:2px;cursor:pointer;border:0;padding:0}
.gdhome .cgrid .hue:hover,.gdhome .cgrid .hue.on{outline:2px solid var(--ink);outline-offset:1px}
.gdhome .cell{position:relative;height:25px;border-radius:3px;border:0;padding:0;cursor:pointer}
.gdhome .cell.empty{cursor:default;opacity:.28}
.gdhome .cell.none{background:transparent!important;cursor:default}
.gdhome .cell .n{position:absolute;inset:0;display:grid;place-items:center;font-size:9.5px;font-weight:700;opacity:0}
.gdhome .show-n .cell .n{opacity:1}
.gdhome .cell:not(.empty):not(.none):hover{transform:scale(1.18);z-index:2;box-shadow:0 2px 6px rgba(0,0,0,.35)}
.gdhome .cell.on{outline:3px solid var(--ink);outline-offset:1px;z-index:3}
.gdhome .hbar{height:50px;display:flex;flex-direction:column;justify-content:flex-end;align-items:stretch;margin-top:6px;cursor:pointer;text-decoration:none!important}
.gdhome .hbar i{display:block;border-radius:2px 2px 0 0;min-height:2px}
.gdhome .hbar span{font-size:9.5px;color:var(--ink-3);text-align:center;margin-top:2px}
.gdhome .hbar:hover span{color:var(--ink)}
.gdhome .cgrid .hl.bl{align-self:end;padding-bottom:14px}
.gdhome .cx-foot{margin-top:8px;font-size:12.5px;color:var(--ink-3)}
.gdhome .match{display:flex;align-items:center;gap:8px}
.gdhome .match input[type=color]{width:34px;height:28px;border:1px solid var(--line-2);border-radius:4px;padding:1px;background:var(--panel)}
.gdhome .match output{color:var(--ink-3)}
.gdhome .cx-detail{padding:14px 16px;display:flex;flex-direction:column;gap:10px;min-width:0}
.gdhome .cx-detail .cdesc{font-size:14px}
.gdhome .cx-actions .btn{flex:1;justify-content:center}
.gdhome .sw{height:40px;border-radius:var(--radius);display:flex;align-items:flex-end;padding:8px 10px;font-weight:700;font-size:12px;border:1px solid rgba(0,0,0,.08)}
.gdhome .cdesc{font-weight:700;font-size:15px}
.gdhome .cmeta{color:var(--ink-3);font-size:12.5px}
.gdhome .splist{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:5px}
.gdhome .splist li{display:grid;grid-template-columns:minmax(0,1fr) 70px 22px;gap:8px;align-items:center;font-size:13px}
.gdhome .splist .bar{height:6px;background:var(--brand-soft);border-radius:3px;overflow:hidden}
.gdhome .splist .bar i{display:block;height:100%;background:var(--brand-2)}
.gdhome .splist .c{text-align:right;color:var(--ink-3);font-size:12px}
.gdhome .thumbs{display:grid;grid-template-columns:repeat(4,1fr);gap:6px}
.gdhome .thumbs a{display:block;border-radius:4px;overflow:hidden;background:var(--panel-2);aspect-ratio:1}
.gdhome .thumbs img{width:100%;height:100%;object-fit:cover}
.gdhome .cx-actions{display:flex;gap:8px;flex-wrap:wrap}
.gdhome .lbl{font-size:11.5px;font-weight:700;text-transform:uppercase;letter-spacing:.04em;color:var(--ink-3)}
.gdhome /* ---------- RI / SG identifier ---------- */
.id2{display:grid;grid-template-columns:minmax(0,1fr) 280px}
.gdhome .plot{padding:10px 8px 6px 4px;border-right:1px solid var(--line);min-width:0;position:relative}
.gdhome .plot svg{width:100%;height:auto;display:block;touch-action:manipulation}
.gdhome .plot .ax{fill:var(--ink-3);font-size:10px}
.gdhome .plot .grid{stroke:var(--line);stroke-width:1}
.gdhome .plot .sp{fill:var(--ink-3);fill-opacity:.16;stroke:var(--ink-3);stroke-opacity:.35;stroke-width:.6;cursor:pointer}
.gdhome .plot .sp.hit{fill:var(--hit);fill-opacity:.45;stroke:var(--hit);stroke-opacity:1}
.gdhome .plot .sp:hover{fill-opacity:.6}
.gdhome .plot .band{fill:var(--brand-2);fill-opacity:.08}
.gdhome .plot .xh{stroke:var(--brand-2);stroke-width:1;stroke-dasharray:3 3}
.gdhome .tip{position:absolute;pointer-events:none;background:var(--ink);color:var(--panel);font-size:12px;padding:5px 8px;border-radius:4px;white-space:nowrap;display:none;z-index:5}
.gdhome .idform{padding:14px 16px;display:flex;flex-direction:column;gap:10px;min-width:0}
.gdhome .fields{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.gdhome .fields label{display:flex;flex-direction:column;gap:3px;font-size:12px;color:var(--ink-2);font-weight:600}
.gdhome .fields input,.gdhome .fields select{font:inherit;font-size:14px;padding:6px 8px;border:1px solid var(--line-2);border-radius:4px;background:var(--panel);color:var(--ink);min-width:0;width:100%}
.gdhome .cands{list-style:none;margin:0;padding:0;max-height:248px;overflow:auto;border-top:1px solid var(--line)}
.gdhome .cands li{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:2px 8px;padding:6px 0;border-bottom:1px solid var(--line);font-size:13px}
.gdhome .cands .v{grid-column:1/-1;color:var(--ink-3);font-size:11.5px;font-family:var(--mono)}
.gdhome .cands .s{color:var(--ink-3);font-size:11.5px}
.gdhome .empty-note{color:var(--ink-3);font-size:12.5px;padding:8px 0}
.gdhome /* ---------- section rows (mirrors mindat's label + tiles rows) ---------- */
.row{display:grid;grid-template-columns:200px minmax(0,1fr);gap:16px;align-items:start}
.gdhome .row .intro h2{font-size:18px;margin-bottom:6px}
.gdhome .row .intro p{margin:0 0 10px;color:var(--ink-2);font-size:13px}
.gdhome .tiles{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:10px}
.gdhome .tile{display:block;color:var(--ink);border:1px solid var(--line);border-radius:var(--radius);overflow:hidden;background:var(--panel)}
.gdhome .tile:hover{border-color:var(--brand-2);text-decoration:none}
.gdhome .tile .im{aspect-ratio:1;background:#f3f1ec}
.gdhome .tile .im img{width:100%;height:100%;object-fit:cover}
.gdhome .tile .cap{padding:6px 8px}
.gdhome .tile .cap b{display:block;font-size:13px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.gdhome .tile .cap span{display:block;font-size:11.5px;color:var(--ink-3);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.gdhome .az{display:flex;flex-wrap:wrap;gap:4px;margin-top:12px}
.gdhome .az a{min-width:30px;text-align:center;padding:4px 0 3px;border:1px solid var(--line);border-radius:4px;color:var(--ink);font-weight:600;font-size:13px;background:var(--panel-2)}
.gdhome .az a small{display:block;font-size:10px;font-weight:400;color:var(--ink-3)}
.gdhome .az a:hover{border-color:var(--brand-2);text-decoration:none}
.gdhome .two{display:grid;grid-template-columns:1fr 1fr;gap:16px}
.gdhome table.list{width:100%;border-collapse:collapse;font-size:13px}
.gdhome table.list td{padding:7px 0;border-bottom:1px solid var(--line);vertical-align:middle}
.gdhome table.list tr:last-child td{border-bottom:0}
.gdhome table.list td.r{text-align:right;width:110px}
.gdhome .meter{display:inline-grid;grid-template-columns:60px 28px;gap:6px;align-items:center}
.gdhome .meter i{display:block;height:6px;background:var(--brand-2);border-radius:3px}
.gdhome .meter span{text-align:right;color:var(--ink-3);font-size:12px}
.gdhome .loc b{display:block;font-weight:600}
.gdhome .loc span{display:block;color:var(--ink-3);font-size:11.5px}
.gdhome /* ---------- sidebar ---------- */
.gid .pb{display:flex;flex-direction:column;gap:12px}
.gdhome .gid .logo2{display:block;width:170px;height:auto;margin:2px 0 4px}   /* trimmed logo at its own proportions (was cropped by object-fit) */
@media (prefers-color-scheme: dark){
.gdhome :root:not([data-theme="light"]) .gid .logo2{filter:invert(1)}
}
.gdhome :root[data-theme="dark"] .gid .logo2{filter:invert(1)}
.gdhome .gid p{margin:0;color:var(--ink-2);font-size:13px}
.gdhome .gid form{display:flex;gap:6px}
.gdhome .gid input{flex:1;min-width:0;font:600 15px var(--mono);letter-spacing:.06em;padding:8px 10px;border:1px solid var(--line-2);border-radius:var(--radius);text-transform:uppercase;background:var(--panel);color:var(--ink)}
.gdhome .kv{display:grid;grid-template-columns:1fr 1fr;gap:8px}
.gdhome .kv div{background:var(--panel-2);border-radius:4px;padding:6px 8px}
.gdhome .kv div.full{grid-column:1/-1}
.gdhome .kv b{display:block;font-size:16px}
.gdhome .kv span{font-size:11.5px;color:var(--ink-3)}
.gdhome .gidlist{list-style:none;margin:0;padding:0}
.gdhome .gidlist li a{display:grid;grid-template-columns:40px minmax(0,1fr);gap:8px;align-items:center;padding:6px 0;border-top:1px solid var(--line);color:var(--ink)}
.gdhome .gidlist li a:hover{text-decoration:none;background:var(--panel-2)}
.gdhome .gidlist img{width:40px;height:40px;object-fit:cover;border-radius:4px;background:var(--panel-2)}
.gdhome .gidlist code{font:600 12px var(--mono);color:var(--brand-2)}
.gdhome .gidlist span{display:block;font-size:12.5px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.gdhome ul.links{list-style:none;margin:0;padding:0}
.gdhome ul.links li{display:flex;justify-content:space-between;gap:8px;padding:6px 0;border-bottom:1px solid var(--line);font-size:13px}
.gdhome ul.links li:last-child{border-bottom:0}
.gdhome ul.links small{color:var(--ink-3)}
.gdhome .bs{display:flex;gap:10px;align-items:center}
.gdhome .bs .dot{width:34px;height:34px;border-radius:50%;flex:none;border:1px solid rgba(0,0,0,.12)}
.gdhome footer{background:var(--util);color:var(--util-ink);font-size:13px}
.gdhome footer .wrap{display:grid;grid-template-columns:2fr repeat(4,1fr);gap:24px;padding-top:28px;padding-bottom:28px}
.gdhome footer h4{color:#fff;font-size:13px;margin-bottom:8px}
.gdhome footer ul{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:5px}
.gdhome footer a{color:var(--util-ink)}
.gdhome footer a:hover{color:#fff}
.gdhome .fine{border-top:1px solid rgba(255,255,255,.1)}
.gdhome .fine .wrap{display:flex;justify-content:space-between;padding-top:10px;padding-bottom:10px;font-size:12px;grid-template-columns:none;flex-wrap:wrap;gap:8px}

/* ---------- responsive ---------- */
/* ---------- responsive ---------- */
@media (max-width:1500px){
.gdhome .cell{height:21px}
.gdhome .hbar{height:44px}
}
@media (max-width:1100px){
.gdhome .layout{grid-template-columns:minmax(0,1fr)}
.gdhome aside.col{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px}
.gdhome .tiles{grid-template-columns:repeat(4,minmax(0,1fr))}
.gdhome .tiles .tile:nth-child(n+5){display:none}
}
@media (max-width:820px){
.gdhome .cx,.gdhome .id2{grid-template-columns:minmax(0,1fr)}
.gdhome .match output{display:none}
.gdhome .cx-grid,.gdhome .plot{border-right:0;border-bottom:1px solid var(--line)}
.gdhome .row{grid-template-columns:minmax(0,1fr)}
.gdhome .two{grid-template-columns:minmax(0,1fr)}
}
@media (max-width:560px){
.gdhome aside.col{grid-template-columns:minmax(0,1fr)}
.gdhome .tiles{grid-template-columns:repeat(3,minmax(0,1fr))}
.gdhome .tiles .tile:nth-child(n+4){display:none}
.gdhome .cgrid{grid-template-columns:62px repeat(26,minmax(8px,1fr));gap:1px}
.gdhome .cgrid .hl{font-size:8.5px;padding-right:4px}
.gdhome .cell{height:15px;border-radius:2px}
.gdhome .hbar span{display:none}
.gdhome .hbar{height:36px}
}

/* tiles, A–Z and gemdatID rows are dark text, not link-blue */
body.gdx .gdhome a.tile,body.gdx .gdhome .az a,body.gdx .gdhome .gidlist a{color:var(--ink)}
body.gdx .gdhome a.tile:hover,body.gdx .gdhome .az a:hover,body.gdx .gdhome .gidlist a:hover{text-decoration:none}
body.gdx .gdhome .gidlist code{color:var(--brand-2)}
.gdhome .bs-all{margin:10px 0 0;font-size:13.5px;font-weight:600}
/* partner banner under Contribute */
.gdhome .gma-link{margin:14px 0 0}
.gdhome .gma-link a{display:block;border-radius:8px;overflow:hidden;box-shadow:0 2px 10px rgba(0,0,0,.12)}
.gdhome .gma-link a:hover{box-shadow:0 4px 16px rgba(0,0,0,.22)}
.gdhome .gma-link img{display:block;width:100%;height:auto}
.gdhome .gma-link figcaption{margin-top:4px;font-size:10.5px;text-transform:uppercase;letter-spacing:.06em;color:var(--ink-3);text-align:right}
/* RI identifier: SG / birefringence switch */
.gdhome .idmode{display:inline-flex;border:1px solid var(--line-2);border-radius:999px;overflow:hidden}
.gdhome .idmode button{border:0;background:none;padding:4px 11px;font:inherit;font-size:12.5px;font-weight:600;color:var(--ink-2);cursor:pointer}
.gdhome .idmode button[aria-pressed="true"]{background:var(--brand);color:#fff}
.gdhome .idmode button:not([aria-pressed="true"]):hover{background:var(--panel-2)}
