/* ================================================================
   TypingTips.in — Language Hub Pages Shared Layout
   Color variables (--lh-*) are set per-language in each page.
================================================================ */

/* ── Base ──────────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
    background-color: var(--lh-bg) !important;
    color: var(--lh-text);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
                 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.65;
    transition: background-color .3s, color .3s;
}
/* Nav + footer match page background; force Latin font on nav regardless of html[lang] */
nav  { background-color: var(--lh-bg) !important; }
footer { background-color: var(--lh-bg) !important; }
nav, nav a, nav li, .menu, .menu ul, .menu ul li, .menu ul li a,
.rightsidemenu, .mobile-header {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
                 'Helvetica Neue', Arial, sans-serif !important;
}

/* ── Layout ────────────────────────────────────────────────── */
.lh-section      { padding: 68px 0; }
.lh-section.alt  { background: var(--lh-surface); }
.lh-wrap         { max-width: 1140px; margin: 0 auto; padding: 0 24px; }

.lh-label {
    font-size: .7rem; font-weight: 700; letter-spacing: 2.5px;
    text-transform: uppercase; color: var(--lh-accent); margin-bottom: 8px;
}
.lh-title {
    font-size: clamp(1.7rem, 3.2vw, 2.3rem); font-weight: 800;
    color: var(--lh-text); margin: 0 0 10px; line-height: 1.2;
}
.lh-sub {
    font-size: 1rem; color: var(--lh-muted);
    margin-bottom: 42px; max-width: 540px;
}

/* ── Buttons ───────────────────────────────────────────────── */
.lh-btn {
    display: inline-flex; align-items: center; gap: 8px;
    font-weight: 700; font-size: .95rem;
    padding: 13px 26px; border-radius: 10px;
    text-decoration: none; border: none; cursor: pointer;
    transition: background .2s, transform .15s, box-shadow .2s, color .2s;
    white-space: nowrap;
}
.lh-btn-fill {
    background: var(--lh-accent); color: var(--lh-invert);
}
.lh-btn-fill:hover {
    background: var(--lh-accent-dk); color: var(--lh-invert);
    transform: translateY(-2px); box-shadow: 0 8px 28px var(--lh-glow);
}
.lh-btn-ghost {
    background: transparent; color: var(--lh-text);
    border: 1.5px solid var(--lh-border);
}
.lh-btn-ghost:hover {
    border-color: var(--lh-accent); color: var(--lh-accent);
    background: var(--lh-glow);
}

/* ================================================================
   HERO
================================================================ */
.lh-hero {
    padding: 60px 0 64px; position: relative; overflow: hidden;
}
.lh-hero::before {
    content: ''; position: absolute; top: -100px; right: -180px;
    width: 540px; height: 540px;
    background: radial-gradient(circle, var(--lh-glow) 0%, transparent 68%);
    pointer-events: none;
}
.lh-hero-inner { display: flex; align-items: center; gap: 52px; flex-wrap: wrap; }
.lh-hero-left  { flex: 1 1 360px; }
.lh-hero-right { flex: 1 1 300px; max-width: 400px; }

.lh-badge {
    display: inline-flex; align-items: center; gap: 8px;
    background: var(--lh-glow); border: 1px solid var(--lh-accent);
    color: var(--lh-accent); font-size: .76rem; font-weight: 600;
    padding: 5px 14px; border-radius: 20px; margin-bottom: 20px;
    letter-spacing: .4px;
}
.lh-badge .dot {
    width: 7px; height: 7px; border-radius: 50%;
    background: var(--lh-accent);
    animation: lh-pulse 1.9s ease-in-out infinite;
}
@keyframes lh-pulse {
    0%,100% { opacity:1; transform:scale(1); }
    50%      { opacity:.4; transform:scale(1.6); }
}

.lh-hero-title {
    font-size: clamp(2.2rem, 5.5vw, 3.6rem); font-weight: 900;
    line-height: 1.12; color: var(--lh-text); margin-bottom: 16px;
}
.lh-hero-title .hl { color: var(--lh-accent); }

.lh-hero-desc {
    font-size: 1.05rem; color: var(--lh-muted);
    margin-bottom: 30px; max-width: 480px;
    line-height: 1.7; text-align: left;
}
.lh-cta-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* Stats strip */
.lh-stats {
    display: flex; flex-wrap: wrap; gap: 26px;
    margin-top: 40px; padding-top: 26px;
    border-top: 1px solid var(--lh-border);
}
.lh-stat-num   { font-size: 1.65rem; font-weight: 800; color: var(--lh-accent); line-height: 1; }
.lh-stat-label { font-size: .73rem; color: var(--lh-muted); text-transform: uppercase; letter-spacing: 1px; margin-top: 3px; }

/* Quick test pills */
.lh-quick-stack { display: flex; flex-direction: column; gap: 11px; }
.lh-quick-pill {
    display: flex; align-items: center; gap: 15px;
    background: var(--lh-card); border: 1px solid var(--lh-border);
    border-radius: 13px; padding: 15px 20px; text-decoration: none;
    transition: border-color .2s, transform .18s, box-shadow .2s;
}
.lh-quick-pill:hover {
    border-color: var(--lh-accent);
    transform: translateX(8px);
    box-shadow: 0 4px 22px var(--lh-glow);
}
.lh-qp-icon {
    width: 44px; height: 44px; border-radius: 10px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.2rem; font-weight: 700; flex-shrink: 0;
    background: var(--lh-glow); color: var(--lh-accent);
}
.lh-qp-name { font-weight: 700; font-size: .94rem; color: var(--lh-text); margin: 0; }
.lh-qp-sub  { font-size: .73rem; color: var(--lh-muted); margin: 2px 0 0; }
.lh-qp-arr  { margin-left: auto; color: var(--lh-muted); font-size: .85rem; }

/* ================================================================
   TEST CARDS GRID
================================================================ */
.lh-cards-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 20px;
}
.lh-card {
    background: var(--lh-card); border: 1px solid var(--lh-border);
    border-radius: 16px; padding: 24px;
    display: flex; flex-direction: column;
    transition: border-color .2s, transform .18s, box-shadow .2s;
}
.lh-card:hover {
    border-color: var(--lh-accent); transform: translateY(-4px);
    box-shadow: 0 12px 36px rgba(0,0,0,0.22);
}
.lh-card-top {
    display: flex; align-items: flex-start;
    justify-content: space-between; margin-bottom: 14px;
}
.lh-card-icon {
    width: 48px; height: 48px; border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    font-size: 1.35rem; font-weight: 800;
    background: var(--lh-glow); color: var(--lh-accent);
}
.lh-card-badge {
    font-size: .67rem; font-weight: 700; letter-spacing: .5px;
    padding: 3px 9px; border-radius: 20px;
    background: var(--lh-glow); color: var(--lh-accent);
    border: 1px solid var(--lh-accent);
}
.lh-card h3 {
    font-size: 1.1rem; font-weight: 800; color: var(--lh-text); margin-bottom: 7px;
}
.lh-card > p {
    font-size: .83rem; color: var(--lh-muted);
    margin-bottom: 18px; line-height: 1.55; text-align: left;
}
.lh-chip-row { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 20px; }
.lh-chip {
    font-size: .77rem; font-weight: 600;
    padding: 5px 12px; border-radius: 8px;
    border: 1px solid var(--lh-border); color: var(--lh-text);
    text-decoration: none; white-space: nowrap;
    transition: background .15s, border-color .15s, color .15s;
}
.lh-chip:hover, .lh-chip.featured {
    background: var(--lh-accent); color: var(--lh-invert);
    border-color: var(--lh-accent);
}
.lh-card-foot {
    margin-top: auto; padding-top: 16px;
    border-top: 1px solid var(--lh-border);
}
.lh-card-foot a {
    font-size: .81rem; font-weight: 600; color: var(--lh-accent);
    text-decoration: none; display: inline-flex; align-items: center; gap: 5px;
    transition: gap .15s;
}
.lh-card-foot a:hover { gap: 11px; }

/* ================================================================
   INFO TABLE
================================================================ */
.lh-table-wrap { overflow-x: auto; margin: 0 0 32px; border-radius: 12px; border: 1px solid var(--lh-border); }
.lh-table {
    width: 100%; border-collapse: collapse; font-size: .85rem;
}
.lh-table th {
    background: var(--lh-card); color: var(--lh-accent);
    padding: 12px 16px; text-align: left; font-weight: 700;
    border-bottom: 1px solid var(--lh-border); white-space: nowrap;
}
.lh-table td {
    padding: 11px 16px; border-bottom: 1px solid var(--lh-border);
    color: var(--lh-muted);
}
.lh-table tr:last-child td { border-bottom: none; }
.lh-table tr:hover td { background: var(--lh-glow); color: var(--lh-text); }
.lh-table .td-hl { color: var(--lh-text); font-weight: 600; }

/* ================================================================
   FEATURES
================================================================ */
.lh-feat-grid {
    display: grid; grid-template-columns: repeat(4,1fr); gap: 16px;
}
@media (max-width: 800px) { .lh-feat-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 440px) { .lh-feat-grid { grid-template-columns: 1fr; } }

.lh-feat {
    background: var(--lh-card); border: 1px solid var(--lh-border);
    border-radius: 13px; padding: 20px 18px;
    transition: border-color .2s, transform .18s;
}
.lh-feat:hover { border-color: var(--lh-accent); transform: translateY(-3px); }
.lh-feat-ico {
    width: 42px; height: 42px; border-radius: 10px;
    background: var(--lh-glow); display: flex; align-items: center;
    justify-content: center; font-size: 1.2rem;
    color: var(--lh-accent); margin-bottom: 12px;
}
.lh-feat h4 { font-size: .93rem; font-weight: 700; color: var(--lh-text); margin-bottom: 5px; }
.lh-feat p  { font-size: .8rem; color: var(--lh-muted); line-height: 1.5; text-align: left; }

/* ================================================================
   KEYBOARD LAYOUT PREVIEW
================================================================ */
.lh-layout-grid {
    display: grid; grid-template-columns: 1fr 1fr; gap: 22px;
}
@media (max-width: 640px) { .lh-layout-grid { grid-template-columns: 1fr; } }

.lh-layout-card {
    background: var(--lh-card); border: 1px solid var(--lh-border);
    border-radius: 16px; padding: 24px;
}
.lh-layout-card h3 {
    font-size: 1rem; font-weight: 800; color: var(--lh-text);
    margin-bottom: 14px; display: flex; align-items: center; gap: 10px;
}
.lh-layout-card h3 span {
    width: 30px; height: 30px; border-radius: 7px;
    background: var(--lh-glow); display: inline-flex;
    align-items: center; justify-content: center;
    color: var(--lh-accent); font-size: .85rem;
}
.lh-layout-card p { font-size: .83rem; color: var(--lh-muted); line-height: 1.6; text-align: left; margin-bottom: 14px; }
.lh-layout-card ul {
    list-style: none; padding: 0; margin: 0;
    display: flex; flex-direction: column; gap: 6px;
}
.lh-layout-card ul li {
    font-size: .8rem; color: var(--lh-muted); padding-left: 16px; position: relative;
}
.lh-layout-card ul li::before {
    content: '▸'; position: absolute; left: 0; color: var(--lh-accent);
}

/* ================================================================
   SEO CONTENT
================================================================ */
.lh-seo { max-width: 780px; }
.lh-seo h2 { font-size: 1.4rem; font-weight: 800; color: var(--lh-text); margin-bottom: 12px; }
.lh-seo h3 { font-size: 1.1rem; font-weight: 700; color: var(--lh-text); margin: 22px 0 8px; }
.lh-seo p  { font-size: .9rem; color: var(--lh-muted); line-height: 1.8; margin-bottom: 12px; text-align: left; }
.lh-seo strong { color: var(--lh-text); }

/* ================================================================
   RESPONSIVE
================================================================ */
@media (max-width: 700px) {
    .lh-hero { padding: 56px 0 40px; }
    .lh-hero-inner { flex-direction: column; gap: 32px; }
    .lh-hero-right { max-width: 100%; width: 100%; }
    .lh-section { padding: 46px 0; }
    .lh-cards-grid { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
    .lh-hero-title { font-size: 2rem; }
    .lh-cta-row { flex-direction: column; }
    .lh-btn { width: 100%; justify-content: center; }
}
