/* ═══════════════════════════════════════════════════════════════════
   BOYKAP E-POSTA STÜDYO - Premium Koyu Tema CSS
   GrapesJS Studio benzeri üç sütunlu editör arayüzü stilleri.
   ═══════════════════════════════════════════════════════════════════ */

/* ── Ana Kabuk ── */
.eposta-studyo-kabuk {
    display: flex;
    height: 100vh;
    width: 100%;
    background: #0f0f12;
    color: #e2e8f0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    overflow: hidden;
    position: relative;
}

/* ── Sol Navigasyon İkon Çubuğu ── */
.eposta-nav-cubugu {
    width: 48px;
    min-width: 48px;
    background: #18181b;
    border-right: 1px solid #27272a;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding-top: 8px;
    gap: 4px;
    z-index: 20;
}

.eposta-nav-oge {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    cursor: pointer;
    color: #71717a;
    font-size: 16px;
    transition: all 0.2s ease;
    position: relative;
}

.eposta-nav-oge:hover {
    background: #27272a;
    color: #a78bfa;
}

.eposta-nav-oge.aktif {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #ffffff;
    box-shadow: 0 2px 12px rgba(99, 102, 241, 0.35);
}

/* ── Sol Çekmece Panel ── */
.eposta-cekmece {
    width: 0;
    min-width: 0;
    background: #1c1c22;
    border-right: 1px solid #27272a;
    overflow: hidden;
    transition: width 0.25s ease, min-width 0.25s ease;
    z-index: 15;
    display: flex;
    flex-direction: column;
}

.eposta-cekmece.aktif {
    width: 280px;
    min-width: 280px;
}

.eposta-cekmece-baslik {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border-bottom: 1px solid #27272a;
    font-size: 12px;
    font-weight: 700;
    letter-spacing: 1.5px;
    color: #a1a1aa;
}

.eposta-cekmece-kapat {
    background: none;
    border: none;
    color: #71717a;
    cursor: pointer;
    font-size: 14px;
    padding: 4px;
    border-radius: 4px;
    transition: all 0.15s;
}

.eposta-cekmece-kapat:hover {
    background: #27272a;
    color: #ef4444;
}

.eposta-cekmece-icerik {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
}

/* Çekmece İçi Scrollbar */
.eposta-cekmece-icerik::-webkit-scrollbar {
    width: 4px;
}
.eposta-cekmece-icerik::-webkit-scrollbar-track {
    background: transparent;
}
.eposta-cekmece-icerik::-webkit-scrollbar-thumb {
    background: #3f3f46;
    border-radius: 4px;
}

/* ── Ana Çalışma Alanı ── */
.eposta-ana-alan {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    background: #141418;
}

/* ── Üst Araç Çubuğu ── */
.eposta-ust-cubuk {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 16px;
    height: 48px;
    min-height: 48px;
    background: #18181b;
    border-bottom: 1px solid #27272a;
    z-index: 10;
}

.eposta-cihaz-secici select {
    background: #27272a;
    color: #e2e8f0;
    border: 1px solid #3f3f46;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 13px;
    font-family: inherit;
    cursor: pointer;
    outline: none;
    transition: border-color 0.15s;
}

.eposta-cihaz-secici select:hover {
    border-color: #6366f1;
}

.eposta-ust-aksiyonlar {
    display: flex;
    align-items: center;
    gap: 4px;
}

.eposta-aksiyon-btn {
    background: transparent;
    border: none;
    color: #a1a1aa;
    cursor: pointer;
    padding: 8px 10px;
    border-radius: 6px;
    font-size: 14px;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.eposta-aksiyon-btn:hover {
    background: #27272a;
    color: #e2e8f0;
}

.eposta-aksiyon-btn.eposta-kaydet-btn {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #ffffff;
    font-weight: 600;
    font-size: 13px;
    padding: 8px 18px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

.eposta-aksiyon-btn.eposta-kaydet-btn:hover {
    box-shadow: 0 4px 16px rgba(99, 102, 241, 0.5);
    transform: translateY(-1px);
}

.eposta-ust-ayirici {
    width: 1px;
    height: 24px;
    background: #27272a;
    margin: 0 4px;
}

/* ── Tuval Alanı ── */
.eposta-tuval-alani {
    flex: 1;
    overflow: hidden;
    position: relative;
    background: #1a1a20;
}

.eposta-tuval-alani .gjs-cv-canvas {
    background: #e2e8f0 !important;
}

/* ── Sağ Panel ── */
.eposta-sag-panel {
    width: 280px;
    min-width: 280px;
    background: #1c1c22;
    border-left: 1px solid #27272a;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.eposta-sag-sekmeler {
    display: flex;
    border-bottom: 1px solid #27272a;
}

.eposta-sekme-btn {
    flex: 1;
    padding: 12px 0;
    background: transparent;
    border: none;
    color: #71717a;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.15s;
    font-family: inherit;
}

.eposta-sekme-btn:hover {
    color: #a78bfa;
}

.eposta-sekme-btn.aktif {
    color: #a78bfa;
    border-bottom-color: #6366f1;
}

.eposta-sag-icerik {
    flex: 1;
    overflow-y: auto;
    padding: 8px;
}

.eposta-sag-icerik::-webkit-scrollbar {
    width: 4px;
}
.eposta-sag-icerik::-webkit-scrollbar-thumb {
    background: #3f3f46;
    border-radius: 4px;
}

/* ── GrapesJS Block Manager Özelleştirmesi ── */
.eposta-cekmece-icerik .gjs-blocks-c {
    display: grid !important;
    grid-template-columns: 1fr 1fr;
    gap: 6px;
}

.eposta-cekmece-icerik .gjs-block {
    background: #27272a !important;
    border: 1px solid #3f3f46 !important;
    border-radius: 8px !important;
    color: #e2e8f0 !important;
    padding: 12px 8px !important;
    min-height: 60px !important;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    cursor: grab !important;
    transition: all 0.2s ease !important;
    font-size: 11px !important;
    text-align: center !important;
}

.eposta-cekmece-icerik .gjs-block:hover {
    border-color: #6366f1 !important;
    background: #2d2d35 !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.2) !important;
}

.eposta-cekmece-icerik .gjs-block svg {
    fill: #a78bfa !important;
}

.eposta-cekmece-icerik .gjs-block-label {
    font-size: 11px !important;
    margin-top: 4px !important;
    color: #a1a1aa !important;
}

/* Blok kategorisi başlıkları */
.eposta-cekmece-icerik .gjs-block-category .gjs-title {
    background: #22222a !important;
    border: none !important;
    color: #a1a1aa !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    letter-spacing: 1px !important;
    padding: 10px 12px !important;
    text-transform: uppercase !important;
}

/* ── GrapesJS Stil Yöneticisi Özelleştirmesi ── */
.eposta-sag-icerik .gjs-sm-sector .gjs-sm-sector-title {
    background: #22222a !important;
    border: none !important;
    color: #a1a1aa !important;
    font-size: 11px !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px !important;
    padding: 10px 12px !important;
}

.eposta-sag-icerik .gjs-field {
    background: #27272a !important;
    border: 1px solid #3f3f46 !important;
    border-radius: 6px !important;
    color: #e2e8f0 !important;
}

.eposta-sag-icerik .gjs-field input,
.eposta-sag-icerik .gjs-field select {
    color: #e2e8f0 !important;
    background: transparent !important;
}

.eposta-sag-icerik label {
    color: #a1a1aa !important;
    font-size: 11px !important;
}

/* ── Görseller Paneli ── */
.eposta-asset-listesi {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
    padding: 4px;
}

.eposta-asset-oge {
    background: #27272a;
    border: 1px solid #3f3f46;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.2s;
}

.eposta-asset-oge:hover {
    border-color: #6366f1;
    transform: scale(1.02);
}

.eposta-asset-oge img {
    width: 100%;
    height: 80px;
    object-fit: cover;
    display: block;
}

.eposta-asset-oge span {
    display: block;
    padding: 6px;
    font-size: 10px;
    color: #a1a1aa;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ── Ayar Paneli ── */
.eposta-ayar-paneli {
    padding: 8px;
}

.eposta-ayar-grup {
    margin-bottom: 16px;
}

.eposta-ayar-grup label {
    display: block;
    font-size: 12px;
    color: #a1a1aa;
    margin-bottom: 6px;
    font-weight: 600;
}

.eposta-ayar-grup input[type="color"] {
    width: 100%;
    height: 36px;
    border: 1px solid #3f3f46;
    border-radius: 6px;
    background: #27272a;
    cursor: pointer;
    padding: 2px;
}

.eposta-ayar-grup select {
    width: 100%;
    padding: 8px 12px;
    background: #27272a;
    border: 1px solid #3f3f46;
    border-radius: 6px;
    color: #e2e8f0;
    font-size: 13px;
    outline: none;
}

/* ── Boş Mesajı ── */
.eposta-bos-mesaj {
    text-align: center;
    color: #52525b;
    font-size: 13px;
    padding: 30px 15px;
}

/* ── GrapesJS iframe içi düzeltmeler ── */
.eposta-tuval-alani .gjs-frame-wrapper {
    background: #e2e8f0 !important;
}

/* ── GrapesJS Modal Özelleştirmesi ── */
.gjs-mdl-dialog {
    background: #1c1c22 !important;
    border: 1px solid #27272a !important;
    border-radius: 12px !important;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5) !important;
}

.gjs-mdl-header {
    background: #18181b !important;
    border-bottom: 1px solid #27272a !important;
    border-radius: 12px 12px 0 0 !important;
    color: #e2e8f0 !important;
}

.gjs-mdl-title {
    color: #e2e8f0 !important;
}

/* ── Editör İçi Seçim ve Hover Efektleri ── */
.eposta-tuval-alani .gjs-selected {
    outline: 2px solid #6366f1 !important;
    outline-offset: -2px;
}

.eposta-tuval-alani .gjs-hovered {
    outline: 1px dashed #a78bfa !important;
}

/* ── Katman Yöneticisi ── */
.eposta-cekmece-icerik .gjs-layer {
    background: #22222a !important;
    border-bottom: 1px solid #27272a !important;
    color: #e2e8f0 !important;
}

.eposta-cekmece-icerik .gjs-layer:hover {
    background: #2d2d35 !important;
}

.eposta-cekmece-icerik .gjs-layer.gjs-selected {
    background: rgba(99, 102, 241, 0.15) !important;
}

/* ── Responsive: Küçük Ekran Desteği ── */
@media (max-width: 1200px) {
    .eposta-cekmece.aktif {
        width: 240px;
        min-width: 240px;
    }
    .eposta-sag-panel {
        width: 240px;
        min-width: 240px;
    }
}

@media (max-width: 900px) {
    .eposta-sag-panel {
        width: 200px;
        min-width: 200px;
    }
}
