/* ============ GLOBAL ============ */
* {
    font-family: "Segoe UI", Tahoma, Geneva, Verdana, sans-serif;
    font-size: 10pt;
}

/* ---------- SIDEBAR (setFixedWidth 400) ---------- */
QWidget#SidebarWidget {
    background-color: #34495e;
}

/* QWidget#SidebarWidget {
    background-color: qlineargradient(
        x1: 0, y1: 0, x2: 0, y2: 1,
        stop: 0 #196F3D,
        stop: 1 #145A32
    );
} */

QPushButton[menuButton="true"] {
    color: #ecf0f1;
    background: transparent;
    padding: 10px 20px;
    text-align: left;
    border: none;
}

QPushButton[menuButton="true"]:hover {
    background-color: #2c3e50;             /* hover sama seperti HTML */
}

QPushButton[menuButton="true"].active {     /* bisa di-toggle pakai setProperty("active", true) */
    background-color: #3498db;
    border-left: 4px solid #2980b9;
}

/* ---------- MAIN CONTENT ---------- */
QStackedWidget {
    background-color: #ecf0f1;
}

/* Kartu / panel putih */
QFrame[card="true"], QWidget[card="true"] {
    background: #ffffff;
    border-radius: 5px;
    padding: 15px;
    /* bayangan ringan simulasi */
    border: 1px solid rgba(0,0,0,0.05);
}

/* Card header */
QLabel[cardHeader="true"] {
    color: #2c3e50;
    font-weight: bold;
    border-bottom: 1px solid #eeeeee;
    padding-bottom: 6px;
}

/* ---------- BUTTON GENERIC ---------- */
QPushButton {
    min-height: 28px;
    min-width: 90px;
    border-radius: 4px;
    font-weight: 600;
}

QPushButton[class~="primary"] {
    background: #3498db;
    color: #ffffff;
}

QPushButton[class~="danger"] {
    background: #e74c3c;
    color: #ffffff;
}

QPushButton[class~="success"] {
    background: #27ae60;
    color: #ffffff;
}

QPushButton:pressed {
    padding-left: 11px;                     /* kesan ditekan */
    padding-top: 1px;
}

/* ---------- TABLE ---------- */
QHeaderView::section {
    background: #2c3e50;
    color: #ffffff;
    padding: 6px;
    border: none;
}

QTableWidget QTableCornerButton::section {
    background: #2c3e50;
}

/* Row hover */
QTableWidget::item:hover {
    background: #f5f5f5;
}

/* ---------- STATUS BADGE ---------- */
QLabel[status="completed"]  { background:#d4edda; color:#155724; padding:3px 6px; border-radius:3px; }
QLabel[status="pending"]    { background:#fff3cd; color:#856404; }
QLabel[status="cancelled"]  { background:#f8d7da; color:#721c24; }

/* ---------- LOGIN WINDOW (opsional) ---------- */
QWidget#LoginContainer {
    background: #ffffff;
    border-radius: 5px;
    padding: 30px;
    border: 1px solid rgba(0,0,0,0.08);
}

img.logo {
  display:block;
  margin:0 auto 6px auto;
  max-height:80px;
  max-width:200px;
}

QPushButton.barang-action {
    background-color: #28a745;
    color: white;
    font-weight: bold;
    padding: 8px 20px;
    border-radius: 10px;
}
QPushButton.barang-action:hover {
    background-color: #218838;
}


QTableWidget.load-transaksi::item:selected {
    background: #d0d0d0;
    color: black;
}
QPushButton.load-toggle {
    background-color: #17a2b8;
    color: white;
    font-weight: bold;
    padding: 4px 12px;
    border-radius: 5px;
    font-size: 8pt;
}
QPushButton.load-toggle:hover { background-color: #138496; }
QLabel.load-info {
    background-color: #f8f9fa;
    border: 2px solid #28a745;
    border-radius: 6px;
    padding: 12px;
    font-size: 10pt;
    line-height: 1.4;
    min-height: 180px;
}
QPushButton.load-close {
    background-color: #6c757d;
    color: white;
    font-weight: bold;
    padding: 10px 30px;
    border-radius: 8px;
    font-size: 10pt;
}
QPushButton.load-close:hover { background-color: #5a6268; }


QTableWidget.pembayaran::item:selected {
    background: #d0d0d0;
    color: black;
}
QPushButton.pembayaran-batal {
    background-color: #28a745;
    color: white;
    font-weight: bold;
    padding: 8px 20px;
    border-radius: 10px;
}
QPushButton.pembayaran-batal:hover { background-color: #218838; }
QPushButton.pembayaran-ok {
    background-color: #28a745;
    color: white;
    font-weight: bold;
    padding: 8px 20px;
    border-radius: 10px;
}
QPushButton.pembayaran-ok:hover { background-color: #218838; }


QPushButton.return-btn {
    background-color: #dc3545;
    color: white;
    font-weight: bold;
    padding: 8px 16px;
    border-radius: 6px;
}
QPushButton.return-btn:hover { background-color: #c82333; }
QCheckBox.return-header {
    font-weight: bold;
}


QComboBox.tpv-customer-input { margin: 0px; padding: 5px; }
QLineEdit.tpv-barang-input { margin: 0px; padding: 5px; }
QCheckBox.tpv-popup-checkbox { margin: 0px; padding: 0px; }
QGroupBox.tpv-info-diskon { font-weight: bold; }
QGroupBox.tpv-info-diskon QLabel { margin-bottom: 4px; }
QPushButton.tpv-simpan-btn {
    background-color: #28a745;
    color: white;
    font-weight: bold;
    padding: 8px 20px;
    border-radius: 10px;
}
QPushButton.tpv-simpan-btn:hover { background-color: #218838; }
QPushButton.tpv-shortcut-btn {
    background-color: #2c3e50;
    color: white;
    border: 1px solid #34495e;
    border-radius: 4px;
    padding: 6px 10px;
    text-align: left;
    font-size: 9pt;
    font-weight: 500;
}
QPushButton.tpv-shortcut-btn:hover {
    background-color: #34495e;
    border: 1px solid #3498db;
}
QPushButton.tpv-shortcut-btn:pressed {
    background-color: #1abc9c;
    border: 1px solid #16a085;
}
QGroupBox.tpv-diskon-group {
    font-weight: bold;
    border: 1px solid #ccc;
    border-radius: 6px;
    margin-top: 6px;
    padding: 4px;
}
QGroupBox.tpv-diskon-group::title {
    subcontrol-origin: margin;
    subcontrol-position: top center;
    padding: 0 4px;
}
QGroupBox.tpv-diskon-group QLabel,
QGroupBox.tpv-diskon-group QRadioButton {
    padding-left: 2px;
}
QPushButton.tpv-hapus-btn {
    background-color: #28a745;
    color: white;
    font-weight: bold;
    padding: 2px 4px;
    border-radius: 4px;
    font-size: 10px;
}
QPushButton.tpv-hapus-btn:hover { background-color: #218838; }

