/**
 * E-Ofis Bulut Sistemi - PRO Stilleri
 */

/* Header Butonu */
.eofis-header-btn {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 28px;
  padding: 0 10px;
  margin-right: 8px;
  font-family: inherit;
  font-size: 12px;
  font-weight: 600;
  color: #1e3a8a;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  border-radius: 6px;
  cursor: pointer;
  transition: all 0.15s ease;
  user-select: none;
}

.eofis-header-btn:hover {
  background: #dbeafe;
  border-color: #93c5fd;
  color: #1d4ed8;
}

.eofis-badge-pro {
  display: inline-block;
  padding: 1px 5px;
  font-size: 9px;
  font-weight: 800;
  background: #2563eb;
  color: #ffffff;
  border-radius: 4px;
  letter-spacing: 0.5px;
}

/* Bulut Otomatik Senkronizasyon Rozeti */
.eofis-sync-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  height: 26px;
  padding: 0 10px;
  margin-right: 8px;
  font-size: 11px;
  font-weight: 600;
  color: #065f46;
  background: #ecfdf5;
  border: 1px solid #a7f3d0;
  border-radius: 6px;
  user-select: none;
  animation: eofisFadeIn 0.2s ease-out;
}

.eofis-sync-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #10b981;
  box-shadow: 0 0 0 2px rgba(16, 185, 129, 0.2);
}

.eofis-sync-dot.is-saving {
  background: #f59e0b;
  box-shadow: 0 0 0 2px rgba(245, 158, 11, 0.2);
  animation: eofisPulse 1s infinite alternate;
}

@keyframes eofisPulse {
  from { opacity: 0.4; }
  to { opacity: 1; }
}

@keyframes eofisFadeIn {
  from { opacity: 0; transform: translateY(-2px); }
  to { opacity: 1; transform: translateY(0); }
}

/* Modal Overlay */
.eofis-modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(5px);
  z-index: 100001;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.eofis-modal-overlay.is-open {
  display: flex;
}

/* Onay ve Tanıtım Kartı */
.eofis-consent-card {
  width: 100%;
  max-width: 600px;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  animation: eofisPop 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes eofisPop {
  from { opacity: 0; transform: scale(0.96) translateY(12px); }
  to { opacity: 1; transform: scale(1) translateY(0); }
}

.eofis-consent-header {
  padding: 22px 26px 18px;
  background: linear-gradient(135deg, #1e3a8a 0%, #2563eb 100%);
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.eofis-consent-title-group {
  display: flex;
  align-items: center;
  gap: 12px;
}

.eofis-consent-icon {
  font-size: 26px;
  background: rgba(255, 255, 255, 0.2);
  width: 44px;
  height: 44px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.eofis-consent-title-group h3 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  display: flex;
  align-items: center;
  gap: 8px;
}

.eofis-modal-close {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.8);
  font-size: 24px;
  cursor: pointer;
  line-height: 1;
  padding: 4px;
  transition: color 0.15s;
}

.eofis-modal-close:hover {
  color: #ffffff;
}

.eofis-consent-body {
  padding: 24px 26px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  max-height: 75vh;
  overflow-y: auto;
}

.eofis-feature-highlight {
  background: #f8fafc;
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.eofis-feature-item {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  font-size: 13px;
  color: #334155;
  line-height: 1.45;
}

.eofis-feature-item .bullet {
  font-size: 15px;
  color: #2563eb;
  flex-shrink: 0;
}

/* KVKK & Türkiye Veri Merkezi Uyarısı */
.eofis-server-notice {
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  gap: 12px;
}

.eofis-server-flag {
  font-size: 26px;
  flex-shrink: 0;
}

.eofis-server-text {
  font-size: 12px;
  color: #166534;
  line-height: 1.5;
}

.eofis-server-text strong {
  display: block;
  font-size: 13px;
  color: #14532d;
  margin-bottom: 2px;
}

/* Fiyatlandırma / Ücret Bilgisi */
.eofis-price-box {
  background: #fefce8;
  border: 1px solid #fef08a;
  border-radius: 12px;
  padding: 14px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.eofis-price-badge {
  font-size: 11px;
  font-weight: 700;
  color: #854d0e;
  text-transform: uppercase;
}

.eofis-price-desc {
  font-size: 12px;
  color: #713f12;
  margin-top: 2px;
}

.eofis-price-amount {
  font-size: 22px;
  font-weight: 800;
  color: #854d0e;
  text-align: right;
}

.eofis-price-period {
  font-size: 11px;
  color: #a16207;
}

/* Checkbox */
.eofis-consent-checkbox-wrap {
  background: #f8fafc;
  border: 1.5px solid #cbd5e1;
  border-radius: 10px;
  padding: 12px 14px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  cursor: pointer;
  transition: border-color 0.15s;
}

.eofis-consent-checkbox-wrap:hover {
  border-color: #3b82f6;
}

.eofis-consent-checkbox-wrap input[type="checkbox"] {
  width: 18px;
  height: 18px;
  margin-top: 2px;
  accent-color: #2563eb;
  flex-shrink: 0;
  cursor: pointer;
}

.eofis-consent-checkbox-label {
  font-size: 12px;
  font-weight: 600;
  color: #1e293b;
  line-height: 1.45;
  cursor: pointer;
}

.eofis-consent-footer {
  padding: 16px 26px;
  background: #f8fafc;
  border-top: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Butonlar */
.eofis-btn {
  height: 36px;
  padding: 0 16px;
  font-family: inherit;
  font-size: 13px;
  font-weight: 600;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.15s ease;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid transparent;
}

.eofis-btn-secondary {
  background: #ffffff;
  border-color: #cbd5e1;
  color: #475569;
}

.eofis-btn-secondary:hover {
  background: #f1f5f9;
  color: #1e293b;
}

.eofis-btn-primary {
  background: #2563eb;
  color: #ffffff;
  box-shadow: 0 2px 4px rgba(37, 99, 235, 0.25);
}

.eofis-btn-primary:hover {
  background: #1d4ed8;
}

.eofis-btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  box-shadow: none;
}

/* === E-OFİS EXPLORER MODAL === */
.eofis-explorer-card {
  width: 980px;
  max-width: 96vw;
  height: 640px;
  max-height: 92vh;
  background: #ffffff;
  border-radius: 16px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: eofisPop 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.eofis-explorer-header {
  padding: 14px 22px;
  background: #f8fafc;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.eofis-explorer-title {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 15px;
  font-weight: 700;
  color: #0f172a;
}

.eofis-server-pill {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 8px;
  font-size: 11px;
  font-weight: 600;
  background: #dcfce7;
  color: #15803d;
  border-radius: 6px;
  border: 1px solid #bbf7d0;
}

.eofis-explorer-content {
  display: flex;
  flex: 1;
  overflow: hidden;
}

/* Sol Panel: Müvekkiller */
.eofis-client-sidebar {
  width: 300px;
  background: #f8fafc;
  border-right: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
}

.eofis-client-search-wrap {
  padding: 12px;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.eofis-input {
  width: 100%;
  box-sizing: border-box;
  height: 32px;
  padding: 0 10px;
  font-size: 12px;
  border: 1px solid #cbd5e1;
  border-radius: 6px;
  outline: none;
}

.eofis-input:focus {
  border-color: #2563eb;
}

.eofis-client-list {
  flex: 1;
  overflow-y: auto;
  padding: 8px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.eofis-client-item {
  padding: 10px 12px;
  border-radius: 10px;
  cursor: pointer;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  transition: all 0.12s ease;
}

.eofis-client-item:hover {
  background: #f1f5f9;
  border-color: #cbd5e1;
}

.eofis-client-item.is-selected {
  background: #eff6ff;
  border-color: #93c5fd;
  box-shadow: 0 1px 3px rgba(37, 99, 235, 0.1);
}

.eofis-client-name {
  font-size: 13px;
  font-weight: 700;
  color: #0f172a;
}

.eofis-client-sub {
  font-size: 11px;
  color: #64748b;
  margin-top: 3px;
  display: flex;
  justify-content: space-between;
}

/* Sağ Panel: Dava ve Dosya Klasörleri */
.eofis-main-area {
  flex: 1;
  display: flex;
  flex-direction: column;
  background: #ffffff;
  overflow: hidden;
}

.eofis-main-header {
  padding: 14px 22px;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  background: #ffffff;
}

.eofis-main-header .eofis-btn {
  white-space: nowrap;
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.eofis-client-heading {
  flex: 1 1 auto;
}

.eofis-client-heading h4 {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #0f172a;
}

.eofis-client-heading span {
  font-size: 12px;
  color: #64748b;
  display: block;
}

.eofis-cases-container {
  flex: 1;
  overflow-y: auto;
  padding: 18px 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

/* Dava / Mahkeme Klasör Kutusu */
.eofis-case-card {
  border: 1px solid #e2e8f0;
  border-radius: 12px;
  background: #fafafa;
  overflow: hidden;
}

.eofis-case-header {
  padding: 12px 16px;
  background: #f1f5f9;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.eofis-case-title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  font-weight: 700;
  color: #1e293b;
}

.eofis-case-files {
  padding: 10px 14px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* Dosya Satırı */
.eofis-file-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  transition: all 0.12s ease;
}

.eofis-file-row:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

.eofis-file-info {
  display: flex;
  align-items: center;
  gap: 12px;
}

.eofis-file-icon {
  font-size: 20px;
}

.eofis-file-name {
  font-size: 13px;
  font-weight: 600;
  color: #0f172a;
}

.eofis-file-meta {
  font-size: 11px;
  color: #64748b;
  margin-top: 2px;
}

.eofis-file-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

.eofis-action-btn {
  height: 28px;
  padding: 0 10px;
  font-size: 11px;
  font-weight: 600;
  border-radius: 6px;
  cursor: pointer;
  border: 1px solid #cbd5e1;
  background: #ffffff;
  color: #334155;
  transition: all 0.12s;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  flex-shrink: 0;
}

.eofis-action-btn:hover {
  background: #f1f5f9;
  color: #0f172a;
}

.eofis-action-btn.is-primary {
  background: #2563eb;
  border-color: #2563eb;
  color: #ffffff;
}

.eofis-action-btn.is-primary:hover {
  background: #1d4ed8;
}

/* Sürüm Geçmişi Popover Modalı */
.eofis-version-drawer {
  position: relative;
  width: 520px;
  max-width: 92vw;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.35);
  border: 1px solid #cbd5e1;
  z-index: 100005;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: eofisFadeUp 0.2s ease-out;
}

.eofis-modal-overlay.is-open .eofis-version-drawer,
.eofis-version-drawer.is-open {
  display: flex;
}

.eofis-version-list {
  max-height: 400px;
  overflow-y: auto;
  padding: 14px 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.eofis-live-draft-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 14px;
  background: #f0fdf4;
  border: 1px solid #86efac;
  border-radius: 10px;
}

.eofis-live-draft-info {
  display: flex;
  align-items: center;
  gap: 10px;
}

.eofis-live-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 3px rgba(34, 197, 94, 0.2);
  flex-shrink: 0;
}

.eofis-milestone-create-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #f8fafc;
  border: 1px dashed #cbd5e1;
  border-radius: 10px;
  margin: 2px 0 6px 0;
}

.eofis-version-item {
  padding: 10px 12px;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: space-between;
  transition: all 0.12s ease;
}

.eofis-version-item:hover {
  background: #f8fafc;
  border-color: #cbd5e1;
}

/* Buluta Kaydet Modalı (Dosya > Buluta Kaydet) */
.eofis-save-modal-card {
  width: 100%;
  max-width: 520px;
  background: #ffffff;
  border-radius: 14px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  animation: eofisPop 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.eofis-form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin-bottom: 14px;
}

.eofis-form-group label {
  font-size: 12px;
  font-weight: 600;
  color: #334155;
}

.eofis-detected-box {
  padding: 8px 12px;
  border-radius: 6px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  font-size: 11px;
  color: #1e40af;
  margin-top: 4px;
}


/* Tehlikeli İşlem Butonu (Sil) */
.eofis-action-btn.is-danger {
  color: #dc2626 !important;
  border-color: #fecaca !important;
  background: #fef2f2 !important;
}
.eofis-action-btn.is-danger:hover {
  background: #fee2e2 !important;
  border-color: #fca5a5 !important;
  color: #b91c1c !important;
}

/* Belge Önizleme Modalı (UDF, PDF, JPEG, TIFF) - Geniş & Tamamen Responsive */
.eofis-preview-drawer {
  width: 96vw;
  max-width: 1440px;
  height: 94vh;
  max-height: 96vh;
  background: #ffffff;
  border-radius: 12px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.45);
  border: 1px solid #cbd5e1;
  z-index: 100020;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  animation: eofisFadeUp 0.2s ease-out;
  transition: width 0.2s ease, height 0.2s ease, max-width 0.2s ease;
}

.eofis-preview-drawer.is-fullscreen {
  width: 100vw !important;
  max-width: 100vw !important;
  height: 100vh !important;
  max-height: 100vh !important;
  border-radius: 0 !important;
  border: none !important;
}

@media (max-width: 1024px) {
  .eofis-preview-drawer {
    width: 98vw;
    height: 96vh;
    border-radius: 8px;
  }
}

.eofis-modal-overlay.is-open .eofis-preview-drawer {
  display: flex;
}

.eofis-preview-content {
  flex: 1;
  background: #334155;
  overflow: hidden;
  padding: 0;
  display: flex;
  flex-direction: column;
}

.eofis-file-name:hover {
  color: #1d4ed8;
  text-decoration: underline;
}
