/* ===== GLOBAL ===== */

body {
    background: radial-gradient(circle at 20% 20%, #1e293b, #0f172a 60%);
    color: #e2e8f0;
    font-family: system-ui, -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ===== CARD ===== */

.app-card {
    background: rgba(30, 41, 59, 0.6);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.08);
    border-radius: 16px;
}

/* ===== LIST ROW ===== */

.row-item {
    padding: 18px 22px;
    border-bottom: 1px solid rgba(255,255,255,0.05);
    transition: 0.2s ease;
}

.row-item:hover {
    background: rgba(255,255,255,0.04);
}

.row-uszkodzony {
    border-left: 4px solid #fa00bb;
    background: rgba(245, 158, 11, 0.05);
}

.row-kradziony {
    border-left: 4px solid #ef4444;
    background: rgba(239, 68, 68, 0.05);
}

/* ===== TEXT ===== */

.title-line { font-size: 1rem; }

.details-inline {
    color: #cbd5e1;
    font-size: 0.9rem;
    margin-left: 8px;
}

.imei-inline {
    color: #fbbf24;
    font-size: 0.8rem;
    margin-left: 8px;
}

.muted {
    color: #94a3b8;
    font-size: 0.8rem;
}

.label {
    font-weight: 600;
    font-size: 0.9rem;
}

.price-gold {
    color: #fbbf24;
    font-weight: 700;
    margin-left: 6px;
}

.price-green {
    color: #22c55e;
    font-weight: 600;
    margin-left: 6px;
}

/* ===== BUTTON ===== */

.btn-primary {
    background: linear-gradient(135deg, #3b82f6, #6366f1);
    border: none;
    border-radius: 10px;
}

/* ===== INPUT DARK ===== */

.bg-dark-input {
    background-color: rgba(255,255,255,0.06) !important;
    border: 1px solid rgba(255,255,255,0.12) !important;
    color: #e2e8f0 !important;
    border-radius: 12px;
    padding: 10px 12px;
}

.bg-dark-input:focus {
    background-color: rgba(255,255,255,0.08) !important;
    border-color: #3b82f6 !important;
    box-shadow: none !important;
    color: white !important;
}

textarea.bg-dark-input {
    resize: none;
}

/* ===== MODAL CLEAN ===== */

.modal-content {
    border: none !important;
}

/* ===== TOGGLE ===== */

.toggle-btn {
    background: rgba(255,255,255,0.06);
    border: 1px solid rgba(255,255,255,0.15);
    color: #e2e8f0;
    padding: 8px 16px;
    border-radius: 10px;
    margin-right: 10px;
    transition: all 0.25s ease;
    cursor: pointer;
}

.toggle-btn:hover {
    background: rgba(255,255,255,0.12);
}

.toggle-active-kradziony {
    background: #ef4444;
    border-color: #ef4444;
    color: white;
    box-shadow: 0 0 15px rgba(239, 68, 68, 0.5);
}

.toggle-active-uszkodzony {
    background: #f59e0b;
    border-color: #f59e0b;
    color: white;
    box-shadow: 0 0 15px rgba(245, 158, 11, 0.4);
}

/* Disabled input */
.input-disabled {
    opacity: 0.4;
    pointer-events: none;
}

/* ===== LINKS ===== */

a {
    color: #93c5fd;
    text-decoration: none;
}

a:hover {
    color: #60a5fa;
}

/* ===== MODAL ANIMATION ===== */

.modal.fade .modal-dialog {
    transform: scale(0.96);
    transition: transform 0.25s ease;
}

.modal.show .modal-dialog {
    transform: scale(1);
}

/* ===== MARŻA ===== */

.margin-percent {
    font-size: 0.75rem;
    font-weight: 600;
    margin-left: 8px;
    opacity: 0.8;
    color: #cbd5e1;
}

.margin-positive {
    color: #22c55e;
}

.margin-negative {
    color: #ef4444;
}

/* ===== FLOATING TOAST ===== */

#toast-container {
    position: fixed;
    top: 30px;
    right: 30px;
    z-index: 1080; /* tylko nad modalem bootstrap */
}

.custom-toast {
    background: rgba(30, 41, 59, 0.85);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255,255,255,0.1);
    color: #e2e8f0;
    padding: 14px 18px;
    border-radius: 12px;
    margin-bottom: 12px;
    font-weight: 500;
    min-width: 260px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);

    opacity: 0;
    transform: translateY(-15px);
    animation: toastIn 0.35s ease forwards;
}

@keyframes toastIn {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.toast-hide {
    opacity: 0 !important;
    transform: translateY(-10px);
    transition: 0.3s ease;
}

/* ===== DETAILS MODAL CONTENT ===== */

.details-modal-content div {
    margin-bottom: 14px;
    font-size: 0.95rem;
}

.details-modal-content strong {
    color: #94a3b8;
    font-weight: 600;
    margin-right: 6px;
}

/* ===== PLACEHOLDER FIX ===== */

.bg-dark-input::placeholder {
    color: #94a3b8 !important;   /* jasny szaroniebieski */
    opacity: 1;
}

.bg-dark-input::-ms-input-placeholder {
    color: #94a3b8 !important;
}

/* ===== SELECT DARK FIX ===== */

select.bg-dark-input {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;

    background-color: rgba(255,255,255,0.06) !important;
    color: #e2e8f0 !important;

    background-image: url("data:image/svg+xml;utf8,<svg fill='%23cbd5e1' height='20' viewBox='0 0 24 24' width='20' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 16px;
    padding-right: 36px;

}

/* dropdown options */
select.bg-dark-input option {
    background-color: #1e293b;
    color: #e2e8f0;
}

/* ===== REMOVE NUMBER INPUT ARROWS ===== */

/* Chrome, Edge, Safari */
input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox */
input[type=number] {
    -moz-appearance: textfield;
}

.is-invalid {
    border: 1px solid #ef4444 !important;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.2);
}

.is-invalid:focus {
    border-color: #ef4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.3);
}

.link-icon {
    font-size: 20px;
    text-decoration: none;
    color: #d4af37;
}

.link-icon:hover {
    transform: scale(1.2);
}

/* =====================================
   OPERATOR WATERMARK
===================================== */

.row-item {
    position: relative;
    overflow: hidden;
}

/* wspólne ustawienia */
.row-item.operator-tmobile::after,
.row-item.operator-plus::after,
.row-item.operator-orange::after,
.row-item.operator-play::after {
    content: "";
    position: absolute;
    right: 25%; 
    /* left: 65%;  */
    top: 50%;
    transform: translateY(-50%) scale(0.70);
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    opacity: 0.8;
    pointer-events: none;
}

/* ===== T-MOBILE ===== */
.row-item.operator-tmobile::after {
    width: 220px;
    height: 120px;
    background-image: url("/static/wyceny/logos/tmobile.svg");
}

/* ===== PLUS ===== */
.row-item.operator-plus::after {
    width: 200px;
    height: 100px;
    background-image: url("/static/wyceny/logos/plus.svg");
}

/* ===== ORANGE ===== */
.row-item.operator-orange::after {
    width: 100px;
    height: 100px;
    background-image: url("/static/wyceny/logos/orange.svg");
}

/* ===== PLAY ===== */
.row-item.operator-play::after {
    width: 180px;
    height: 100px;
    background-image: url("/static/wyceny/logos/play.svg");
}

.hidden-checkbox {
    display: none;
}

.toggle-btn-active {
    background-color: #a70dfd;
    border-color: #a70dfd;
    color: white;
}