/* ============================================
   PLN Material Management System
   Color Theme: PLN Blue (#0066cc) + Electric Yellow (#ffc107)
   ============================================ */

:root {
    --pln-blue: #0057a8;
    --pln-blue-dark: #003d75;
    --pln-blue-light: #e8f4fd;
    --pln-yellow: #ffc107;
    --pln-yellow-dark: #e6ac00;
    --sidebar-width: 260px;
    --topbar-height: 65px;
    --border-radius: 12px;
    --shadow: 0 2px 12px rgba(0, 87, 168, 0.08);
    --shadow-hover: 0 8px 25px rgba(0, 87, 168, 0.15);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: #f0f5fa;
    color: #333;
    line-height: 1.6;
}

/* ============================================
   LOGIN PAGE
   ============================================ */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--pln-blue-dark) 0%, var(--pln-blue) 50%, #0078d4 100%);
    position: relative;
    overflow: hidden;
}

.login-page::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 193, 7, 0.1) 0%, transparent 50%);
    animation: pulse 4s ease-in-out infinite;
}

@keyframes pulse {
    0%, 100% { transform: scale(1); opacity: 0.5; }
    50% { transform: scale(1.1); opacity: 1; }
}

.login-container {
    position: relative;
    z-index: 1;
    width: 100%;
    max-width: 420px;
    padding: 20px;
}

.login-card {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.login-header {
    text-align: center;
    margin-bottom: 30px;
}

/* SMAPP Logo */
.smapp-logo {
    width: 70px;
    height: 70px;
    margin: 0 auto 10px;
    filter: drop-shadow(0 4px 10px rgba(0, 162, 233, 0.35));
    animation: logoFloat 3s ease-in-out infinite;
}

.smapp-logo svg {
    width: 100%;
    height: 100%;
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-6px); }
}

.login-header h1 {
    font-size: 1.8rem;
    color: var(--pln-blue);
    margin-bottom: 5px;
}

.login-header h1 i {
    color: var(--pln-yellow);
}

.login-header p {
    color: #666;
    font-size: 0.9rem;
}

.login-logo {
    width: 80px;
    margin-bottom: 15px;
}

.login-form .form-group {
    margin-bottom: 20px;
}

.login-form label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #555;
    font-size: 0.85rem;
}

.login-form label i {
    margin-right: 5px;
    color: var(--pln-blue);
}

.login-footer {
    text-align: center;
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.login-footer p {
    font-size: 0.75rem;
    color: #999;
}

/* ============================================
   LAYOUT
   ============================================ */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* ============================================
   SIDEBAR
   ============================================ */
.sidebar {
    width: var(--sidebar-width);
    background: linear-gradient(180deg, var(--pln-blue-dark) 0%, var(--pln-blue) 100%);
    color: white;
    position: fixed;
    top: 0;
    left: 0;
    height: 100vh;
    z-index: 1000;
    display: flex;
    flex-direction: column;
    transition: var(--transition);
    box-shadow: 4px 0 15px rgba(0, 0, 0, 0.1);
}

.sidebar-header {
    padding: 20px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.3rem;
    font-weight: 700;
}

.logo i {
    font-size: 1.5rem;
    color: var(--pln-yellow);
    text-shadow: 0 0 10px rgba(255, 193, 7, 0.5);
}

.sidebar-logo-icon {
    width: 34px;
    height: 34px;
    display: inline-flex;
}

.sidebar-logo-icon svg {
    width: 100%;
    height: 100%;
}

.sidebar-nav {
    flex: 1;
    padding: 15px 0;
    overflow-y: auto;
}

.sidebar-nav ul {
    list-style: none;
}

.sidebar-nav li a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 20px;
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition);
    border-left: 3px solid transparent;
    font-size: 0.9rem;
}

.sidebar-nav li a:hover {
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-left-color: var(--pln-yellow);
}

.sidebar-nav li.active a {
    background: rgba(255, 255, 255, 0.15);
    color: white;
    border-left-color: var(--pln-yellow);
    font-weight: 500;
}

.sidebar-nav li.active a i {
    color: var(--pln-yellow);
}

.nav-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.1);
    margin: 10px 20px;
}

.sidebar-footer {
    padding: 15px 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.user-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
}

.user-info i {
    color: var(--pln-yellow);
}

/* ============================================
   MAIN CONTENT
   ============================================ */
.main-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    min-height: 100vh;
}

/* ============================================
   TOPBAR
   ============================================ */
.topbar {
    height: var(--topbar-height);
    background: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 25px;
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.topbar-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.sidebar-toggle {
    display: none;
    background: none;
    border: none;
    font-size: 1.2rem;
    color: #555;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: var(--transition);
}

.sidebar-toggle:hover {
    background: var(--pln-blue-light);
    color: var(--pln-blue);
}

.page-title {
    font-size: 1rem;
    font-weight: 600;
    color: var(--pln-blue-dark);
}

.topbar-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

.current-date {
    font-size: 0.85rem;
    color: #666;
}

.current-date i {
    color: var(--pln-blue);
    margin-right: 5px;
}

/* ============================================
   CONTENT AREA
   ============================================ */
.content-area {
    padding: 25px;
}

.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 25px;
}

.page-header h2 {
    font-size: 1.4rem;
    color: var(--pln-blue-dark);
}

.page-header h2 i {
    color: var(--pln-yellow);
    margin-right: 8px;
}

.page-header p {
    color: #666;
    font-size: 0.85rem;
    margin-top: 3px;
}

/* ============================================
   STATS CARDS
   ============================================ */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-bottom: 25px;
}

.stat-card {
    background: white;
    border-radius: var(--border-radius);
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    box-shadow: var(--shadow);
    transition: var(--transition);
    border-left: 4px solid transparent;
}

.stat-card:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.stat-blue { border-left-color: var(--pln-blue); }
.stat-green { border-left-color: #28a745; }
.stat-orange { border-left-color: #fd7e14; }
.stat-purple { border-left-color: #6f42c1; }

.stat-icon {
    width: 55px;
    height: 55px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.stat-blue .stat-icon { background: var(--pln-blue-light); color: var(--pln-blue); }
.stat-green .stat-icon { background: #e8f5e9; color: #28a745; }
.stat-orange .stat-icon { background: #fff3e0; color: #fd7e14; }
.stat-purple .stat-icon { background: #f3e5f5; color: #6f42c1; }

.stat-info h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #333;
}

.stat-info p {
    font-size: 0.8rem;
    color: #888;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* ============================================
   CARDS
   ============================================ */
.card {
    background: white;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-bottom: 20px;
    overflow: hidden;
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 25px;
    border-bottom: 1px solid #f0f0f0;
    background: #fafbfc;
}

.card-header h3 {
    font-size: 1rem;
    color: #333;
    font-weight: 600;
}

.card-header h3 i {
    color: var(--pln-blue);
    margin-right: 8px;
}

.card-body {
    padding: 20px 25px;
}

/* ============================================
   TABLE
   ============================================ */
.table-responsive {
    overflow-x: auto;
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table thead th {
    background: var(--pln-blue-light);
    color: var(--pln-blue-dark);
    padding: 12px 15px;
    text-align: left;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
    white-space: nowrap;
}

.table tbody td {
    padding: 12px 15px;
    border-bottom: 1px solid #f5f5f5;
    font-size: 0.88rem;
    vertical-align: middle;
}

.table tbody tr:hover {
    background: #f8fbff;
}

.table tbody tr:last-child td {
    border-bottom: none;
}

code {
    background: #f0f5fa;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    color: var(--pln-blue);
}

.stock-cell {
    font-weight: 600;
}

.stock-number {
    font-size: 1rem;
}

.action-cell {
    white-space: nowrap;
}

.action-cell .btn {
    margin-right: 4px;
}

.date-cell {
    font-size: 0.82rem;
    color: #666;
}

.date-cell i {
    color: var(--pln-blue);
    margin-right: 4px;
}

/* ============================================
   BADGES
   ============================================ */
.badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 0.72rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.badge-success { background: #e8f5e9; color: #2e7d32; }
.badge-warning { background: #fff8e1; color: #f57f17; }
.badge-danger { background: #fce4ec; color: #c62828; }
.badge-info { background: var(--pln-blue-light); color: var(--pln-blue); }

/* ============================================
   BUTTONS
   ============================================ */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.85rem;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-primary {
    background: var(--pln-blue);
    color: white;
}

.btn-primary:hover {
    background: var(--pln-blue-dark);
}

.btn-success {
    background: #28a745;
    color: white;
}

.btn-success:hover {
    background: #218838;
}

.btn-warning {
    background: var(--pln-yellow);
    color: #333;
}

.btn-warning:hover {
    background: var(--pln-yellow-dark);
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

.btn-info {
    background: #17a2b8;
    color: white;
}

.btn-info:hover {
    background: #138496;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 0.78rem;
}

.btn-block {
    width: 100%;
    justify-content: center;
    padding: 12px;
    font-size: 0.95rem;
}

/* ============================================
   FORMS
   ============================================ */
.form-group {
    margin-bottom: 18px;
}

.form-group label {
    display: block;
    margin-bottom: 6px;
    font-weight: 500;
    color: #555;
    font-size: 0.85rem;
}

.form-group label i {
    margin-right: 5px;
    color: var(--pln-blue);
}

.form-control {
    width: 100%;
    padding: 10px 15px;
    border: 2px solid #e8ecf0;
    border-radius: 8px;
    font-family: 'Poppins', sans-serif;
    font-size: 0.9rem;
    transition: var(--transition);
    background: #fafbfc;
}

.form-control:focus {
    outline: none;
    border-color: var(--pln-blue);
    background: white;
    box-shadow: 0 0 0 3px rgba(0, 87, 168, 0.1);
}

.form-control::placeholder {
    color: #aaa;
}

textarea.form-control {
    resize: vertical;
    min-height: 80px;
}

select.form-control {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23666' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 35px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

/* ============================================
   SEARCH
   ============================================ */
.search-form {
    display: flex;
    align-items: center;
}

.search-input-group {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    position: relative;
}

.search-input-group i {
    position: absolute;
    left: 15px;
    color: #aaa;
    z-index: 1;
}

.search-input-group .form-control {
    padding-left: 40px;
    flex: 1;
}

/* ============================================
   ALERTS
   ============================================ */
.alert {
    padding: 12px 18px;
    border-radius: 8px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.88rem;
    animation: slideDown 0.3s ease;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.alert-success {
    background: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #c8e6c9;
}

.alert-danger {
    background: #fce4ec;
    color: #c62828;
    border: 1px solid #f8bbd0;
}

.alert-info {
    background: var(--pln-blue-light);
    color: var(--pln-blue);
    border: 1px solid #b3d9f2;
}

/* ============================================
   MODALS
   ============================================ */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
    backdrop-filter: blur(3px);
}

.modal.active {
    display: flex;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: white;
    border-radius: 16px;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 25px;
    border-bottom: 1px solid #f0f0f0;
}

.modal-header h3 {
    font-size: 1.1rem;
    color: var(--pln-blue-dark);
}

.modal-header h3 i {
    color: var(--pln-yellow);
    margin-right: 8px;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #999;
    cursor: pointer;
    padding: 5px;
    line-height: 1;
    transition: var(--transition);
}

.modal-close:hover {
    color: #dc3545;
}

.modal-body {
    padding: 25px;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 15px 25px;
    border-top: 1px solid #f0f0f0;
    background: #fafbfc;
    border-radius: 0 0 16px 16px;
}

.material-info-box {
    background: var(--pln-blue-light);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    border: 1px solid #b3d9f2;
}

.material-info-box p {
    font-size: 0.88rem;
    margin-bottom: 5px;
}

.material-info-box p:last-child {
    margin-bottom: 0;
}

.stock-highlight {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--pln-blue);
}

/* ============================================
   EMPTY STATE
   ============================================ */
.empty-state {
    padding: 40px 20px;
    text-align: center;
    color: #999;
}

.empty-state i {
    font-size: 3rem;
    margin-bottom: 15px;
    color: #ddd;
}

.empty-state p {
    font-size: 0.9rem;
}

.empty-state a {
    color: var(--pln-blue);
    text-decoration: none;
    font-weight: 500;
}

.empty-state a:hover {
    text-decoration: underline;
}

/* ============================================
   ROLE BADGES
   ============================================ */
.badge-admin { background: #fff3e0; color: #e65100; border: 1px solid #ffcc80; }
.badge-user { background: var(--pln-blue-light); color: var(--pln-blue); border: 1px solid #b3d9f2; }

.role-info-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.role-info-item {
    padding: 15px;
    border-radius: 8px;
    background: #fafbfc;
    border: 1px solid #eee;
}

.role-info-item p {
    margin-top: 8px;
    font-size: 0.82rem;
    color: #666;
}

/* ============================================
   SETUP GUIDE
   ============================================ */
.setup-guide {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.guide-step {
    display: flex;
    gap: 15px;
    align-items: flex-start;
}

.step-number {
    width: 36px;
    height: 36px;
    min-width: 36px;
    background: var(--pln-blue);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 0.9rem;
}

.step-content h4 {
    font-size: 0.95rem;
    color: #333;
    margin-bottom: 5px;
}

.step-content p {
    font-size: 0.85rem;
    color: #666;
    margin-bottom: 5px;
}

.form-help {
    display: block;
    margin-top: 5px;
    font-size: 0.78rem;
    color: #888;
}

/* ============================================
   SIDEBAR ENHANCEMENTS
   ============================================ */
.nav-section-title {
    padding: 8px 20px 4px;
}

.nav-section-title span {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: rgba(255, 255, 255, 0.4);
    font-weight: 600;
}

.sidebar-footer .user-info {
    display: flex;
    align-items: center;
    gap: 10px;
}

.sidebar-footer .user-info div {
    display: flex;
    flex-direction: column;
}

.sidebar-footer .user-info span {
    font-size: 0.85rem;
    font-weight: 500;
}

.sidebar-footer .user-info small {
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.5);
}

/* ============================================
   ALERT WARNING
   ============================================ */
.alert-warning {
    background: #fff8e1;
    color: #f57f17;
    border: 1px solid #ffecb3;
}

.alert-warning a {
    color: var(--pln-blue);
    font-weight: 500;
}

/* ============================================
   USER BADGE IN TOPBAR
   ============================================ */
.user-badge .badge {
    padding: 5px 12px;
    font-size: 0.75rem;
}

/* ============================================
   UTILITIES
   ============================================ */
.text-center { text-align: center; }

/* ============================================
   PHOTO UPLOAD
   ============================================ */
.photo-upload-area {
    border: 2px dashed #d0d0d0;
    border-radius: 12px;
    padding: 25px;
    text-align: center;
    cursor: pointer;
    transition: var(--transition);
    background: #fafbfc;
}

.photo-upload-area:hover {
    border-color: var(--pln-blue);
    background: var(--pln-blue-light);
}

.photo-upload-area i {
    font-size: 2rem;
    color: #ccc;
    margin-bottom: 8px;
}

.photo-upload-area:hover i {
    color: var(--pln-blue);
}

.photo-upload-area p {
    font-size: 0.85rem;
    color: #888;
    margin-bottom: 4px;
}

.photo-upload-area small {
    font-size: 0.75rem;
    color: #aaa;
}

/* Evidence Thumbnail in Table */
.evidence-thumb {
    display: inline-block;
    width: 45px;
    height: 45px;
    border-radius: 6px;
    overflow: hidden;
    border: 2px solid #e0e0e0;
    transition: var(--transition);
}

.evidence-thumb:hover {
    border-color: var(--pln-blue);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.evidence-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.no-evidence {
    color: #ccc;
    font-size: 0.8rem;
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.9);
    z-index: 9999;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    padding: 20px;
}

.lightbox.active {
    display: flex;
}

.lightbox img {
    max-width: 90%;
    max-height: 90vh;
    border-radius: 8px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.5);
}

/* ============================================
   ABOUT PAGE
   ============================================ */
.about-hero {
    text-align: center;
    padding: 30px 0;
}

.about-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto 15px;
    background: linear-gradient(135deg, var(--pln-blue), var(--pln-blue-dark));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--pln-yellow);
    box-shadow: 0 8px 25px rgba(0, 87, 168, 0.3);
}

.about-hero h2 {
    font-size: 1.5rem;
    color: var(--pln-blue-dark);
    margin-bottom: 5px;
}

.about-version {
    color: #888;
    font-size: 0.85rem;
}

.about-description {
    text-align: center;
    max-width: 600px;
    margin: 0 auto;
    padding: 0 20px 20px;
}

.about-description p {
    color: #555;
    font-size: 0.9rem;
    line-height: 1.7;
}

/* Developer Info */
.developer-info {
    display: flex;
    align-items: center;
    gap: 20px;
    padding: 10px 0;
}

.developer-avatar {
    width: 70px;
    height: 70px;
    min-width: 70px;
    background: linear-gradient(135deg, #ffc107, #ff9800);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: white;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.developer-details h3 {
    font-size: 1.2rem;
    color: #333;
    margin-bottom: 5px;
}

.developer-role, .developer-company {
    font-size: 0.88rem;
    color: #666;
    margin-bottom: 3px;
}

.developer-role i, .developer-company i {
    color: var(--pln-blue);
    margin-right: 6px;
    width: 16px;
}

/* Donation Section */
.donation-section {
    text-align: center;
}

.donation-text {
    font-size: 0.92rem;
    color: #555;
    margin-bottom: 25px;
    line-height: 1.6;
}

.qris-container {
    display: flex;
    justify-content: center;
    margin-bottom: 25px;
}

.qris-card {
    background: #fafbfc;
    border: 2px solid #e8ecf0;
    border-radius: 16px;
    padding: 25px;
    max-width: 360px;
    width: 100%;
}

.qris-header {
    font-size: 0.95rem;
    font-weight: 600;
    color: var(--pln-blue);
    margin-bottom: 15px;
}

.qris-header i {
    margin-right: 6px;
}

.qris-image {
    margin-bottom: 15px;
    display: flex;
    justify-content: center;
}

.qris-info p {
    font-size: 0.88rem;
    color: #333;
    margin-bottom: 5px;
}

.qris-note {
    font-size: 0.78rem !important;
    color: #888 !important;
}

.donation-methods {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.donation-methods h4 {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 12px;
}

.donation-methods h4 i {
    color: var(--pln-blue);
    margin-right: 6px;
}

.payment-icons {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px;
}

.payment-badge {
    background: white;
    border: 1px solid #e0e0e0;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    color: #555;
    font-weight: 500;
}

/* Features Grid */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.feature-item {
    text-align: center;
    padding: 20px 15px;
    border-radius: 12px;
    background: #fafbfc;
    border: 1px solid #f0f0f0;
    transition: var(--transition);
}

.feature-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
    border-color: var(--pln-blue-light);
}

.feature-icon {
    width: 50px;
    height: 50px;
    margin: 0 auto 12px;
    background: var(--pln-blue-light);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    color: var(--pln-blue);
}

.feature-item h4 {
    font-size: 0.9rem;
    color: #333;
    margin-bottom: 5px;
}

.feature-item p {
    font-size: 0.78rem;
    color: #888;
    line-height: 1.4;
}

/* ============================================
   PROFILE PAGE
   ============================================ */
.profile-info {
    display: flex;
    align-items: flex-start;
    gap: 30px;
}

.profile-avatar {
    width: 80px;
    height: 80px;
    min-width: 80px;
    background: var(--pln-blue-light);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    color: var(--pln-blue);
}

.profile-details {
    flex: 1;
}

.profile-row {
    display: flex;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #f5f5f5;
}

.profile-row:last-child {
    border-bottom: none;
}

.profile-label {
    width: 120px;
    font-weight: 500;
    color: #666;
    font-size: 0.85rem;
}

.profile-value {
    font-size: 0.9rem;
    color: #333;
}

/* ============================================
   RESPONSIVE - TABLET & MOBILE
   ============================================ */

/* Sidebar overlay backdrop for mobile */
.sidebar-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 999;
    backdrop-filter: blur(2px);
}

.sidebar-overlay.active {
    display: block;
}

/* ── TABLET (≤ 1024px) ── */
@media (max-width: 1024px) {
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ── MOBILE & SMALL TABLET (≤ 768px) ── */
@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        width: 270px;
        z-index: 1001;
    }
    
    .sidebar.active {
        transform: translateX(0);
    }
    
    .main-content {
        margin-left: 0;
        width: 100%;
    }
    
    .sidebar-toggle {
        display: block;
    }
    
    /* Topbar */
    .topbar {
        padding: 0 12px;
        height: 56px;
    }
    
    .page-title {
        font-size: 0.85rem;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 140px;
    }
    
    .topbar-right {
        gap: 8px;
    }
    
    .topbar-right .current-date {
        display: none;
    }
    
    .user-badge .badge {
        padding: 4px 8px;
        font-size: 0.68rem;
    }
    
    .topbar-right .btn span,
    .topbar-right .btn {
        font-size: 0.75rem;
    }
    
    /* Content */
    .content-area {
        padding: 15px 12px;
    }
    
    .page-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .page-header h2 {
        font-size: 1.2rem;
    }
    
    .page-header .btn {
        width: 100%;
        justify-content: center;
    }
    
    /* Stats */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .stat-card {
        padding: 14px;
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .stat-icon {
        width: 45px;
        height: 45px;
        font-size: 1.1rem;
    }
    
    .stat-info h3 {
        font-size: 1.4rem;
    }
    
    .stat-info p {
        font-size: 0.7rem;
    }
    
    /* Cards */
    .card-header {
        padding: 14px 16px;
        flex-wrap: wrap;
        gap: 10px;
    }
    
    .card-header h3 {
        font-size: 0.9rem;
    }
    
    .card-body {
        padding: 15px 12px;
    }
    
    /* Tables - horizontal scroll with momentum */
    .table-responsive {
        -webkit-overflow-scrolling: touch;
        margin: 0 -12px;
        padding: 0 12px;
        width: calc(100% + 24px);
    }
    
    .table {
        min-width: 600px;
    }
    
    .table thead th,
    .table tbody td {
        padding: 8px 10px;
        font-size: 0.78rem;
        white-space: nowrap;
    }
    
    .action-cell {
        white-space: nowrap;
    }
    
    .action-cell .btn {
        padding: 5px 8px;
        font-size: 0.7rem;
        margin-right: 2px;
    }
    
    /* Search */
    .search-input-group {
        flex-wrap: wrap;
    }
    
    .search-input-group .form-control {
        flex: 1 1 100%;
        margin-bottom: 8px;
    }
    
    .search-input-group .btn {
        flex: 1;
    }
    
    /* Forms */
    .form-row {
        grid-template-columns: 1fr;
        gap: 0;
    }
    
    /* Modals - full screen feel */
    .modal {
        padding: 0;
        align-items: flex-end;
    }
    
    .modal-content {
        max-width: 100%;
        width: 100%;
        max-height: 92vh;
        border-radius: 20px 20px 0 0;
        animation: slideUpMobile 0.3s ease;
    }
    
    @keyframes slideUpMobile {
        from { transform: translateY(100%); }
        to { transform: translateY(0); }
    }
    
    .modal-footer {
        border-radius: 0;
        position: sticky;
        bottom: 0;
    }
    
    .modal-footer .btn {
        flex: 1;
        justify-content: center;
    }
    
    /* Role info */
    .role-info-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    /* About / Developer / Profile */
    .developer-info,
    .profile-info {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .profile-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }
    
    .profile-label {
        width: auto;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
    
    .guide-step {
        gap: 10px;
    }
    
    /* About QRIS */
    .qris-card {
        max-width: 100%;
    }
    
    /* Setup guide code blocks */
    .step-content p code {
        word-break: break-all;
        display: inline-block;
    }
    
    pre {
        font-size: 0.7rem !important;
    }
}

/* ── SMALL MOBILE (≤ 480px) ── */
@media (max-width: 480px) {
    .content-area {
        padding: 12px 10px;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .stat-card {
        flex-direction: row;
        text-align: left;
    }
    
    .login-card {
        padding: 25px 20px;
    }
    
    .login-container {
        padding: 12px;
    }
    
    .login-header h1 {
        font-size: 1.5rem;
    }
    
    .page-title {
        max-width: 110px;
        font-size: 0.78rem;
    }
    
    .topbar-right .btn {
        padding: 6px 10px;
    }
    
    /* Hide logout text, show icon only */
    .topbar-right .btn-danger span {
        display: none;
    }
    
    .card-header .btn-sm {
        font-size: 0.72rem;
        padding: 5px 10px;
    }
    
    .badge {
        font-size: 0.65rem;
        padding: 3px 7px;
    }
    
    .evidence-thumb {
        width: 38px;
        height: 38px;
    }
}

/* ── Landscape phones / prevent zoom on input focus (iOS) ── */
@media (max-width: 768px) {
    input.form-control,
    select.form-control,
    textarea.form-control {
        font-size: 16px; /* prevents iOS auto-zoom */
    }
}
