/* ==========================================================================
   My Telenor Answers Today – main stylesheet
   Mobile-first. Brand colour: Telenor-style blue (#19A9F8).
   ========================================================================== */

/* ---------- 1. Design tokens ---------- */
:root {
    --brand: #19a9f8;
    --brand-600: #0a86d3;
    --brand-700: #0072bc;
    --brand-800: #005e9e;
    --brand-50: #e8f6ff;
    --brand-100: #d2edfe;

    --ink: #0b1f33;
    --ink-soft: #2c3e52;
    --muted: #4a5b6e;
    --line: #dbe7f1;
    --bg: #f4f9fd;
    --surface: #ffffff;

    --success: #0f7b55;
    --success-bg: #e9f8f1;
    --warn: #8a5a00;
    --warn-bg: #fff6e0;

    --radius-sm: 10px;
    --radius: 16px;
    --radius-lg: 24px;
    --shadow-sm: 0 1px 2px rgba(11, 31, 51, .06);
    --shadow: 0 10px 30px -12px rgba(0, 94, 158, .25);

    --container: 960px;
    --gutter: 16px;

    --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
}

/* ---------- 2. Base ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

html {
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
    scroll-padding-top: 88px;
}

@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { transition: none !important; animation: none !important; }
}

body {
    margin: 0;
    font-family: var(--font);
    font-size: 1.0625rem;
    line-height: 1.7;
    color: var(--ink-soft);
    background: var(--bg);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
    color: var(--ink);
    line-height: 1.25;
    margin: 0 0 .6em;
    letter-spacing: -.01em;
}

p { margin: 0 0 1em; }

a { color: var(--brand-700); text-underline-offset: 3px; }
a:hover { color: var(--brand-800); }

:focus-visible {
    outline: 3px solid var(--brand);
    outline-offset: 2px;
    border-radius: 4px;
}

img, svg { max-width: 100%; height: auto; }

.container {
    width: 100%;
    max-width: var(--container);
    margin-inline: auto;
    padding-inline: var(--gutter);
}

.sr-only {
    position: absolute;
    width: 1px; height: 1px;
    padding: 0; margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.skip-link {
    position: absolute;
    left: 12px; top: -60px;
    z-index: 100;
    padding: 10px 16px;
    background: var(--ink);
    color: #fff;
    border-radius: var(--radius-sm);
    font-weight: 600;
}
.skip-link:focus { top: 12px; color: #fff; }

/* ---------- 3. Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 46px;
    padding: 10px 22px;
    border: 2px solid transparent;
    border-radius: 999px;
    font: inherit;
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.2;
    text-decoration: none;
    cursor: pointer;
    transition: background-color .2s, color .2s, border-color .2s, transform .2s;
}
.btn:hover { transform: translateY(-1px); }

.btn--primary { background: var(--brand-700); color: #fff; }
.btn--primary:hover { background: var(--brand-800); color: #fff; }

.btn--light { background: #fff; color: var(--brand-800); }
.btn--light:hover { background: var(--brand-50); color: var(--brand-800); }

.btn--outline-light { border-color: rgba(255, 255, 255, .85); color: #fff; }
.btn--outline-light:hover { background: rgba(255, 255, 255, .14); color: #fff; }

.btn--ghost { border-color: var(--brand-100); color: var(--brand-700); background: var(--surface); }
.btn--ghost:hover { border-color: var(--brand); color: var(--brand-800); }

/* ---------- 4. Header ---------- */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(255, 255, 255, .96);
    border-top: 4px solid var(--brand);
    border-bottom: 1px solid var(--line);
    backdrop-filter: saturate(160%) blur(8px);
}

.site-header__inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    min-height: 68px;
    gap: 16px;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: var(--ink);
}
.brand__mark { flex: none; width: 40px; height: 40px; }
.brand__text { display: flex; flex-direction: column; line-height: 1.15; }
.brand__name { font-size: 1.05rem; font-weight: 800; color: var(--ink); }
.brand__tag { font-size: .78rem; font-weight: 600; color: var(--brand-700); }

.nav-toggle {
    display: none;
    width: 46px; height: 46px;
    border: 1px solid var(--line);
    border-radius: 12px;
    background: var(--surface);
    cursor: pointer;
    position: relative;
}
.nav-toggle__bar,
.nav-toggle__bar::before,
.nav-toggle__bar::after {
    position: absolute;
    left: 50%;
    width: 20px; height: 2px;
    margin-left: -10px;
    background: var(--ink);
    border-radius: 2px;
    transition: transform .2s, opacity .2s;
    content: "";
}
.nav-toggle__bar { top: 50%; margin-top: -1px; }
.nav-toggle__bar::before { top: -6px; left: 0; margin-left: 0; }
.nav-toggle__bar::after { top: 6px; left: 0; margin-left: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar::after { transform: translateY(-6px) rotate(-45deg); }

.site-nav ul {
    display: flex;
    gap: 4px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.site-nav a {
    display: block;
    padding: 8px 14px;
    border-radius: 999px;
    color: var(--ink-soft);
    font-size: .95rem;
    font-weight: 600;
    text-decoration: none;
}
.site-nav a:hover { background: var(--brand-50); color: var(--brand-800); }
.site-nav a[aria-current="page"] { background: var(--brand-50); color: var(--brand-800); }

@media (max-width: 767px) {
    .js .nav-toggle { display: block; }

    .js .site-nav {
        position: absolute;
        top: 100%;
        left: 0; right: 0;
        display: none;
        padding: 8px var(--gutter) 16px;
        background: var(--surface);
        border-bottom: 1px solid var(--line);
        box-shadow: var(--shadow);
    }
    .js .site-nav.is-open { display: block; }
    .site-nav ul { flex-direction: column; }
    .site-nav a { padding: 12px 14px; border-radius: var(--radius-sm); }

    .no-js .site-header__inner { flex-wrap: wrap; padding-block: 8px; }
    .no-js .site-nav ul { flex-direction: row; flex-wrap: wrap; }
}

/* ---------- 5. Hero ---------- */
.hero {
    position: relative;
    overflow: hidden;
    color: #fff;
    background: linear-gradient(180deg, var(--brand-600) 0%, var(--brand-700) 100%);
    padding: 44px 0 96px;
}
.hero::before,
.hero::after {
    content: "";
    position: absolute;
    border-radius: 50%;
    background: var(--brand);
    pointer-events: none;
}
.hero::before { width: 420px; height: 420px; top: -210px; right: -120px; opacity: .55; }
.hero::after { width: 220px; height: 220px; bottom: -150px; left: -60px; opacity: .35; }

.hero__inner { position: relative; z-index: 1; }

.hero__badge {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
    padding: 6px 14px;
    border-radius: 999px;
    background: rgba(0, 46, 82, .28);
    font-size: .9rem;
    font-weight: 600;
}
.hero__dot {
    width: 9px; height: 9px;
    border-radius: 50%;
    background: #6ff2b4;
    box-shadow: 0 0 0 4px rgba(111, 242, 180, .25);
}

.hero__title {
    color: #fff;
    font-size: clamp(2rem, 6vw, 3.1rem);
    font-weight: 800;
    margin-bottom: 12px;
}
.hero__lead {
    max-width: 640px;
    font-size: 1.1rem;
    color: #fff;
    margin-bottom: 26px;
}
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }

.hero--compact { padding: 28px 0 84px; }
.hero--compact .hero__title { font-size: clamp(1.7rem, 5vw, 2.4rem); }
.hero--compact .hero__lead { margin-bottom: 0; }

/* Breadcrumbs (inside hero) */
.breadcrumbs ol {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin: 0 0 14px;
    padding: 0;
    list-style: none;
    font-size: .9rem;
}
.breadcrumbs li + li::before { content: "/"; margin-right: 6px; opacity: .7; }
.breadcrumbs a { color: #fff; }
.breadcrumbs [aria-current] { opacity: .9; }

/* ---------- 6. Page layout & cards ---------- */
.page {
    position: relative;
    z-index: 2;
    margin-top: -64px;
    padding-bottom: 56px;
    display: grid;
    gap: 28px;
}
.page > * { min-width: 0; }

.card {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow);
    padding: 22px;
}

@media (min-width: 640px) {
    .card { padding: 32px; }
}

/* ---------- 7. Answers ---------- */
.answers__head {
    margin-bottom: 18px;
    padding-bottom: 14px;
    border-bottom: 2px solid var(--brand-50);
}
.answers__title { font-size: clamp(1.3rem, 3.6vw, 1.65rem); margin: 0; }
.answers__date { color: var(--brand-700); white-space: nowrap; }

.qa-list {
    display: grid;
    gap: 14px;
    margin: 0;
    padding: 0;
    list-style: none;
}

.qa {
    padding: 18px 18px 16px;
    border: 1px solid var(--line);
    border-left: 5px solid var(--brand);
    border-radius: var(--radius);
    background: linear-gradient(180deg, #fff 0%, #fbfdff 100%);
}
.qa__label {
    margin: 0 0 4px;
    font-size: .8rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
    color: var(--brand-700);
}
.qa__question {
    font-size: 1.08rem;
    font-weight: 700;
    margin: 0 0 12px;
}
.qa__answer {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    margin: 0;
    padding: 10px 14px;
    border-radius: var(--radius-sm);
    background: var(--success-bg);
    color: var(--success);
}
.qa__icon { flex: none; width: 20px; height: 20px; margin-top: 3px; color: var(--success); }
.qa__answer-label { font-weight: 600; }
.qa__answer strong { color: #0a5c40; }

.answers__foot {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--line);
}
.answers__updated { margin: 0; font-size: .95rem; color: var(--muted); }

/* Notices */
.notice {
    margin: 0 0 18px;
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    font-size: .98rem;
}
.notice--info { background: var(--brand-50); color: var(--ink); border: 1px solid var(--brand-100); }
.notice--warn { background: var(--warn-bg); color: #5b3b00; border: 1px solid #f3dca4; }

/* Share */
.share { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.share__title { font-size: .92rem; font-weight: 600; color: var(--muted); }
.share__btn {
    display: inline-flex;
    align-items: center;
    min-height: 38px;
    padding: 6px 14px;
    border: 0;
    border-radius: 999px;
    font: inherit;
    font-size: .9rem;
    font-weight: 700;
    color: #fff;
    text-decoration: none;
    cursor: pointer;
}
.share__btn:hover { color: #fff; filter: brightness(.92); }
.share__btn--wa { background: #128c4a; }
.share__btn--fb { background: #1664d9; }
.share__btn--copy { background: var(--ink-soft); }

/* ---------- 8. Recent days / archive ---------- */
.recent__title { font-size: 1.35rem; }
.recent__list {
    display: grid;
    gap: 10px;
    margin: 0 0 18px;
    padding: 0;
    list-style: none;
}
@media (min-width: 640px) {
    .recent__list { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
.recent__link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    min-height: 56px;
    padding: 12px 16px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    color: var(--ink);
    font-weight: 600;
    text-decoration: none;
    transition: border-color .2s, box-shadow .2s;
}
.recent__link:hover { border-color: var(--brand); box-shadow: var(--shadow-sm); color: var(--ink); }
.recent__count {
    flex: none;
    padding: 2px 10px;
    border-radius: 999px;
    background: var(--brand-50);
    color: var(--brand-800);
    font-size: .82rem;
    font-weight: 700;
}

.archive-month__title { font-size: 1.3rem; }
.archive-month .recent__list { margin: 0; }

/* Pager */
.pager { display: grid; gap: 12px; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.pager:empty { display: none; }
.pager__link {
    display: flex;
    flex-direction: column;
    padding: 14px 18px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    text-decoration: none;
}
.pager__link:hover { border-color: var(--brand); }
.pager__link--next { text-align: right; }
.pager__hint { font-size: .85rem; color: var(--muted); }
.pager__date { font-weight: 700; color: var(--brand-700); }

/* ---------- 9. Article content ---------- */
.prose {
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: var(--radius-lg);
    padding: 22px;
}
@media (min-width: 640px) {
    .prose { padding: 36px 40px; }
}
.prose h2 {
    position: relative;
    font-size: clamp(1.35rem, 3.4vw, 1.7rem);
    margin-top: 1.8em;
    padding-bottom: 10px;
}
.prose h2::after {
    content: "";
    position: absolute;
    left: 0; bottom: 0;
    width: 56px; height: 4px;
    border-radius: 4px;
    background: var(--brand);
}
.prose > h2:first-child,
.prose .toc + h2 { margin-top: 0; }
.prose h3 { font-size: 1.15rem; margin-top: 1.5em; color: var(--brand-800); }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin-bottom: .4em; }
.prose--page h2 { margin-top: 1.5em; }
.prose--page > h2:first-child { margin-top: 0; }

/* Table of contents */
.toc {
    margin-bottom: 32px;
    padding: 18px 20px;
    border-radius: var(--radius);
    background: var(--brand-50);
    border: 1px solid var(--brand-100);
}
.toc__title { font-size: 1.05rem; margin-bottom: 8px; }
.toc__title::after { display: none; }
.prose .toc h2 { padding-bottom: 0; }
.toc ol {
    margin: 0;
    padding-left: 1.3em;
    columns: 1;
    column-gap: 32px;
}
@media (min-width: 640px) {
    .toc ol { columns: 2; }
}
.toc li { margin-bottom: 4px; break-inside: avoid; }
.toc a { text-decoration: none; font-weight: 600; }
.toc a:hover { text-decoration: underline; }

/* Numbered steps */
.prose ol.steps { counter-reset: step; list-style: none; padding-left: 0; }
.steps li {
    position: relative;
    counter-increment: step;
    padding: 10px 0 10px 48px;
    margin: 0;
    border-bottom: 1px dashed var(--line);
}
.steps li:last-child { border-bottom: 0; }
.steps li::before {
    content: counter(step);
    position: absolute;
    left: 0; top: 9px;
    display: grid;
    place-items: center;
    width: 32px; height: 32px;
    border-radius: 50%;
    background: var(--brand);
    color: var(--ink);
    font-weight: 800;
    font-size: .95rem;
}

/* Check list */
.prose ul.checklist { list-style: none; padding-left: 0; }
.checklist li { position: relative; padding-left: 32px; }
.checklist li::before {
    content: "";
    position: absolute;
    left: 0; top: .3em;
    width: 20px; height: 20px;
    border-radius: 50%;
    background: var(--brand-50) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M6 12.5l4 4 8-9' fill='none' stroke='%230072bc' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 14px no-repeat;
    border: 1px solid var(--brand-100);
}

/* Tables */
.table-wrap {
    margin: 0 0 1.4em;
    overflow-x: auto;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    -webkit-overflow-scrolling: touch;
}
table {
    width: 100%;
    border-collapse: collapse;
    font-size: .97rem;
}
th, td {
    padding: 12px 16px;
    text-align: left;
    vertical-align: top;
    border-bottom: 1px solid var(--line);
}
thead th {
    background: var(--brand-700);
    color: #fff;
    font-weight: 700;
}
tbody th { color: var(--ink); font-weight: 700; width: 38%; }
.table--wide { min-width: 560px; }
tbody tr:nth-child(even) { background: #f8fbfe; }
tbody tr:last-child th,
tbody tr:last-child td { border-bottom: 0; }

/* ---------- 10. FAQs ---------- */
.faqs h2 { font-size: clamp(1.35rem, 3.4vw, 1.7rem); }
.faq {
    margin-bottom: 12px;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    background: var(--surface);
    overflow: hidden;
}
.faq[open] { border-color: var(--brand-100); box-shadow: var(--shadow-sm); }
.faq__q {
    position: relative;
    padding: 16px 52px 16px 18px;
    font-weight: 700;
    color: var(--ink);
    cursor: pointer;
    list-style: none;
}
.faq__q::-webkit-details-marker { display: none; }
.faq__q::after {
    content: "+";
    position: absolute;
    right: 16px; top: 50%;
    display: grid;
    place-items: center;
    width: 28px; height: 28px;
    margin-top: -14px;
    border-radius: 50%;
    background: var(--brand-50);
    color: var(--brand-800);
    font-size: 1.2rem;
    line-height: 1;
}
.faq[open] .faq__q::after { content: "−"; }
.faq__a { margin: 0; padding: 0 18px 18px; }

/* ---------- 11. Misc ---------- */
.empty-state { text-align: center; }
.empty-state .hero__actions { justify-content: center; margin-bottom: 16px; }
.empty-state__hint { margin: 0; color: var(--muted); }
.contact-email { margin: 8px 0 12px; }
.contact-email .btn { word-break: break-all; }

/* ---------- 12. Footer ---------- */
.site-footer {
    background: var(--ink);
    color: #c8d6e5;
    padding-top: 44px;
    font-size: .95rem;
}
.site-footer a { color: #e6f4fe; text-decoration: none; }
.site-footer a:hover { color: #fff; text-decoration: underline; }
.site-footer__grid {
    display: grid;
    gap: 28px;
    padding-bottom: 32px;
}
@media (min-width: 768px) {
    .site-footer__grid { grid-template-columns: 2fr 1fr 1fr; }
}
.brand--footer .brand__name { color: #fff; }
.brand--footer .brand__tag { color: var(--brand); }
.site-footer__about p { margin-top: 14px; max-width: 380px; }
.site-footer__title {
    margin-bottom: 10px;
    font-size: 1rem;
    color: #fff;
}
.site-footer ul { margin: 0; padding: 0; list-style: none; }
.site-footer li { margin-bottom: 6px; }
.site-footer__bottom {
    padding-block: 18px 24px;
    border-top: 1px solid rgba(255, 255, 255, .12);
    font-size: .85rem;
}
.site-footer__bottom p { margin: 0 0 6px; }
.site-footer__notice { color: #9fb2c6; }
