/* ==========================================================================
   eSIM Travel — public + client inner-page components.
   Shell (topbar, hero, footer, auth, client sidebar/dashboard, checkout) comes
   from the cloned reference design in esim-travel.css; this file styles the
   Bootstrap-based inner pages with the same tokens.
   ========================================================================== */

.min-w-0 { min-width: 0; }

/* --- Buttons (legacy names used across inner pages) ------------------------ */
.btn-brand {
    color: #fff;
    background: linear-gradient(135deg, var(--cyan), var(--blue-2));
    box-shadow: 0 10px 22px rgba(13, 134, 247, 0.2);
    min-height: 44px;
}

.btn-brand:hover,
.btn-brand:focus {
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 14px 28px rgba(13, 134, 247, 0.25);
}

.btn-outline-brand {
    background: #fff;
    border: 1px solid #cdd9e8;
    color: var(--navy);
    min-height: 44px;
}

.btn-outline-brand:hover,
.btn-outline-brand:focus {
    border-color: var(--blue-2);
    background: var(--soft-blue);
    color: var(--blue-2);
}

/* --- Titles ---------------------------------------------------------------- */
/* Block titles: closer to their own content than to what's above */
.block-title {
    margin-top: 32px;
    margin-bottom: 12px;
    font-weight: 850;
    letter-spacing: -0.02em;
    color: var(--navy);
}

.section-eyebrow {
    font-size: 12px;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    font-weight: 850;
    color: var(--blue);
    margin-bottom: 4px;
}

/* --- Cards ----------------------------------------------------------------- */
.stat-card {
    background: #fff;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 16px 20px;
}

a.stat-card { transition: transform 0.15s ease, box-shadow 0.15s ease; }
a.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow); }

/* Destination tiles on listing pages: photo + gradient overlay */
.dest-card {
    position: relative;
    border-radius: var(--radius);
    overflow: hidden;
    min-height: 180px;
    background:
        radial-gradient(circle at 80% 15%, rgba(31, 199, 232, 0.55), transparent 45%),
        linear-gradient(145deg, var(--navy-2), var(--blue));
    color: #fff;
    display: flex;
    align-items: flex-end;
    padding: 0;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.dest-card-media {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: grid;
    place-items: center;
    font-size: 2.5rem;
}

.dest-card-body {
    position: relative;
    z-index: 1;
    width: 100%;
    padding: 16px;
    background: linear-gradient(180deg, transparent, rgba(6, 38, 95, 0.88));
}

.dest-card:hover { color: #fff; transform: translateY(-2px); box-shadow: var(--shadow); }

.package-card { padding: 0 !important; }
.package-card-media {
    width: 100%;
    height: 140px;
    object-fit: cover;
    display: block;
    background: linear-gradient(145deg, var(--navy-2), var(--blue));
}
.package-placeholder {
    display: grid;
    place-items: center;
    font-size: 2rem;
    color: #fff;
}
.package-card-body { padding: 16px 20px; }

/* --- Client dashboard additions -------------------------------------------- */
.usage-line { padding: 8px 0; border-bottom: 1px solid var(--line); }
.usage-line:last-child { border-bottom: 0; }
.usage-line .progress { margin-top: 6px; }

.esim-row { color: inherit; }
.esim-row:hover strong { color: var(--blue-2); }

.esim-thumb-placeholder {
    display: grid;
    place-items: center;
    font-size: 1.5rem;
    background: linear-gradient(145deg, var(--navy-2), var(--blue));
}

.cell-truncate {
    max-width: 240px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* --- Footer additions ------------------------------------------------------ */
.footer-copy {
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    font-size: 13px;
    color: rgba(220, 232, 251, 0.7);
}

/* --- eSIM install page ----------------------------------------------------- */
.install-hero {
    background: linear-gradient(135deg, var(--soft-blue), #fff 70%);
    padding: 24px 0 16px;
}

.qr-frame {
    background: #fff;
    border: 2px solid var(--soft-blue);
    border-radius: var(--radius);
    padding: 12px;
    width: 100%;
    max-width: 260px;
    margin-inline: auto;
    animation: qr-in 0.45s ease-out both;
}

.qr-frame svg { display: block; width: 100%; height: auto; }

@keyframes qr-in {
    from { opacity: 0; transform: scale(0.96); }
    to { opacity: 1; transform: scale(1); }
}

.code-line {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 14px;
    word-break: break-all;
    background: var(--soft);
    border-radius: 10px;
    padding: 8px 12px;
}

.accordion-header.is-open .accordion-button {
    background: var(--soft-blue);
    color: var(--blue-2);
    font-weight: 700;
    box-shadow: inset 4px 0 0 var(--blue-2);
}

/* --- Support conversation -------------------------------------------------- */
.support-message {
    border-radius: var(--radius);
    padding: 12px 16px;
    max-width: 100%;
}

.support-message.from-customer { background: var(--soft); }

.support-message.from-support {
    background: var(--soft-blue);
    border-left: 4px solid var(--blue-2);
}

.support-body { white-space: pre-line; overflow-wrap: anywhere; }

@media (min-width: 768px) {
    .support-message { max-width: 85%; }
    .support-message.from-support { margin-right: auto; }
    .support-message.from-customer { margin-left: auto; }
    .dest-card { min-height: 200px; }
}

@media (max-width: 720px) {
    .esim-row { grid-template-columns: 52px 1fr auto; }
    .esim-row > strong:last-child { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .qr-frame { animation: none; }
    .btn-brand,
    .dest-card,
    a.stat-card { transition: none; }
}
