* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background-color: #f8fafc;
    color: #1e293b;
    padding: 40px 20px;
    line-height: 1.5;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

.page-header {
    margin-bottom: 35px;
}

h1 {
    font-size: 28px;
    font-weight: 800;
    color: #0f172a;
    letter-spacing: -0.025em;
    margin-bottom: 8px;
}

.subtitle {
    font-size: 16px;
    color: #64748b;
}

/* Currency Toggle Component */
.currency-toggle-wrapper {
    display: flex;
    align-items: center;
    gap: 8px;
    background: #ffffff;
    padding: 6px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
}

.currency-label {
    font-size: 12px;
    font-weight: 700;
    color: #64748b;
    text-transform: uppercase;
    padding-left: 6px;
}

.toggle-btn {
    padding: 8px 16px;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s ease;
}

.toggle-btn.active-inr { background-color: #15803d; color: #ffffff; }
.toggle-btn.active-usd { background-color: #2563eb; color: #ffffff; }

.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    background: #ffffff;
    padding: 20px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.05);
    margin-bottom: 30px;
    align-items: flex-end;
}

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

label {
    font-size: 11px;
    font-weight: 700;
    color: #475569;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

select, input[type="text"], input[type="number"] {
    padding: 10px 14px;
    border: 1px solid #cbd5e1;
    border-radius: 8px;
    font-size: 14px;
    color: #334155;
    background-color: #ffffff;
    min-width: 160px;
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

select { cursor: pointer; }
select:focus, input[type="text"]:focus, input[type="number"]:focus {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.15);
}

.export-btn {
    background-color: #f1f5f9;
    color: #334155;
    border: 1px solid #cbd5e1;
    cursor: pointer;
    transition: all 0.2s ease;
}
.export-btn:hover { background-color: #e2e8f0; color: #0f172a; }

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 24px;
}

.card {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    padding: 24px;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.02);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    cursor: pointer;
}
.card:hover {
    transform: translateY(-4px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.05);
}

.card-title {
    font-size: 18px;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: 12px;
}

.tag-container {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 20px;
}

.tag {
    font-size: 11px;
    padding: 4px 8px;
    border-radius: 6px;
    font-weight: 600;
}
.tag-niche { background-color: #f1f5f9; color: #334155; }
.tag-platform { background-color: #e0f2fe; color: #0369a1; }
.tag-tier { background-color: #fef3c7; color: #d97706; }
.tag-format { background-color: #fae8ff; color: #a21caf; }

.cpm-box {
    background-color: #f0fdf4;
    border: 1px solid #dcfce7;
    color: #15803d;
    padding: 12px 16px;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 700;
    margin-bottom: 20px;
    margin-top: auto;
}

.buy-btn {
    background-color: #0f172a;
    color: #ffffff;
    text-decoration: none;
    text-align: center;
    padding: 12px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.2s ease;
}
.buy-btn:hover { background-color: #1e293b; }

.no-results {
    grid-column: 1 / -1;
    text-align: center;
    background: #ffffff;
    border: 1px dashed #cbd5e1;
    border-radius: 12px;
    padding: 50px 20px;
    color: #64748b;
    font-weight: 500;
}

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}
.modal-overlay.active { opacity: 1; pointer-events: auto; }

.modal-content {
    background-color: #ffffff;
    width: 90%;
    max-width: 550px;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
    position: relative;
    transform: scale(0.95);
    transition: transform 0.25s ease;
}
.modal-overlay.active .modal-content { transform: scale(1); }

.close-modal {
    position: absolute;
    top: 20px;
    right: 25px;
    font-size: 28px;
    font-weight: 600;
    color: #94a3b8;
    cursor: pointer;
}

.modal-body {
    margin-top: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.calculator-panel {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 20px;
}
.calculator-panel h3 {
    font-size: 13px;
    text-transform: uppercase;
    color: #1e293b;
    margin-bottom: 12px;
}
.calc-disclaimer-box {
    margin-top: 15px;
    padding: 12px 14px;
    background-color: #f1f5f9; /* Soft Slate background */
    border-left: 4px solid #94a3b8; /* Muted accent border line */
    border-radius: 4px;
    font-size: 11px;
    line-height: 1.4;
    color: #475569; /* Balanced slate text */
    text-align: justify;
}

.calc-disclaimer-box strong {
    color: #1e293b;
    font-weight: 700;
}

.calc-row { display: flex; gap: 15px; flex-wrap: wrap; }
.calc-input-wrapper, .calc-output-wrapper { flex: 1; display: flex; flex-direction: column; gap: 5px; }
.calc-display-box {
    background-color: #ffffff;
    border: 1px solid #cbd5e1;
    padding: 10px 14px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 800;
    color: #2563eb;
    height: 43px;
    display: flex;
    align-items: center;
}
.calc-note { font-size: 11px; color: #64748b; margin-top: 10px; font-style: italic; }

.detail-section h3 {
    font-size: 14px;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 8px;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 4px;
}
.detail-list { list-style: none; display: flex; flex-direction: column; gap: 6px; }
.detail-list li {
    font-size: 15px;
    color: #334155;
    padding: 6px 12px;
    background-color: #f8fafc;
    border-radius: 6px;
    border-left: 3px solid #3b82f6;
}
.modal-footer { margin-top: 30px; display: flex; justify-content: flex-end; }
