@import url('/mis-entradas-flow.css');

/* ─── Tokens ─────────────────────────────────────────────────────────────── */
:root {
    --me-purple: #3d15ce;
    --me-purple-light: #9046ea;
    --me-gradient: linear-gradient(135deg, #3d15ce 0%, #9046ea 100%);
    --me-bg: #f4f4f5;
    --me-card: #ffffff;
    --me-border: #e4e4e7;
    --me-muted: #71717a;
    --me-text: #18181b;
    --me-radius: 16px;
}

[hidden] { display: none !important; }

/* ─── Layout ─────────────────────────────────────────────────────────────── */
.me-main {
    background: var(--me-bg);
    min-height: calc(100vh - 76px);
}

/* ─── Login view ─────────────────────────────────────────────────────────── */
.me-login-view {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: calc(100vh - 76px);
    padding: 40px 16px 64px;
}

.me-login-box {
    background: var(--me-card);
    border: 1px solid var(--me-border);
    border-radius: var(--me-radius);
    padding: 40px 36px 36px;
    width: 100%;
    max-width: 440px;
}

.me-login-icon {
    width: 52px;
    height: 52px;
    background: var(--me-gradient);
    border-radius: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    margin-bottom: 20px;
}

.me-login-title {
    font-family: var(--font-roobert);
    font-size: 26px;
    font-weight: 700;
    color: var(--me-text);
    margin: 0 0 8px;
    line-height: 1.2;
}

.me-login-subtitle {
    font-size: 15px;
    color: var(--me-muted);
    margin: 0 0 28px;
    line-height: 1.5;
}

.me-form-step {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.me-field-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.me-label {
    font-size: 13px;
    font-weight: 600;
    color: #374151;
    letter-spacing: 0.01em;
}

.me-input {
    font-family: var(--font-roobert);
    font-size: 15px;
    color: var(--me-text);
    background: #ffffff;
    border: 1.5px solid #d1d5db;
    border-radius: 10px;
    padding: 11px 14px;
    outline: none;
    transition: border-color 0.18s ease, box-shadow 0.18s ease;
    width: 100%;
    box-sizing: border-box;
}

.me-input:focus {
    border-color: #7c3aed;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.12);
}

.me-input--pin {
    font-size: 22px;
    font-weight: 700;
    letter-spacing: 0.18em;
    text-align: center;
}

.me-input--error {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1) !important;
}

.me-field-error {
    font-size: 13px;
    color: #dc2626;
    line-height: 1.4;
}

/* Buttons */
.me-btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    padding: 11px 18px;
    background: var(--me-gradient);
    color: #ffffff;
    font-family: var(--font-roobert);
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    white-space: nowrap;
}

.me-btn-primary:hover {
    opacity: 0.92;
    transform: translateY(-1px);
}

.me-btn-primary:active {
    transform: translateY(0);
}

.me-btn-primary:disabled {
    opacity: 0.55;
    cursor: not-allowed;
    transform: none;
}

.me-btn-secondary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 9px 16px;
    background: #ffffff;
    color: #374151;
    font-family: var(--font-roobert);
    font-size: 13px;
    font-weight: 600;
    border: 1px solid var(--me-border);
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    transition: border-color 0.18s ease, background 0.18s ease;
    white-space: nowrap;
}

.me-btn-secondary:hover {
    border-color: #c4b5fd;
    background: #fafafa;
}

.me-btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 6px 12px;
    background: transparent;
    color: var(--me-purple);
    font-family: var(--font-roobert);
    font-size: 13px;
    font-weight: 600;
    border: 1px solid var(--me-border);
    border-radius: 8px;
    cursor: pointer;
    transition: border-color 0.15s ease, background 0.15s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.me-btn-ghost:hover {
    border-color: #c4b5fd;
    background: #faf5ff;
}

.me-btn--compact {
    padding: 8px 14px;
    font-size: 13px;
    width: auto;
}

.me-btn--danger-text {
    color: #dc2626;
    border-color: #fecaca;
}

.me-btn--danger-text:hover {
    background: #fef2f2;
    border-color: #fca5a5;
    color: #b91c1c;
}

.me-btn--text {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 0;
    background: none;
    border: none;
    color: var(--me-purple);
    font-family: var(--font-roobert);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    transition: color 0.15s ease;
}

.me-btn--text:hover {
    color: #5b21b6;
}

.me-link-btn {
    background: none;
    border: none;
    color: #7c3aed;
    font-family: var(--font-roobert);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    text-decoration: underline;
    transition: color 0.15s ease;
}

.me-link-btn:hover {
    color: #5b21b6;
}

.me-link-btn:disabled {
    color: #9ca3af;
    cursor: not-allowed;
    text-decoration: none;
}

.me-spinner {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.35);
    border-top-color: #ffffff;
    border-radius: 50%;
    animation: me-spin 0.7s linear infinite;
    flex-shrink: 0;
}

@keyframes me-spin {
    to { transform: rotate(360deg); }
}

.me-pin-info {
    font-size: 13px;
    color: var(--me-muted);
    margin: 0;
    line-height: 1.5;
}

.me-pin-info strong {
    color: var(--me-text);
}

.me-resend-row {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.me-resend-text {
    font-size: 13px;
    color: #9ca3af;
}

.me-btn-primary--inline {
    width: auto;
    min-width: 140px;
}

/* ─── Dashboard ──────────────────────────────────────────────────────────── */
.me-dashboard-view {
    padding: 0 0 72px;
}

.me-dashboard-container {
    max-width: 820px;
    margin: 0 auto;
    padding: 28px 20px 0;
}

.me-dashboard-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 20px;
}

.me-dashboard-title {
    font-family: var(--font-roobert);
    font-size: 28px;
    font-weight: 700;
    color: var(--me-text);
    margin: 0;
    letter-spacing: -0.02em;
}

.me-dashboard-email {
    display: none;
}

.me-logout-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 12px;
    background: transparent;
    color: var(--me-muted);
    font-family: var(--font-roobert);
    font-size: 12px;
    font-weight: 600;
    border: 1px solid var(--me-border);
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
    white-space: nowrap;
    flex-shrink: 0;
}

.me-logout-btn:hover {
    background: #fef2f2;
    border-color: #fecaca;
    color: #dc2626;
}

.me-logout-btn svg {
    opacity: 0.7;
}

/* Profile */
.me-profile {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
    padding: 0;
    background: transparent;
    border: none;
}

.me-profile__row {
    display: flex;
    align-items: center;
    flex: 1;
    min-width: 0;
    gap: 12px;
}

.me-logout-btn--profile {
    display: none;
}

.me-profile__main {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex: 1;
}

.me-profile__avatar {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    border-radius: 50%;
    background: linear-gradient(135deg, #ede9fe 0%, #f3e8ff 100%);
    color: #6d28d9;
    font-family: var(--font-roobert);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.02em;
}

.me-profile__info {
    min-width: 0;
    flex: 1;
}

.me-profile__name {
    margin: 0;
    font-family: var(--font-roobert);
    font-size: 16px;
    font-weight: 700;
    color: var(--me-text);
    line-height: 1.25;
    letter-spacing: -0.01em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.me-profile__stats {
    margin: 3px 0 0;
    font-size: 13px;
    color: var(--me-muted);
    line-height: 1.35;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.me-profile__actions {
    display: flex;
    gap: 8px;
    flex-shrink: 0;
}

.me-profile__btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    padding: 6px 12px;
    border-radius: 8px;
    font-family: var(--font-roobert);
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
    white-space: nowrap;
    background: #fff;
    border: 1px solid var(--me-border);
    color: #52525b;
}

.me-profile__btn-icon {
    flex-shrink: 0;
    opacity: 0.85;
}

.me-profile__btn:hover {
    border-color: #d4d4d8;
    background: #fafafa;
}

.me-profile__btn--bank {
    background: #faf5ff;
    border-color: #e9d5ff;
    color: #7c3aed;
}

.me-profile__btn--bank:hover {
    background: #f3e8ff;
    border-color: #d8b4fe;
}

.me-edit-panel {
    background: var(--me-card);
    border: 1px solid var(--me-border);
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 14px;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
    gap: 12px;
}

.me-edit-panel .me-field-error {
    grid-column: 1 / -1;
}

.me-edit-panel__actions {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    flex-wrap: wrap;
}

.me-bank-form {
    grid-template-columns: repeat(2, minmax(0, 1fr));
}

.me-bank-form .me-field-group:nth-child(5) {
    grid-column: 1 / -1;
}

/* Segmented control (Entradas / Mesas) */
.me-segment {
    display: flex;
    gap: 2px;
    margin-bottom: 12px;
    padding: 3px;
    background: #ececef;
    border-radius: 10px;
}

.me-segment__btn {
    flex: 1;
    padding: 6px 10px;
    background: transparent;
    border: none;
    border-radius: 8px;
    color: #71717a;
    font-family: var(--font-roobert);
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, box-shadow 0.15s ease;
}

.me-segment__btn:hover {
    color: var(--me-text);
}

.me-segment__btn--active {
    background: #fff;
    color: var(--me-text);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
}

/* Filters */
.me-filters {
    display: flex;
    justify-content: flex-start;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 14px;
    padding: 0;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}

.me-filters::-webkit-scrollbar {
    display: none;
}

.me-filter {
    flex: 0 0 auto;
    padding: 6px 12px;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 999px;
    color: #71717a;
    font-family: var(--font-roobert);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease;
    white-space: nowrap;
}

.me-filter:hover {
    color: var(--me-text);
    background: rgba(255, 255, 255, 0.6);
}

.me-filter--active {
    background: #fff;
    border-color: #e4e4e7;
    color: var(--me-text);
    font-weight: 600;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

/* Search */
.me-search-wrap {
    margin-bottom: 14px;
}

.me-search {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    padding: 10px 14px;
    background: #fff;
    border: 1px solid var(--me-border);
    border-radius: 12px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.me-search:focus-within {
    border-color: #c4b5fd;
    box-shadow: 0 0 0 3px rgba(124, 58, 237, 0.08);
}

.me-search__icon {
    display: flex;
    color: #a1a1aa;
    flex-shrink: 0;
}

.me-search__input {
    flex: 1;
    min-width: 0;
    border: none;
    background: transparent;
    font-family: var(--font-roobert);
    font-size: 14px;
    color: var(--me-text);
    outline: none;
    padding: 0;
}

.me-search__input::placeholder {
    color: #a1a1aa;
}

/* Skeleton */
.me-orders-loading {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.me-skeleton-card {
    background: var(--me-card);
    border: 1px solid var(--me-border);
    border-radius: 14px;
    height: 92px;
    position: relative;
    overflow: hidden;
}

.me-skeleton-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(0,0,0,0.04) 50%, transparent 100%);
    animation: me-shimmer 1.4s ease-in-out infinite;
}

@keyframes me-shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Action cards */
.me-action-cards {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
    margin: 0 0 28px;
}

.me-action-card {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    min-height: 132px;
    padding: 14px 14px 12px;
    border: 1px solid #ececf0;
    border-radius: 14px;
    background: #fff;
    text-decoration: none;
    color: inherit;
    position: relative;
    transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease, background 0.18s ease;
}

.me-action-card:hover {
    border-color: #ddd6fe;
    background: #fefefe;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
    transform: translateY(-1px);
}

.me-action-card__icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    flex-shrink: 0;
    margin-bottom: 12px;
    border-radius: 12px;
    background: #f4f4f5;
    color: #52525b;
}

.me-action-card__icon--sell {
    background: linear-gradient(135deg, #f5f3ff 0%, #ede9fe 100%);
    color: #7c3aed;
}

.me-action-card__body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 3px;
    padding-right: 18px;
}

.me-action-card__title {
    font-family: var(--font-roobert);
    font-size: 14px;
    font-weight: 650;
    color: var(--me-text);
    line-height: 1.25;
    letter-spacing: -0.01em;
}

.me-action-card__desc {
    font-size: 12px;
    color: var(--me-muted);
    line-height: 1.4;
}

.me-action-card__chevron {
    position: absolute;
    top: 14px;
    right: 12px;
    color: #d4d4d8;
    transition: color 0.15s ease, transform 0.15s ease;
}

.me-action-card:hover .me-action-card__chevron {
    color: #a78bfa;
    transform: translateX(2px);
}

/* Ticket sections / wallet rows */
.me-tickets-wrap {
    display: flex;
    flex-direction: column;
    gap: 28px;
}

.me-wallet-section__title {
    margin: 0 0 12px;
    font-family: var(--font-roobert);
    font-size: 17px;
    font-weight: 700;
    color: var(--me-text);
    letter-spacing: -0.01em;
}

.me-wallet-row.me-vender-row {
    min-height: 88px;
    flex-wrap: nowrap;
    align-items: center;
}

.me-wallet-row__title {
    margin-bottom: 3px;
}

.me-wallet-row__type {
    margin: 0;
    font-size: 13px;
    font-weight: 500;
    color: #52525b;
    line-height: 1.35;
}

.me-wallet-row__type + .me-wallet-row__type {
    margin-top: 1px;
}

.me-wallet-row__date {
    margin: 3px 0 0;
    font-size: 13px;
    font-weight: 400;
    color: #71717a;
    line-height: 1.35;
}

.me-vender-row__body .me-wallet-row__type:first-of-type {
    margin-top: 0;
}

.me-vender-row--past {
    opacity: 0.78;
}

.me-vender-row--sold {
    opacity: 0.72;
    pointer-events: none;
}

.me-vender-row--sold .me-vender-row__thumb img,
.me-vender-row--sold .me-wallet-row__thumb-placeholder {
    filter: grayscale(0.4);
}

.me-vender-row__meta--sub {
    color: #71717a;
    font-weight: 400;
    font-size: 12px;
}

a.me-vender-row__btn {
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    box-sizing: border-box;
    text-align: center;
}

.me-wallet-row__thumb-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d4d4d8;
}

@media (max-width: 480px) {
    .me-wallet-row.me-vender-row {
        gap: 12px;
        padding: 12px 14px;
    }

    .me-wallet-row .me-vender-row__btn,
    .me-wallet-row > a.me-vender-row__btn {
        min-width: 84px;
        padding: 8px 10px;
        font-size: 12px;
    }
}

/* Legacy ticket card (unused) */
.me-ticket-card {
    background: var(--me-card);
    border: 1px solid var(--me-border);
    border-radius: var(--me-radius);
    overflow: hidden;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.me-ticket-card:hover {
    border-color: #d4d4d8;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}

.me-ticket-card--dim {
    opacity: 0.78;
}

.me-ticket-card--sold {
    opacity: 0.72;
    pointer-events: none;
}

.me-ticket-card--sold .me-ticket-card__thumb img,
.me-ticket-card--sold .me-ticket-card__thumb-placeholder {
    filter: grayscale(0.4);
}

.me-ticket-card__sale-details {
    list-style: none;
    margin: 6px 0 0;
    padding: 8px 10px;
    background: #f4f4f5;
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.me-ticket-card__sale-details li {
    font-size: 12px;
    color: #52525b;
    line-height: 1.5;
}

.me-ticket-card__main {
    display: grid;
    grid-template-columns: auto 1fr 118px;
    gap: 10px;
    padding: 11px 12px;
    align-items: center;
}

.me-ticket-card__thumb {
    width: 78px;
    height: 78px;
    flex-shrink: 0;
    border-radius: 9px;
    overflow: hidden;
    background: #f4f4f5;
    align-self: center;
}

.me-ticket-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.me-ticket-card__thumb-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d4d4d8;
}

.me-ticket-card__content {
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1px;
}

.me-ticket-card__title {
    margin: 0;
    font-family: var(--font-roobert);
    font-size: 14px;
    font-weight: 700;
    color: var(--me-text);
    line-height: 1.25;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.me-ticket-card__meta {
    margin: 0;
    font-size: 12px;
    color: #52525b;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.me-ticket-card__inline {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 5px;
    margin: 2px 0 0;
    font-size: 12px;
    line-height: 1.3;
}

.me-ticket-card__inline-qty {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    color: #52525b;
    font-weight: 500;
}

.me-ticket-card__inline-icon {
    flex-shrink: 0;
    color: #a1a1aa;
}

.me-ticket-card__inline-sep {
    color: #d4d4d8;
}

.me-ticket-card__inline-status {
    font-weight: 600;
}

.me-ticket-card__inline-status--active {
    color: #15803d;
}

.me-ticket-card__inline-status--selling {
    color: #7e22ce;
}

.me-ticket-card__inline-status--past {
    color: #71717a;
}

.me-ticket-card__sale-block {
    display: flex;
    gap: 12px;
    margin-top: 4px;
}

.me-ticket-card__sale-item {
    display: flex;
    flex-direction: column;
    gap: 0;
    min-width: 0;
}

.me-ticket-card__sale-label {
    font-size: 10px;
    font-weight: 500;
    color: var(--me-muted);
    line-height: 1.25;
}

.me-ticket-card__sale-value {
    font-size: 12px;
    font-weight: 700;
    color: var(--me-text);
    line-height: 1.25;
}

.me-ticket-card__sale-value--payout {
    color: #7e22ce;
}

.me-ticket-card__actions {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: stretch;
    gap: 5px;
    width: 118px;
    flex-shrink: 0;
    align-self: center;
}

.me-btn--card {
    width: 100%;
    padding: 8px 10px;
    font-size: 12px;
    box-sizing: border-box;
}

.me-btn-ghost {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-roobert);
    font-size: 12px;
    font-weight: 600;
    color: #374151;
    background: #fff;
    border: 1px solid var(--me-border);
    border-radius: 10px;
    cursor: pointer;
    text-decoration: none;
    transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.me-btn-ghost:hover {
    border-color: #d4d4d8;
    background: #fafafa;
}

.me-btn-ghost--danger {
    color: #dc2626;
    border-color: #fecaca;
}

.me-btn-ghost--danger:hover {
    background: #fef2f2;
    border-color: #fca5a5;
    color: #b91c1c;
}

/* Transfer modal */
.me-modal {
    position: fixed;
    inset: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.me-modal__backdrop {
    position: absolute;
    inset: 0;
    background: rgba(17, 24, 39, 0.56);
}

.me-modal__dialog {
    position: relative;
    width: 100%;
    max-width: 480px;
    max-height: calc(100vh - 40px);
    overflow: auto;
    background: #ffffff;
    border-radius: var(--me-radius);
    padding: 24px;
    box-shadow: 0 22px 70px rgba(17, 24, 39, 0.24);
}

.me-modal__header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 10px;
}

.me-modal__eyebrow {
    margin: 0 0 4px;
    font-size: 11px;
    font-weight: 700;
    color: #7c3aed;
    text-transform: uppercase;
    letter-spacing: 0.08em;
}

.me-modal__title {
    margin: 0;
    font-size: 22px;
    line-height: 1.2;
    color: var(--me-text);
}

.me-modal__close {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 8px;
    background: #f3f4f6;
    color: #4b5563;
    cursor: pointer;
}

.me-modal__event {
    margin: 0 0 14px;
    font-size: 14px;
    font-weight: 600;
    color: #374151;
}

.me-transfer-warning {
    padding: 12px 14px;
    margin-bottom: 16px;
    background: #fffbeb;
    border: 1px solid #fde68a;
    border-radius: 10px;
    color: #92400e;
    font-size: 13px;
    line-height: 1.45;
}

.me-transfer-form {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.me-transfer-profile-fields {
    display: flex;
    flex-direction: column;
    gap: 14px;
}

.me-transfer-lookup-message {
    margin: 0;
    padding: 10px 12px;
    border-radius: 8px;
    background: #f3f4f6;
    color: #374151;
    font-size: 13px;
    line-height: 1.4;
}

.me-sell-breakdown {
    display: grid;
    gap: 8px;
    padding: 12px;
    border-radius: 8px;
    background: #f9fafb;
    border: 1px solid var(--me-border);
}

.me-sell-breakdown div {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    color: var(--me-muted);
    font-size: 13px;
}

.me-sell-breakdown strong {
    color: var(--me-text);
}

.me-modal__actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.me-success-banner {
    background: #dcfce7;
    border: 1px solid #86efac;
    border-radius: 10px;
    color: #15803d;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.45;
    padding: 12px 16px;
    margin-bottom: 20px;
    animation: me-fadein 0.25s ease;
}

@keyframes me-fadein {
    from { opacity: 0; transform: translateY(-6px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* Empty / error */
.me-empty-state {
    text-align: center;
    padding: 56px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.me-empty-icon {
    width: 64px;
    height: 64px;
    background: #f4f4f5;
    border-radius: var(--me-radius);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #d4d4d8;
    margin-bottom: 4px;
}

.me-empty-title {
    font-family: var(--font-roobert);
    font-size: 17px;
    font-weight: 600;
    color: #374151;
    margin: 0;
}

.me-empty-desc {
    font-size: 14px;
    color: var(--me-muted);
    margin: 0;
}

.me-error-state {
    text-align: center;
    padding: 48px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.me-error-title {
    font-size: 15px;
    color: var(--me-muted);
    margin: 0;
}

.me-filter-empty {
    text-align: center;
    padding: 32px 16px;
    color: var(--me-muted);
    font-size: 14px;
}

/* ─── Responsive ─────────────────────────────────────────────────────────── */
@media (max-width: 768px) {
    .me-login-box {
        padding: 32px 24px 28px;
    }

    .me-dashboard-container {
        padding: 28px 16px 0;
    }

    .me-dashboard-header {
        margin-bottom: 24px;
    }

    .me-edit-panel,
    .me-bank-form {
        grid-template-columns: 1fr;
    }

    .me-bank-form .me-field-group:nth-child(5) {
        grid-column: auto;
    }

    .me-ticket-card__thumb {
        width: 66px;
        height: 66px;
    }

    .me-ticket-card__main {
        grid-template-columns: auto 1fr;
        gap: 10px;
    }

    .me-ticket-card__actions {
        grid-column: 1 / -1;
        flex-direction: column;
        width: 100%;
        align-self: stretch;
    }

    .me-ticket-card__actions .me-btn-primary,
    .me-ticket-card__actions .me-btn-ghost {
        width: 100%;
    }

    .me-modal {
        align-items: flex-end;
        padding: 12px;
    }

    .me-modal__dialog {
        border-radius: var(--me-radius);
        padding: 20px;
    }
}

/* Global wallet actions (legacy) */
.me-flow-header {
    margin-bottom: 20px;
}

.me-flow-back {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-bottom: 10px;
    font-size: 13px;
    font-weight: 600;
    color: #6b7280;
    text-decoration: none;
    transition: color 0.15s;
}

.me-flow-back:hover {
    color: #6d28d9;
}

.me-flow-content {
    display: flex;
    flex-direction: column;
    gap: 24px;
}

.me-flow-section__title {
    margin: 0 0 10px;
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: #3f3f46;
}

.me-flow-section__list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.me-flow-card {
    border: 1px solid var(--me-border, #e4e4e7);
    border-radius: 12px;
    background: #fff;
    overflow: hidden;
}

.me-flow-card--disabled {
    opacity: 0.88;
}

.me-flow-card__main {
    display: grid;
    grid-template-columns: 78px 1fr;
    gap: 12px;
    padding: 12px 14px 10px;
}

.me-flow-card__thumb {
    width: 78px;
    height: 78px;
    border-radius: 10px;
    overflow: hidden;
    background: #f4f4f5;
    flex-shrink: 0;
}

.me-flow-card__thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.me-flow-card__title {
    margin: 0 0 4px;
    font-size: 15px;
    font-weight: 650;
    line-height: 1.25;
    color: #18181b;
}

.me-flow-card__meta {
    margin: 0 0 4px;
    font-size: 12px;
    color: #71717a;
    line-height: 1.35;
}

.me-flow-card__note {
    margin: 4px 0 0;
    font-size: 12px;
    color: #a16207;
}

.me-flow-card__amount {
    margin: 6px 0 0;
    font-size: 12px;
    color: #52525b;
}

.me-flow-card__amount strong {
    color: #18181b;
    font-weight: 650;
}

.me-flow-card__reason {
    margin: 6px 0 0;
    font-size: 12px;
    color: #71717a;
    line-height: 1.4;
}

.me-flow-card__reason-label {
    color: #52525b;
    font-weight: 600;
}

.me-flow-card__footer {
    padding: 0 14px 12px;
}

.me-flow-card__footer .me-btn-primary,
.me-flow-card__footer .me-btn-ghost {
    width: 100%;
}

.me-flow-card__actions-row {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.me-flow-card--listed {
    border-color: #ddd6fe;
    background: linear-gradient(180deg, #faf5ff 0%, #fff 48%);
}

.me-listing-details {
    display: grid;
    gap: 6px;
    margin: 10px 0 0;
    padding: 10px 12px;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid #ede9fe;
}

.me-listing-details__row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 12px;
    font-size: 12px;
    line-height: 1.35;
}

.me-listing-details__row dt {
    margin: 0;
    color: #71717a;
    font-weight: 500;
}

.me-listing-details__row dd {
    margin: 0;
    color: #18181b;
    font-weight: 650;
    text-align: right;
}

.me-listing-details__row--highlight dt,
.me-listing-details__row--highlight dd {
    color: #6d28d9;
}

.me-listing-details__row--highlight dd {
    font-size: 13px;
}

@media (max-width: 640px) {
    .me-dashboard-header {
        margin-bottom: 16px;
    }

    .me-logout-btn--header {
        display: none;
    }

    .me-logout-btn--profile {
        display: inline-flex;
        flex-shrink: 0;
        padding: 8px;
        margin-left: 4px;
    }

    .me-profile {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        margin-bottom: 14px;
    }

    .me-profile__row {
        width: 100%;
        gap: 10px;
    }

    .me-profile__avatar {
        width: 40px;
        height: 40px;
        font-size: 13px;
    }

    .me-profile__name {
        font-size: 17px;
        font-weight: 800;
        letter-spacing: -0.02em;
    }

    .me-profile__stats {
        font-size: 12px;
        margin-top: 2px;
    }

    .me-profile__actions {
        width: 100%;
        gap: 8px;
    }

    .me-profile__btn {
        flex: 1;
        min-width: 0;
        min-height: 36px;
        padding: 8px 10px;
        font-size: 11px;
        gap: 5px;
    }

    .me-profile__btn-icon {
        width: 14px;
        height: 14px;
    }

    .me-filters {
        gap: 5px;
    }

    .me-filter {
        padding: 5px 11px;
        font-size: 12px;
    }

    .me-action-cards {
        grid-template-columns: 1fr;
    }

    .me-action-card {
        min-height: 0;
        flex-direction: row;
        align-items: center;
        gap: 12px;
        padding: 14px 16px;
    }

    .me-action-card__icon {
        margin-bottom: 0;
    }

    .me-action-card__body {
        padding-right: 20px;
    }

    .me-action-card__desc--single {
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .me-action-card__chevron {
        top: 50%;
        transform: translateY(-50%);
    }

    .me-action-card:hover .me-action-card__chevron {
        transform: translateY(-50%) translateX(2px);
    }
}

@media (max-width: 480px) {
    .me-login-view {
        align-items: flex-start;
        padding-top: 32px;
    }

    .me-login-box {
        padding: 28px 20px 24px;
    }

    .me-login-title {
        font-size: 22px;
    }

    .me-dashboard-title {
        font-size: 22px;
    }

    .me-logout-btn span.me-logout-label {
        display: none;
    }

    .me-edit-panel__actions .me-btn-secondary,
    .me-edit-panel__actions .me-btn-primary,
    .me-modal__actions .me-btn-secondary,
    .me-modal__actions .me-btn-primary {
        width: 100%;
    }
}
