/* Ice Pink Theme - WeTalk History */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --bg-primary: #0a0a0a;
    --bg-secondary: #141414;
    --bg-card: #1c1c1c;
    --border-color: #333333;
    --text-primary: #ffffff;
    --text-secondary: #e8e8e8;
    --text-muted: #888888;
    --accent-peach: #ff85a2;
    --accent-peach-light: #ffa8be;
    --accent-peach-dark: #e06080;
    --incoming-color: #5dff5d;
    --outgoing-color: #5db8ff;
    --code-color: #ffcc66;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    min-height: 100vh;
    margin: 0;
    padding: 0;
    background: var(--bg-primary);
    color: var(--text-secondary);
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 40px;
}

.page-wrapper {
    width: 100%;
    max-width: 550px;
    padding: 0 15px;
}



/* Header */
.header {
    text-align: center;
    margin-bottom: 30px;
}

.logo {
    font-size: 18px;
    font-weight: 600;
    color: var(--accent-peach);
    margin: 0 0 10px 0;
}

.stats-bar {
    display: flex;
    justify-content: center;
    gap: 12px;
}

.stat {
    font-size: 12px;
    color: var(--text-muted);
    padding: 3px 8px;
    background: var(--bg-secondary);
    border-radius: 4px;
    border: 1px solid var(--border-color);
}

.stat.incoming {
    color: var(--incoming-color);
}

.stat.outgoing {
    color: var(--outgoing-color);
}

/* Search Container */
.search-container {
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
}

.search-bar {
    display: flex;
    width: 100%;
    gap: 10px;
    align-items: center;
    background: var(--bg-secondary);
    padding: 8px;
    border-radius: 8px;
    border: 1px solid var(--border-color);
}

.search-input-wrapper {
    flex: 1;
    display: flex;
}

.search-input {
    width: 100%;
    padding: 0 12px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    border-radius: 6px;
    color: var(--text-secondary);
    font-size: 14px;
    height: 40px;
    font-family: inherit;
    transition: border-color 0.2s;
}

.search-input:focus {
    outline: none;
    border-color: var(--accent-peach);
}

.search-input::placeholder {
    color: var(--text-muted);
    font-size: 14px;
}

.search-btn {
    background: var(--accent-peach);
    color: #ffffff;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s ease;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.search-btn:hover {
    background: var(--accent-peach-light);
}

.stats-summary {
    display: flex;
    justify-content: space-between;
    padding: 10px 15px;
    background: var(--bg-card);
    border-radius: 6px;
    border: 1px solid var(--border-color);
    margin-bottom: 15px;
    font-size: 13px;
    color: var(--text-muted);
    align-items: center;
}

.stats-details {
    display: flex;
    gap: 15px;
}

.stat-item {
    font-weight: 500;
}

.stat-in {
    color: var(--incoming-color);
}

.stat-out {
    color: var(--outgoing-color);
}

.search-btn:disabled {
    background: var(--bg-card);
    color: var(--text-muted);
    cursor: not-allowed;
}

.refresh-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }

    100% {
        transform: rotate(360deg);
    }
}

/* Container */
.container {
    background: var(--bg-secondary);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid var(--accent-peach);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
}



/* Message */
.message {
    background: var(--bg-card);
    padding: 10px 15px;
    border-radius: 6px;
    margin: 8px 0;
    border: 1px solid var(--border-color);
    transition: all 0.2s ease;
}

.message:hover {
    border-color: var(--accent-peach-dark);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.from-to {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
    font-size: 13px;
}

.from,
.to {
    color: var(--text-muted);
}

.from strong,
.to strong {
    color: var(--accent-peach);
    font-weight: 500;
}

.text {
    line-height: 1.6;
    padding: 12px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    color: var(--text-secondary);
    border: 1px solid rgba(255, 255, 255, 0.05);
    word-break: break-word;
    font-size: 14px;
    margin-bottom: 8px;
}

.message-footer {
    margin-top: 8px;
    font-size: 10px;
    color: var(--text-muted);
}

/* Numeric Code Highlight */
.numeric-code {
    color: var(--code-color) !important;
    font-weight: bold;
    background: #1a1a0a !important;
    padding: 2px 5px;
    border-radius: 3px;
    border: 1px solid var(--code-color);
}

/* Loading */
.loading-container {
    text-align: center;
    padding: 20px;
}

.loading-text {
    color: var(--text-muted);
    margin-top: 10px;
    font-size: 13px;
}

@keyframes shimmer {
    0% {
        background-position: -500px 0;
    }

    100% {
        background-position: 500px 0;
    }
}

.skeleton {
    background: linear-gradient(90deg, #1c1c1c 25%, #2a2a2a 50%, #1c1c1c 75%);
    background-size: 500px 100%;
    animation: shimmer 1.5s infinite linear;
    border-radius: 4px;
}

.skeleton-message {
    background: var(--bg-card);
    padding: 12px;
    border-radius: 6px;
    border: 1px solid var(--border-color);
}

.skeleton-header {
    height: 16px;
    width: 150px;
    margin-bottom: 8px;
}

.skeleton-text {
    height: 40px;
    width: 100%;
}

/* Responsive */
@media (max-width: 500px) {
    .search-bar {
        flex-direction: column;
        width: 100%;
    }

    .search-input {
        width: 100%;
    }

    .search-btn {
        width: 100%;
    }

    .from-to {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
}