/* MCST Quote Plugin - Green + Gold Theme */
:root {
  --mcstq-primary: #2A5066;
  --mcstq-primary-light: #3A6A84;
  --mcstq-accent: #fbd8c5;
  --mcstq-bg: #ffffff;
  --mcstq-bg-light: #f4f6fa;
  --mcstq-text: #1a1a2e;
  --mcstq-text-muted: #6b7280;
  --mcstq-border: #d0d7e2;
  --mcstq-success: #059669;
  --mcstq-error: #dc2626;
}

.mcstq-wrap { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; color: var(--mcstq-text); line-height: 1.6; }

.mcstq-hero {
  background: linear-gradient(135deg, #c5e8fb, #d4efff);
  padding: 60px 20px; text-align: center;
}
.mcstq-hero h1 { font-size: 2.2em; margin: 0 0 10px; color: var(--mcstq-primary); }
.mcstq-hero p { font-size: 1.1em; opacity: 0.9; margin: 0; color: #3a5a70; }

.mcstq-container { max-width: 900px; margin: 0 auto; padding: 30px 20px; }
.mcstq-container h2 { color: var(--mcstq-primary); border-bottom: 2px solid var(--mcstq-accent); padding-bottom: 8px; margin-top: 30px; }

/* Steps */
.mcstq-steps { display: flex; justify-content: center; gap: 20px; margin-bottom: 30px; }
.mcstq-step {
  display: flex; align-items: center; gap: 8px; padding: 8px 16px;
  border-radius: 20px; background: var(--mcstq-bg-light); color: var(--mcstq-text-muted);
  font-size: 0.9em; transition: all 0.3s;
}
.mcstq-step.active { background: var(--mcstq-primary); color: #fff; }
.mcstq-step .step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 24px; height: 24px; border-radius: 50%; background: rgba(255,255,255,0.2);
  font-size: 0.85em; font-weight: bold;
}
.mcstq-step.active .step-num { background: #fbd8c5; color: var(--mcstq-text); }
.mcstq-step-content { display: none; }
.mcstq-step-content.active { display: block; }

/* Grid */
.mcstq-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px; }
.mcstq-field { margin-bottom: 12px; }
.mcstq-field label { display: block; margin-bottom: 4px; font-weight: 600; font-size: 0.9em; color: var(--mcstq-text); }
.mcstq-field input, .mcstq-field select, .mcstq-field textarea {
  width: 100%; padding: 10px 12px; border: 1px solid var(--mcstq-border); border-radius: 6px;
  font-size: 1em; transition: border-color 0.2s; box-sizing: border-box;
}
.mcstq-field input:focus, .mcstq-field select:focus, .mcstq-field textarea:focus {
  outline: none; border-color: var(--mcstq-primary); box-shadow: 0 0 0 3px rgba(42,80,102,0.15);
}
.mcstq-full { grid-column: 1 / -1; }
.mcstq-toggle { display: flex; align-items: center; gap: 10px; cursor: pointer; }
.mcstq-toggle input { width: auto; } .toggle-label { font-weight: 500; }

/* Buttons */
.mcstq-btn {
  display: inline-block; padding: 10px 24px; border: 1px solid var(--mcstq-border); border-radius: 6px;
  background: #fff; color: var(--mcstq-text); font-size: 0.95em; cursor: pointer;
  transition: all 0.2s; text-decoration: none;
}
.mcstq-btn:hover { border-color: var(--mcstq-primary); color: var(--mcstq-primary); }
.mcstq-btn-secondary { background: #6b7280; border-color: #6b7280; color: #fff; }
.mcstq-btn-secondary:hover { background: #4b5563; border-color: #4b5563; color: #fff; }
.mcstq-btn-primary { background: var(--mcstq-primary); border-color: var(--mcstq-primary); color: #fff; }
.mcstq-btn-primary:hover { background: var(--mcstq-primary-light); border-color: var(--mcstq-primary-light); color: #fff; }
.mcstq-btn-sm { padding: 6px 14px; font-size: 0.85em; }
.mcstq-btn-lg { padding: 14px 36px; font-size: 1.1em; }
.mcstq-actions { text-align: center; margin-top: 30px; }

/* Fee Preview Box */
.mcstq-fee-box {
  background: var(--mcstq-bg-light); border: 1px solid var(--mcstq-border); border-radius: 8px;
  padding: 20px; margin: 20px 0;
}
.mcstq-fee-box h3 { color: var(--mcstq-primary); margin: 0 0 15px; }
.mcstq-fee-line { display: flex; justify-content: space-between; padding: 6px 0; border-bottom: 1px solid var(--mcstq-border); font-size: 0.95em; }
.mcstq-fee-line:last-child { border-bottom: none; }
.mcstq-fee-total { display: flex; justify-content: space-between; padding: 10px 0 0; margin-top: 10px; border-top: 2px solid var(--mcstq-accent); font-weight: bold; font-size: 1.1em; color: var(--mcstq-primary); }

/* Success */
.mcstq-success-box { text-align: center; padding: 60px 20px; }
.mcstq-success-box h2 { color: var(--mcstq-success); border: none; }
.mcstq-success-box strong { color: var(--mcstq-primary); font-size: 1.3em; }

/* Admin */
.mcstq-admin-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 10px; }
.mcstq-admin-meta { display: flex; align-items: center; gap: 15px; font-size: 0.9em; color: var(--mcstq-text-muted); }
.mcstq-toolbar { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 15px; margin: 20px 0; padding: 15px; background: var(--mcstq-bg-light); border-radius: 8px; }
.mcstq-search input { padding: 8px 14px; border: 1px solid var(--mcstq-border); border-radius: 6px; width: 250px; font-size: 0.95em; }
.mcstq-filters { display: flex; align-items: center; gap: 15px; font-size: 0.9em; flex-wrap: wrap; }
.mcstq-counts { color: var(--mcstq-text-muted); font-size: 0.85em; }

/* Login Box */
.mcstq-login-box { max-width: 400px; margin: 60px auto; padding: 30px; background: var(--mcstq-bg-light); border-radius: 12px; box-shadow: 0 2px 8px rgba(0,0,0,0.08); }
.mcstq-login-box h2 { text-align: center; margin-top: 0; }

/* Submissions Table */
.mcstq-table { width: 100%; border-collapse: collapse; font-size: 0.9em; }
.mcstq-table th { background: var(--mcstq-primary); color: #fff; padding: 10px 12px; text-align: left; }
.mcstq-table td { padding: 10px 12px; border-bottom: 1px solid var(--mcstq-border); }
.mcstq-table tr:hover td { background: var(--mcstq-bg-light); }
.mcstq-table .actions { display: flex; gap: 6px; flex-wrap: wrap; }
.mcstq-table .badge { display: inline-block; padding: 2px 8px; border-radius: 12px; font-size: 0.85em; background: var(--mcstq-bg-light); color: var(--mcstq-text-muted); }
.mcstq-table .badge-archived { background: #fef3c7; color: #92400e; }
.mcstq-table .badge-assigned { background: #dbeafe; color: #1e40af; }
.mcstq-table .btn-archive { background: #fef2f2; border-color: #fecaca; color: #991b1b; }
.mcstq-table .btn-unarchive { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }

/* Detail View */
.mcstq-detail-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; background: var(--mcstq-bg-light); border-radius: 8px; padding: 20px; margin: 15px 0; }
.mcstq-detail-label { font-weight: 600; color: var(--mcstq-text-muted); font-size: 0.85em; }
.mcstq-detail-value { color: var(--mcstq-text); }

/* Fee Editor */
.mcstq-fee-editor { background: #fff; border: 1px solid var(--mcstq-border); border-radius: 8px; padding: 20px; margin: 15px 0; }
/* Three-column grid keeps every row's label / input / formatted amount aligned
   in vertical columns regardless of label or amount length. */
.mcstq-fee-row {
  display: grid;
  grid-template-columns: minmax(0, 2fr) minmax(120px, 1fr) minmax(110px, max-content);
  gap: 12px;
  align-items: center;
  margin-bottom: 8px;
}
.mcstq-fee-row label { font-weight: 500; min-width: 0; }
.mcstq-fee-row input {
  width: 100%; padding: 8px; border: 1px solid var(--mcstq-border);
  border-radius: 4px; box-sizing: border-box;
}
.mcstq-fee-row .fee-formatted { text-align: right; color: var(--mcstq-text-muted); }
.mcstq-fee-row #mcstq-fee-total-formatted { text-align: right; font-weight: bold; color: var(--mcstq-primary); }

/* Modal */
.mcstq-modal { position: fixed; top: 0; left: 0; right: 0; bottom: 0; background: rgba(0,0,0,0.5); display: flex; align-items: center; justify-content: center; z-index: 99999; }
.mcstq-modal-content { background: #fff; padding: 30px; border-radius: 12px; max-width: 500px; width: 90%; max-height: 80vh; overflow-y: auto; }

/* Messages */
.mcstq-msg { padding: 10px 16px; border-radius: 6px; margin: 10px 0; font-size: 0.9em; }
.mcstq-msg.success { background: #ecfdf5; color: #065f46; border: 1px solid #a7f3d0; }
.mcstq-msg.error { background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; }

/* Responsive */
@media (max-width: 640px) {
  .mcstq-grid { grid-template-columns: 1fr; }
  .mcstq-hero { padding: 40px 20px; }
  .mcstq-hero h1 { font-size: 1.6em; }
  .mcstq-toolbar { flex-direction: column; }
  .mcstq-search input { width: 100%; }
  .mcstq-step { font-size: 0.8em; padding: 6px 10px; }
}

/* Hide PDF Generator for WP icon on MCST Quote pages */
.pgfw-icon-display {
    display: none !important;
}



.mcstq-table .badge-active { background: #d1fae5; color: #065f46; }