:root {
    --val-red: #ff4655;
    --val-black: #111111;
    --val-gray: #ece8e1;
    --val-dark-gray: #1f1f1f;
    --val-darker-gray: #141414;
}

body {
    background-color: var(--val-black);
    color: var(--val-gray);
    font-family: 'Oswald', sans-serif;
    margin: 0;
    padding: 20px;
    height: 100vh;
    box-sizing: border-box;
    overflow: hidden;
    /* Prevent body scroll, let panels scroll */
}

/* Layout */
.container {
    height: 100%;
    max-width: 1400px;
    margin: 0 auto;
}

.main-layout {
    display: grid;
    grid-template-columns: 450px 1fr;
    gap: 30px;
    height: 100%;
}

@media (max-width: 900px) {
    .main-layout {
        grid-template-columns: 1fr;
        overflow-y: auto;
    }

    body {
        overflow: auto;
    }
}

/* Columns */
.generator-section {
    background: var(--val-darker-gray);
    padding: 20px;
    border: 1px solid #333;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
}

.history-section {
    background: var(--val-darker-gray);
    border: 1px solid #333;
    display: flex;
    flex-direction: column;
    padding: 20px;
    overflow: hidden;
}

/* Header */
header {
    border-bottom: 2px solid var(--val-red);
    margin-bottom: 20px;
    padding-bottom: 10px;
}

h1 {
    font-size: 2rem;
    margin: 0;
    letter-spacing: 2px;
}

.status-bar {
    font-family: 'Roboto Mono', monospace;
    font-size: 0.8rem;
    color: var(--val-red);
    margin-top: 5px;
    font-weight: bold;
}

/* Inputs & Config */
.config-card {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
    background: #000;
    padding: 15px;
    border: 1px solid #333;
}

.input-box {
    background: #111;
    border: 1px solid #444;
    color: #fff;
    height: 48px;
    padding: 0 15px;
    display: flex;
    /* Ensure content centers vertically if needed, though text input usually blocks */
    align-items: center;
    font-family: 'Roboto Mono', monospace;
    font-size: 1rem;
    width: 100%;
    flex: 1;
    /* Make it fill available space */
    box-sizing: border-box;
}

.input-box:focus {
    border-color: var(--val-red);
    outline: none;
}

.input-box.small {
    width: 80px;
}

/* Cards */
.card {
    background: var(--val-dark-gray);
    padding: 15px;
    margin-bottom: 15px;
    border-left: 4px solid var(--val-gray);
}

h2 {
    font-size: 1rem;
    margin-top: 0;
    color: #888;
    margin-bottom: 10px;
}

/* Fields & Values */
.field-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 8px;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.9rem;
}

.field-row label {
    width: 100px;
    color: #aaa;
}

.value-wrapper {
    display: flex;
    flex: 1;
    gap: 5px;
}

.value-box {
    background: #000;
    height: 48px;
    padding: 0 15px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    /* Keep text aligned right */
    border: 1px solid #333;
    color: #fff;
    flex: 1;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    box-sizing: border-box;
}

/* Buttons & Icons */
.btn-icon {
    background: #333;
    border: 1px solid #444;
    color: #fff;
    cursor: pointer;
    height: 48px;
    width: 48px;
    /* Square */
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
    box-sizing: border-box;
}

.btn-icon:hover {
    background: var(--val-red);
    border-color: var(--val-red);
    transform: rotate(180deg);
}



/* Email & OTP specific */
.email-wrapper,
.otp-wrapper {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.email-box,
.otp-display {
    background: #000;
    color: var(--val-red);
    font-family: 'Roboto Mono', monospace;
    height: 48px;
    padding: 0 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed #444;
    flex: 1;
    font-weight: bold;
    box-sizing: border-box;
}

.otp-display {
    font-size: 2rem;
    letter-spacing: 5px;
    color: #fff;
    border-style: solid;
}

/* Main Buttons */
.btn {
    width: 100%;
    height: 48px;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Oswald', sans-serif;
    font-size: 1.1rem;
    cursor: pointer;
    border: none;
    text-transform: uppercase;
    font-weight: bold;
    letter-spacing: 1px;
    box-sizing: border-box;
}

.btn.primary {
    background: var(--val-red);
    color: #fff;
}

.btn.primary:hover {
    background: #ff6b76;
}

.btn.secondary {
    background: transparent;
    border: 1px solid var(--val-gray);
    color: var(--val-gray);
}

.btn.secondary:hover {
    background: var(--val-gray);
    color: #000;
}

.btn-text {
    background: none;
    border: none;
    color: #666;
    cursor: pointer;
    font-family: 'Oswald', sans-serif;
    text-decoration: underline;
}

.btn-text:hover {
    color: var(--val-red);
}

/* History Section */
.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    border-bottom: 1px solid #333;
    padding-bottom: 10px;
    flex-shrink: 0;
    flex-wrap: wrap;
    gap: 10px;
}

.filter-controls {
    display: flex;
    gap: 5px;
    flex: 1;
    justify-content: center;
}

.filter-btn {
    background: transparent;
    border: 1px solid #444;
    color: #666;
    padding: 4px 10px;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.7rem;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-btn:hover {
    border-color: #666;
    color: #aaa;
}

.filter-btn.active {
    background: var(--val-red);
    border-color: var(--val-red);
    color: #fff;
}

.history-list {
    overflow-y: auto;
    flex: 1;
    padding-right: 5px;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 6px;
}

::-webkit-scrollbar-track {
    background: #111;
}

::-webkit-scrollbar-thumb {
    background: #333;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* History Item */
.history-item {
    background: #1a1a1a;
    border: 1px solid #333;
    padding: 10px;
    padding-top: 30px;
    /* Space for absolute tag */
    margin-bottom: 10px;
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.85rem;
    transition: all 0.2s;
    position: relative;
    /* For absolute positioning of tag */
}

.history-item.inactive {
    opacity: 0.5;
    background: #111;
}

.history-item:hover {
    border-color: #555;
}

.history-details div {
    margin-bottom: 4px;
}

.history-details span {
    color: #888;
    display: inline-block;
    width: 70px;
}

.history-actions {
    display: flex;
    flex-direction: row;
    gap: 4px;
    justify-content: center;
    align-items: center;
}

.status-radio-btn {
    background: transparent;
    border: 1px solid #444;
    color: #666;
    padding: 6px 10px;
    font-family: 'Roboto Mono', monospace;
    font-size: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: bold;
    min-width: 32px;
}

.status-radio-btn:hover {
    border-color: #666;
    color: #aaa;
}

.status-radio-btn.active {
    border-color: var(--val-red);
    color: var(--val-red);
    background: rgba(255, 70, 85, 0.1);
}

.history-tag {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 0.65rem;
    padding: 3px 8px;
    background: #333;
    color: #aaa;
    border-radius: 2px;
    text-align: center;
    font-weight: bold;
    letter-spacing: 0.5px;
}

.history-tag.active {
    color: #4caf50;
    border: 1px solid #4caf50;
    background: rgba(76, 175, 80, 0.1);
}

.history-tag.banned {
    color: var(--val-red);
    border: 1px solid var(--val-red);
    background: rgba(255, 70, 85, 0.1);
}