/* =========================
   TEMP MAIL BOX (TOP AREA)
   ========================= */

.tempmail-box {
    background: var(--tm-box-bg);
    padding: 20px;
    border-radius: 10px;
    max-width: 520px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
}

.tempmail-input-wrap {
    display: flex;
    gap: 10px;
}

.tempmail-input-wrap input {
    flex: 1;
    padding: 12px;
    font-size: 16px;
    color: var(--tm-box-text);
}

.tm-copy {
    position: relative;
    background: var(--tm-copy-bg);
    border: none;
    padding: 12px 14px;
    border-radius: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tempmail-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.tempmail-actions button {
    flex: 1;
    padding: 10px;
    color: #fff;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

.tempmail-actions button:nth-child(1) { background: var(--tm-btn-refresh); }
.tempmail-actions button:nth-child(2) { background: var(--tm-btn-change); }
.tempmail-actions button:nth-child(3) { background: var(--tm-btn-delete); }

.tempmail-box .dashicons {
    font-size: 18px;
}

.tm-copy .dashicons { color: var(--tm-icon-copy); }
.tempmail-actions button:nth-child(1) .dashicons { color: var(--tm-icon-refresh); }
.tempmail-actions button:nth-child(2) .dashicons { color: var(--tm-icon-change); }
.tempmail-actions button:nth-child(3) .dashicons { color: var(--tm-icon-delete); }

/* =========================
   INBOX CARD
   ========================= */

.tempmail-inbox-wrapper {
    max-width: 900px;
    margin: 40px auto;
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    overflow: hidden;
}

/* =========================
   SHARED GRID (HEADER + ROWS)
   ========================= */

.tempmail-inbox-header,
.tempmail-row {
    display: grid;
    grid-template-columns: 340px 1fr 120px;
    align-items: center;
}

/* =========================
   INBOX HEADER
   ========================= */

.tempmail-inbox-header {
    background: #1e293b;
    color: #ffffff;
    padding: 20px 0;
    font-size: 13px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Ensure Subject header text stays white */
.tempmail-inbox-header .tm-subject-col {
    color: #ffffff;
}

/* Equal padding INSIDE columns */
.tempmail-inbox-header > div {
    padding: 0 20px;
    text-align: center;
}

/* =========================
   INBOX BODY
   ========================= */

#tempmail-inbox {
    background: #ffffff;
    min-height: 260px;
    padding-bottom: 30px;
}

/* =========================
   EMPTY STATE
   ========================= */

.tempmail-empty {
    text-align: center;
    padding: 60px 20px;
}

.tempmail-loader {
    width: 72px;
    height: 72px;
    border: 3px solid #e5e7eb;
    border-top-color: #2563eb;
    border-radius: 50%;
    margin: 0 auto 20px;
    position: relative;
    animation: tm-spin 1.4s linear infinite;
}

.tempmail-loader .dashicons {
    font-size: 28px;
    color: #1833FE;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.tempmail-empty-text strong {
    display: block;
    font-size: 17px;
    font-weight: 600;
    color: #111827;
    margin-bottom: 6px;
}

.tempmail-empty-text span {
    font-size: 14px;
    color: #6b7280;
}

@keyframes tm-spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* =========================
   INBOX ROWS
   ========================= */

.tempmail-row {
    padding: 14px 20px;
    cursor: pointer;
    transition: background 0.15s ease;
}

.tempmail-row:nth-child(odd) {
    background: #f1f5f9;
}

/* =========================
   ROW COLUMNS
   ========================= */

/* Sender */
.tm-sender-col,
.tm-sender {
    display: flex;
    align-items: center;
    justify-content: flex-start;
    gap: 10px;
}

.tm-dot {
    width: 8px;
    height: 8px;
    background: #10b981;
    border-radius: 50%;
}

.tm-sender strong {
    display: block;
    font-size: 14px;
    color: #111827;
}

.tm-sender small {
    font-size: 12px;
    color: #6b7280;
}

/* UNDERLINE SENDER ON HOVER */
.tm-sender:hover strong,
.tm-sender:hover small {
text-decoration: underline;
}

/* Subject */
.tm-subject-col,
.tm-subject {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

/* UNDERLINE SUBJECT ON HOVER */
.tm-subject:hover {
text-decoration: underline;
}

/* View */
.tm-view-col,
.tm-view {
    display: flex;
    align-items: center;
    justify-content: center;
}

.tm-view .dashicons {
    color: #9ca3af;
    font-size: 20px;
}

.tempmail-row:hover .tm-view .dashicons {
    color: #10b981 !important;
}


/* ===============================
   OPEN MAIL VIEW — WRAPPER
   =============================== */

.tempmail-open-mail {
    background: #ffffff;
    border-radius: 14px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    overflow: hidden;
    margin-top: 0px;
    font-family: inherit;
}

/* ===============================
   HEADER BAR
   =============================== */

.tempmail-open-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #1e293b;
    color: #ffffff;
    padding: 14px 20px;
    font-size: 13px;
    font-weight: 600;
}

.tempmail-open-header .tm-back {
    display: flex;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    color: #ffffff;
}

.tempmail-open-header .tm-actions {
    display: flex;
    gap: 18px;
}

.tempmail-open-header .tm-actions button {
    background: none;
    border: none;
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

/* ===============================
   SENDER ROW
   =============================== */

.tempmail-open-sender {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px;
}

.tempmail-open-sender-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.tempmail-avatar {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: #e5e7eb;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    color: #10b981;
}

.tempmail-sender-info strong {
    display: block;
    font-size: 14px;
    color: #111827;
}

.tempmail-sender-info small {
    display: block;
    font-size: 12px;
    color: #6b7280;
}

.tempmail-open-date {
    text-align: right;
    font-size: 12px;
    color: #6b7280;
}

.tempmail-divider {
    height: 1px;
    background: #e5e7eb;
    margin: 0 20px;
}

/* ===============================
   SUBJECT ROW
   =============================== */

.tempmail-open-subject {
    display: flex;
    gap: 10px;
    padding: 14px 20px;
    font-size: 14px;
}

.tempmail-open-subject span {
    color: #6b7280;
}

.tempmail-open-subject strong {
    color: #111827;
}

/* ===============================
   MAIL BODY
   =============================== */

.tempmail-open-body {
    padding: 20px;
    font-size: 14px;
    color: #374151;
    line-height: 1.6;
}

/* ===============================
   COPY BUTTON ADVANCE CSS
   =============================== */

/* Copy button hover — desktop and tablet only */
@media (min-width: 601px) {
    .tm-copy:hover {
        background: #9ca3af !important;
        transition: background 0.2s ease;
    }
}


/* =========================================
   TEMPORARY ADDRESS HEADER
   ========================================= */

.tm-address-header {
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    width: 100% !important;
    gap: 20px;
    margin-bottom: 13px;
    line-height: 1 !important;
    box-sizing: border-box;
}

/* =========================================
   LEFT SIDE — EMAIL ICON + TEXT
   ========================================= */

.tm-address-header-left {
    display: flex !important;
    align-items: center !important;
    justify-content: flex-start !important;
    flex: 1 1 auto !important;
    min-width: 0;
    gap: 8px;
    white-space: nowrap;
}

/* Circular email icon */
.tm-address-icon {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    flex: 0 0 26px !important;
    width: 26px !important;
    height: 26px !important;
    min-width: 26px !important;
    border-radius: 50%;
    margin-left: 3px;

    /* CIRCULAR BACKGROUND COLOR */
    background: #1833FE;
}

/* Email icon */
.tm-address-icon .dashicons {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;

    /* ICON COLOR */
    color: #FFFFFF !important;

    /* ICON SIZE */
    font-size: 14px !important;
    width: 14px !important;
    height: 14px !important;
    line-height: 14px !important;
    transform: translate(-1px, 1px) !important;
}

/* Your Temporary Address */
.tm-address-label {
    display: inline-flex !important;
    align-items: center !important;

    /* TEXT COLOR */
    color: #3F4A5A;

    /* TEXT SIZE */
    font-size: 13px !important;

    /* TEXT WEIGHT */
    font-weight: 600 !important;

    text-transform: uppercase;
    letter-spacing: 0.4px;
    line-height: 1 !important;
    white-space: nowrap;
}

/* =========================================
   RIGHT SIDE — ACTIVE FOR
   ========================================= */

.tm-active-time {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;

    flex: 0 0 auto !important;
    margin-left: auto !important;

    gap: 6px;

    padding: 7px 10px;

    border-radius: 20px;

    /* BADGE BACKGROUND */
    background: #D1F2DC;

    /* SAME TEXT COLOR AS LEFT SIDE */
    color: #15803D !important;

    /* SAME FONT SIZE AS LEFT SIDE */
    font-size: 13px !important;

    /* SAME FONT WEIGHT */
    font-weight: 600 !important;

    line-height: 1 !important;
    white-space: nowrap;
    box-sizing: border-box;
}

/* Green status dot + pulse */
.tm-active-time .dashicons {
    position: relative !important;
    display: inline-block !important;
    flex: 0 0 8px !important;

    width: 8px !important;
    height: 8px !important;
    min-width: 8px !important;

    background: #15813E !important;
    border-radius: 50% !important;

    font-size: 0 !important;
    line-height: 0 !important;
    color: transparent !important;

    animation: tmPing 2s infinite !important;
}

/* Hide the dashicon glyph and your old pulse layers */
.tm-active-time .dashicons::before,
.tm-active-time .dashicons::after {
    content: none !important;
    display: none !important;
}

@keyframes tmPing {
    0%      { box-shadow: 0 0 0 0 rgba(21, 129, 62, 0.5); }
    70%,
    100%    { box-shadow: 0 0 0 7px rgba(21, 129, 62, 0); }
}


/* =========================================
   MOBILE — HIDE ACTIVE TIME BADGE
   ========================================= */

@media (max-width: 600px) {

    .tm-active-time {
        display: none !important;
    }

}

/* =========================================
   Inbox Attachment
   ========================================= */


/* Email attachments section */
.tempmail-attachments {
    position: relative;
    margin-top: 28px;
    padding: 20px 0 0;
    border-top: none;
}

/* Short divider with space at both ends */
.tempmail-attachments::before {
    content: "";
    position: absolute;
    top: 0;
    left: 20px;
    right: 20px;
    height: 1px;
    background: #e5e7eb;
}

/* Heading and paperclip icon */
.tempmail-attachments-header {
    display: flex;
    align-items: center;
    gap: 9px;
    margin: 0 0 16px;
    margin-left: 20px;
    color: #202124;
    font-size: 15px;
}

.tempmail-attachments-header > .dashicons {
    width: 19px;
    height: 19px;
    font-size: 19px;
    color: #64748b;
}

.tempmail-attachments-header strong {
    font-weight: 600;
}

.tempmail-attachments-count {
    color: #8a94a3;
    font-size: 12px;
    font-weight: 400;
}

/* Attachment cards */
.tempmail-attachments-list {
    display: flex;
    flex-wrap: wrap;
    align-items: stretch;
    gap: 12px;
    margin-left: 20px;
    margin-bottom: 20px;
}

.tempmail-attachment-item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: fit-content;
    max-width: 100%;
    min-width: 220px;
    box-sizing: border-box;
    padding: 12px;
    border: 1px solid #e1e5eb;
    border-radius: 13px;
    background: #fff;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.tempmail-attachment-item:hover {
    border-color: #cbd5e1;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.04);
}

/* File-type icon */
.tempmail-attachment-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 42px;
    width: 42px;
    height: 42px;
    border-radius: 10px;
    background: #f1f5f9;
    color: #53657a;
}

.tempmail-attachment-icon .dashicons {
    width: 22px;
    height: 22px;
    font-size: 22px;
}

/* Filename and size */
.tempmail-attachment-info {
    flex: 1 1 auto;
    min-width: 0;
}

.tempmail-attachment-name {
    overflow-wrap: anywhere;
    color: #273449;
    font-size: 13px;
    font-weight: 600;
    line-height: 1.45;
}

.tempmail-attachment-size {
    margin-top: 3px;
    color: #8a94a3;
    font-size: 11px;
    line-height: 1.4;
}

/* Compact icon-only download button */
.tempmail-attachment-download {
    display: flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 34px;
    width: 34px;
    height: 34px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: #f1f5f9;
    color: #64748b;
    text-decoration: none !important;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.tempmail-attachment-download .dashicons {
    width: 18px;
    height: 18px;
    font-size: 18px;
}

.tempmail-attachment-download:hover {
    background: #e2e8f0;
    color: #1e293b;
}

/* Mobile layout */
@media (max-width: 480px) {
    .tempmail-attachments::before {
        left: 12px;
        right: 12px;
    }

    .tempmail-attachment-item {
        width: 100%;
        min-width: 0;
        gap: 10px;
        padding: 10px;
    }
}


