/*
 * tigray-map-full.css — Full-viewport overrides for the Tigray Interactive Map page
 * Child theme: ashe-pro-child
 * Loaded only on pages using the "Tigray Interactive Map" template (slug: tigray-map).
 *
 * All map component styles (.ti-kyt-*) come from homepage.css, which is NOT
 * loaded on this page. This file provides the same component CSS plus the
 * full-viewport sizing override.
 *
 * Import strategy: rather than duplicating all .ti-kyt-* rules, this file
 * contains only what differs from or extends the homepage context.
 * The shared map component styles are inlined below so this page is
 * self-contained without depending on homepage.css.
 */

/* ── Page layout ──────────────────────────────────── */
/* Lock the full-map page to the viewport — no page scroll.
 * WordPress body class: .page-template-page-tigray-map               */

.page-template-page-tigray-map,
.page-template-page-tigray-map body {
    overflow: hidden;
    height: 100%;
}

.ti-fullmap-page {
    background: #1e1e1e;
    height: 100vh;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.ti-fullmap-header {
    padding: 1rem 1.5rem 0.6rem;
    background: #1e1e1e;
    border-bottom: 1px solid rgba(255,255,255,0.07);
    flex-shrink: 0;
}

.ti-fullmap-title {
    font-family: 'Noto Serif Ethiopic', serif;
    font-size: 1.05rem;
    font-weight: 700;
    color: #eeeeee;
    margin: 0 0 2px;
}

.ti-fullmap-subtitle {
    font-size: 0.78rem;
    color: #888888;
    margin: 0;
}

/* ── Full-viewport map wrapper ────────────────────── */
/* flex:1 + min-height:0 makes the wrap fill exactly the remaining   */
/* height below .ti-fullmap-header, regardless of site header height. */

.ti-fullmap-wrap {
    flex: 1 1 0;
    min-height: 0;
    border-radius: 0;
    overflow: hidden;
}

#ti-kyt-app {
    height: 100%;      /* fills .ti-fullmap-wrap exactly */
    min-height: 320px;
}

/* ── Shared map component styles ─────────────────── */
/* (same as homepage.css .ti-kyt-* block — self-contained for this page) */

/* SVG fills the app container absolutely (iOS Safari safe) */
#ti-kyt-map {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    display: block;
    background: transparent;
}

.ti-kyt-panel {
    position: absolute;
    z-index: 10;
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    background: rgba(38, 38, 38, 0.96);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 10px;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.5);
}

.ti-kyt-info-panel {
    top: 18px;
    right: 18px;
    min-width: 220px;
    max-width: 270px;
    padding: 12px 15px;
    transition: opacity 0.2s;
}

.ti-kyt-eyebrow {
    font-size: 0.68rem;
    text-transform: uppercase;
    letter-spacing: 0.12em;
    color: #666666;
    margin-bottom: 8px;
}

.ti-kyt-woreda-name {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.4;
    color: #eeeeee;
    margin-bottom: 2px;
    font-family: 'Noto Serif Ethiopic', serif;
}

.ti-kyt-woreda-name-en {
    font-size: 0.76rem;
    color: #888888;
    margin-bottom: 8px;
    line-height: 1.3;
}

.ti-kyt-tabia-name {
    font-size: 0.98rem;
    color: #e8c84a;
    line-height: 1.5;
    font-family: 'Noto Serif Ethiopic', serif;
}

.ti-kyt-tabia-name-en {
    font-size: 0.76rem;
    color: #888888;
    margin-top: 2px;
    line-height: 1.3;
}

.ti-kyt-divider {
    margin: 10px 0;
    border: none;
    border-top: 1px solid rgba(255, 255, 255, 0.07);
}

.ti-kyt-hint {
    font-size: 0.76rem;
    color: #666666;
    line-height: 1.45;
}

.ti-kyt-lock-badge {
    display: inline-block;
    margin-top: 8px;
    font-size: 0.70rem;
    background: rgba(224, 120, 64, 0.2);
    color: #e07840;
    border: 1px solid rgba(224, 120, 64, 0.35);
    border-radius: 5px;
    padding: 3px 8px;
}

.ti-kyt-controls-panel {
    bottom: 18px;
    left: 18px;
    padding: 8px 12px;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.ti-kyt-ctrl-btn {
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    color: #aaaaaa;
    border-radius: 6px;
    padding: 5px 11px;
    font-size: 0.78rem;
    cursor: pointer;
    transition: background 0.15s, color 0.15s;
    white-space: nowrap;
}

.ti-kyt-ctrl-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #eeeeee;
}

.ti-kyt-ctrl-btn.active {
    background: rgba(232, 200, 74, 0.15);
    border-color: rgba(232, 200, 74, 0.4);
    color: #e8c84a;
}

.ti-kyt-ctrl-label {
    font-size: 0.76rem;
    color: #666666;
    margin-right: 2px;
}

.ti-kyt-legend-panel {
    bottom: 18px;
    right: 18px;
    padding: 10px 14px;
}

.ti-kyt-legend-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.77rem;
    color: #888888;
    margin-bottom: 6px;
}

.ti-kyt-legend-row:last-child { margin-bottom: 0; }

.ti-kyt-legend-dot {
    width: 13px;
    height: 13px;
    border-radius: 3px;
    flex-shrink: 0;
    border: 1px solid rgba(255,255,255,0.1);
}

#ti-kyt-tooltip {
    position: fixed;    /* fixed = viewport-relative; bypasses any container offset */
    z-index: 9999;
    background: rgba(20, 20, 20, 0.97);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    padding: 8px 12px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.12s;
    font-size: 0.82rem;
    line-height: 1.5;
    max-width: 220px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.7);
}

#ti-kyt-tooltip.visible { opacity: 1; }

.ti-kyt-tt-woreda {
    font-weight: 600;
    color: #eeeeee;
    font-size: 0.86rem;
    font-family: 'Noto Serif Ethiopic', serif;
}

.ti-kyt-tt-tabia {
    color: #e8c84a;
    font-family: 'Noto Serif Ethiopic', serif;
}

.ti-kyt-woreda     { stroke: rgba(255,255,255,0.22); stroke-width: 1.2; vector-effect: non-scaling-stroke; pointer-events: none; }
.ti-kyt-woreda.cat-a { fill: #6f7668; }
.ti-kyt-woreda.cat-b { fill: #7c8475; }

.ti-kyt-tabia {
    fill: #6b6b5a; fill-opacity: 0.26;
    stroke: rgba(255,255,255,0.18); stroke-width: 0.45;
    vector-effect: non-scaling-stroke;
    transition: fill 100ms ease, opacity 100ms ease, fill-opacity 100ms ease;
    cursor: pointer;
}
.ti-kyt-tabia.is-dimmed  { opacity: 0.35; fill-opacity: 0.18; }
.ti-kyt-tabia.is-woreda  { fill: #7a9baa; fill-opacity: 0.78; }
.ti-kyt-tabia.is-hovered { fill: #e8c84a; fill-opacity: 1; stroke: #b89a00; stroke-width: 0.8; }
.ti-kyt-tabia.is-locked  { fill: #e07840; fill-opacity: 1; stroke: #a05010; stroke-width: 0.8; }

.ti-kyt-woreda-boundary { fill: none; stroke: rgba(255,255,255,0.55); stroke-width: 1.8px; vector-effect: non-scaling-stroke; pointer-events: none; }

.ti-kyt-label-layer text { pointer-events: none; paint-order: stroke; stroke-linejoin: round; }

.ti-kyt-woreda-label {
    fill: #111111; font-size: 15px; font-weight: 700;
    font-family: 'Noto Serif Ethiopic', serif;
    text-anchor: middle; dominant-baseline: central; stroke: none;
}

.ti-kyt-tabia-label {
    fill: #ccccbb; font-size: 12px; font-weight: 400;
    font-family: 'Noto Serif Ethiopic', serif;
    text-anchor: middle; dominant-baseline: central;
    stroke: none; stroke-width: 0;
}
.ti-kyt-tabia-label.on-highlight { fill: #e8c84a; stroke: none; }
.ti-kyt-tabia-label.on-locked    { fill: #e07840; stroke: none; }

/* ── Responsive ───────────────────────────────────── */
/* 800px matches homepage breakpoint — covers 768px iPad */

@media (max-width: 800px) {
    .ti-kyt-info-panel {
        top: auto;
        bottom: 80px;
        left: 10px;
        right: 10px;
        max-width: none;
        min-width: 0;
    }
    .ti-kyt-controls-panel { bottom: 10px; left: 10px; right: 10px; }
    .ti-kyt-legend-panel { display: none; }
}
