* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans Sinhala', Arial, sans-serif;
    background: linear-gradient(135deg, #ff9933, #ffcc66);
    min-height: 100vh;
    position: relative;
}

body:has(.category-container) {
    background: none;
}

:root {
    --gold: #d4af37;
    --gold-glow: rgba(212, 175, 55, 0.4);
    --bg-dark: rgba(0, 0, 0, 0.85);
}

.bg-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.bg-image {
    width: 100%;
    height: 100%;
    background: linear-gradient(var(--bg-dark), var(--bg-dark)), #2d5016;
    background-size: cover;
    background-position: center;
}

.bg-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('image_79dc29.png');
    background-size: cover;
    background-position: center;
    opacity: 0;
    z-index: -1;
}

@keyframes slowZoom {
    from { transform: scale(1); }
    to { transform: scale(1.15); }
}

.main-wrapper {
    height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.glass-box {
    position: relative;
    max-width: 700px;
    padding: 60px 40px;
    text-align: center;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(212, 175, 55, 0.15);
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    cursor: pointer;
    transition: transform 0.3s ease;
    opacity: 1;
    transform: translateY(0);
}

.glass-box:hover {
    transform: translateY(-5px);
}

@keyframes boxFadeIn {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.splash-title {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2.5rem, 8vw, 4rem);
    font-weight: 700;
    letter-spacing: 2px;
    margin-bottom: 5px;
    background: linear-gradient(to right, #fff 20%, var(--gold) 40%, var(--gold) 60%, #fff 80%);
    background-size: 200% auto;
    color: #fff;
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: shine 8s linear infinite;
}

@keyframes shine {
    to { background-position: 200% center; }
}

.divider {
    height: 1px;
    width: 80px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    margin: 25px auto;
}

.english-text {
    font-weight: 200;
    line-height: 1.8;
    font-size: 1.1rem;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 35px;
    letter-spacing: 0.5px;
}

.sinhala-container {
    font-family: 'Noto Sans Sinhala', sans-serif;
    margin-top: 20px;
    animation: calmBreath 5s infinite ease-in-out;
}

.sinhala-main {
    display: block;
    font-size: 1.8rem;
    font-weight: 500;
    color: #fff;
    margin-bottom: 8px;
}

.sinhala-sub {
    display: block;
    font-size: 1.2rem;
    color: var(--gold);
    font-weight: 300;
}

@keyframes calmBreath {
    0%, 100% { opacity: 0.7; transform: translateY(0); }
    50% { opacity: 1; transform: translateY(-5px); }
}

.status {
    margin-top: 40px;
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 6px;
    color: var(--gold);
    opacity: 0.5;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% { opacity: 0.5; }
    50% { opacity: 1; }
}

.hidden {
    display: none;
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 10;
}

.login-container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(45, 80, 22, 0.8);
    z-index: -1;
}

.login-box {
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(15px);
    padding: 40px;
    border-radius: 15px;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
    text-align: center;
    border: 1px solid rgba(212, 175, 55, 0.15);
    animation: boxFadeIn 1s ease-out;
}

.temple-logo img {
    width: 120px;
    height: 120px;
    margin-bottom: 20px;
}

.system-name {
    color: #fff;
    font-size: 24px;
    margin-bottom: 10px;
    font-weight: bold;
    font-family: 'Inter', sans-serif;
}

.system-subtitle {
    color: var(--gold);
    font-size: 16px;
    margin-bottom: 30px;
    font-family: 'Noto Sans Sinhala', sans-serif;
}

.form-group {
    margin-bottom: 20px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    color: #fff;
    font-weight: bold;
    font-family: 'Noto Sans Sinhala', sans-serif;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid rgba(212, 175, 55, 0.3);
    border-radius: 8px;
    font-size: 16px;
    transition: border-color 0.3s;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    backdrop-filter: blur(5px);
}

.form-group input:focus {
    outline: none;
    border-color: var(--gold);
    background: rgba(255, 255, 255, 0.15);
}

.form-group input::placeholder {
    color: rgba(255, 255, 255, 0.6);
}

.login-btn {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #2d5016, #4a7c59);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s;
    font-family: 'Noto Sans Sinhala', sans-serif;
    box-shadow: 0 4px 15px rgba(45, 80, 22, 0.3);
}

.login-btn:hover {
    background: linear-gradient(135deg, #1a3009, #2d5016);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(45, 80, 22, 0.5);
}

.category-container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px;
    position: relative;
    z-index: 1;
    min-height: 100vh;
    padding-top: 15vh;
}

.category-container::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background: linear-gradient(rgba(25, 42, 86, 0.85), rgba(25, 42, 86, 0.75)), url('https://images.unsplash.com/photo-1544735716-392fe2489ffa?ixlib=rb-4.0.3&auto=format&fit=crop&w=1920&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    z-index: -1;
}

.category-header {
    text-align: center;
    margin-bottom: 40px;
    color: #fff;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    background: rgba(0, 0, 0, 0.4);
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(212, 175, 55, 0.3);
}

.category-header h1 {
    color: #fff;
    font-family: 'Noto Sans Sinhala', sans-serif;
    margin: 0;
    font-size: 28px;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
}

.logout-btn {
    padding: 10px 20px;
    background: rgba(212, 175, 55, 0.9);
    color: #000;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Noto Sans Sinhala', sans-serif;
    font-weight: bold;
    transition: all 0.3s;
    backdrop-filter: blur(5px);
}

.logout-btn:hover {
    background: var(--gold);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.4);
}

.category-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
    max-width: 1000px;
    margin-left: auto;
    margin-right: auto;
}

.category-card {
    background: white;
    padding: 0;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    text-align: center;
    cursor: pointer;
    transition: transform 0.3s, box-shadow 0.3s;
    border: 3px solid transparent;
    aspect-ratio: 4/3;
    min-height: 200px;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    border-color: #ff9933;
}

.category-title {
    font-size: clamp(16px, 4vw, 20px);
    font-weight: bold;
    color: white;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.8);
    z-index: 2;
    position: relative;
    padding: 10px;
    line-height: 1.2;
}

.category-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(to bottom, rgba(0,0,0,0.4), rgba(0,0,0,0.7));
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    transition: all 0.3s;
}

.category-card:hover .category-overlay {
    background: linear-gradient(to bottom, rgba(0,0,0,0.2), rgba(0,0,0,0.6));
}

.secondary-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 20px;
    flex-wrap: wrap;
}

.secondary-btn {
    padding: 12px 20px;
    background: rgba(212, 175, 55, 0.9);
    color: #000;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-family: 'Noto Sans Sinhala', sans-serif;
    font-weight: bold;
    transition: all 0.3s;
    backdrop-filter: blur(5px);
    font-size: 14px;
    min-width: 140px;
}

.secondary-btn:hover {
    background: var(--gold);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(212, 175, 55, 0.4);
}

.bank-grid, .inventory-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.bank-card, .inventory-card {
    background: rgba(255, 255, 255, 0.95);
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.1);
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    border: 2px solid transparent;
}

.bank-card:hover, .inventory-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    border-color: var(--gold);
}

.bank-card h3, .inventory-card h3 {
    color: #2d5016;
    margin-bottom: 15px;
    font-size: 18px;
}

.bank-card p, .inventory-card p {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

.professional-form {
    background: rgba(255, 255, 255, 0.95);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.3);
    max-width: 800px;
    margin: 0 auto;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.professional-form h2 {
    color: #2d5016;
    margin-bottom: 20px;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.1);
}

.professional-form label {
    color: #333;
    font-weight: bold;
    margin-bottom: 8px;
    display: block;
    font-size: 16px;
}

.professional-form input, .professional-form select {
    width: 100%;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    margin-bottom: 20px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    font-weight: 500;
}

.professional-form input:focus, .professional-form select:focus {
    outline: none;
    border-color: #2d5016;
    background: white;
    box-shadow: 0 0 10px rgba(45, 80, 22, 0.2);
}

.form-container {
    margin-top: 20px;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin-top: 30px;
}

.table-input {
    width: 100%;
    padding: 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
}

.inventory-controls {
    display: flex;
    gap: 15px;
    margin: 20px 0;
    justify-content: center;
}

.inventory-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 16px;
    box-shadow: 0 10px 40px rgba(0,0,0,0.1);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.inventory-container h2 {
    color: #2d5016;
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 30px;
    text-align: center;
    background: linear-gradient(135deg, #2d5016, #4a7c59);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
}

.inventory-container h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 3px;
    background: linear-gradient(90deg, #2d5016, #4a7c59);
    border-radius: 2px;
}

.inventory-tabs {
    display: flex;
    margin-bottom: 30px;
    background: rgba(245, 245, 245, 0.8);
    border-radius: 12px;
    padding: 8px;
    border: 1px solid rgba(0,0,0,0.1);
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.05);
}

.tab-btn {
    flex: 1;
    padding: 14px 20px;
    background: transparent;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 15px;
    transition: all 0.3s ease;
    color: #666;
    position: relative;
    overflow: hidden;
}

.tab-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(45, 80, 22, 0.1), transparent);
    transition: left 0.5s;
}

.tab-btn:hover::before {
    left: 100%;
}

.tab-btn.active {
    background: linear-gradient(135deg, #2d5016, #4a7c59);
    color: white;
    box-shadow: 0 4px 15px rgba(45, 80, 22, 0.3);
    transform: translateY(-2px);
}

.tab-btn:hover:not(.active) {
    background: rgba(45, 80, 22, 0.1);
    color: #2d5016;
    transform: translateY(-1px);
}

.inventory-actions {
    display: flex;
    gap: 15px;
    margin-bottom: 25px;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: flex-end;
}

.search-container {
    flex: 1;
    max-width: 400px;
}

.search-container input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e1e5e9;
    border-radius: 10px;
    font-size: 15px;
    transition: all 0.3s ease;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
}

.search-container input:focus {
    outline: none;
    border-color: #2d5016;
    box-shadow: 0 0 0 3px rgba(45, 80, 22, 0.1);
    background: white;
}

.search-container input::placeholder {
    color: #999;
    font-style: italic;
}

.reports-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.summary-card {
    padding: 20px;
    border-radius: 8px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.summary-card h3 {
    margin: 0 0 10px 0;
    color: #333;
    font-size: 16px;
}

.summary-card h2 {
    margin: 0;
    font-size: 24px;
}

.settings-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.settings-card {
    background: rgba(255, 255, 255, 0.95);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    text-align: center;
}

.settings-card h3 {
    color: #2d5016;
    margin-bottom: 10px;
}

.settings-card p {
    color: #666;
    margin-bottom: 15px;
}

.btn-group {
    display: flex;
    gap: 10px;
    justify-content: center;
}

.btn {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s;
}

.btn:hover::before {
    left: 100%;
}

.btn-primary {
    background: linear-gradient(135deg, #2d5016, #4a7c59);
    color: white;
    box-shadow: 0 4px 15px rgba(45, 80, 22, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1a3009, #2d5016);
    box-shadow: 0 6px 20px rgba(45, 80, 22, 0.5);
    transform: translateY(-2px);
}

.btn-success {
    background: linear-gradient(135deg, #28a745, #20c997);
    color: white;
    box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3);
}

.btn-success:hover {
    background: linear-gradient(135deg, #1e7e34, #17a2b8);
    box-shadow: 0 6px 20px rgba(40, 167, 69, 0.5);
    transform: translateY(-2px);
}

.btn-warning {
    background: linear-gradient(135deg, #ffc107, #fd7e14);
    color: #000;
    box-shadow: 0 4px 15px rgba(255, 193, 7, 0.3);
}

.btn-warning:hover {
    background: linear-gradient(135deg, #e0a800, #dc3545);
    box-shadow: 0 6px 20px rgba(255, 193, 7, 0.5);
    transform: translateY(-2px);
}

.btn-info {
    background: linear-gradient(135deg, #17a2b8, #6f42c1);
    color: white;
    box-shadow: 0 4px 15px rgba(23, 162, 184, 0.3);
}

.btn-info:hover {
    background: linear-gradient(135deg, #117a8b, #4a148c);
    box-shadow: 0 6px 20px rgba(23, 162, 184, 0.5);
    transform: translateY(-2px);
}

.btn-secondary {
    background: linear-gradient(135deg, #6c757d, #495057);
    color: white;
    box-shadow: 0 4px 15px rgba(108, 117, 125, 0.3);
}

.btn-secondary:hover {
    background: linear-gradient(135deg, #545b62, #343a40);
    box-shadow: 0 6px 20px rgba(108, 117, 125, 0.5);
    transform: translateY(-2px);
}

.btn-danger {
    background: linear-gradient(135deg, #dc3545, #c82333);
    color: white;
    box-shadow: 0 4px 15px rgba(220, 53, 69, 0.3);
}

.btn-danger:hover {
    background: linear-gradient(135deg, #bd2130, #a02622);
    box-shadow: 0 6px 20px rgba(220, 53, 69, 0.5);
    transform: translateY(-2px);
}

.btn-sm {
    padding: 8px 16px;
    font-size: 12px;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    margin: 2px;
    font-weight: 600;
    transition: all 0.3s ease;
    text-transform: none;
    letter-spacing: normal;
}

.btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
}

.dashboard {
    display: none;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.dashboard.active {
    display: block;
}

.dashboard-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(rgba(25, 42, 86, 0.85), rgba(25, 42, 86, 0.75)), url('back2.png');
    background-size: cover;
    background-position: center;
    z-index: -1;
}

.dashboard-header {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.dashboard-header h1 {
    color: #cc6600;
    font-family: 'Noto Sans Sinhala', sans-serif;
    margin: 0;
    font-size: 24px;
    font-weight: bold;
}

.nav-menu {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.nav-btn {
    padding: 10px 20px;
    background: #f0f0f0;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background 0.3s;
}

.nav-btn:hover, .nav-btn.active {
    background: linear-gradient(135deg, #2d5016, #4a7c59);
    color: white;
    box-shadow: 0 3px 10px rgba(45, 80, 22, 0.4);
}

.content-area {
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    min-height: 400px;
    color: #333;
}

.content-area h2, .content-area h3, .content-area h4 {
    color: #cc6600;
    margin-bottom: 20px;
}

.content-area label {
    color: #333;
    font-weight: bold;
    margin-bottom: 5px;
    display: block;
}

.content-area input, .content-area select {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    margin-bottom: 15px;
    background: white;
    color: #333;
}

.content-area input:focus, .content-area select:focus {
    outline: none;
    border-color: #ff9933;
}

.content-area textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
    margin-bottom: 15px;
    background: white;
    color: #333;
    font-family: inherit;
    resize: vertical;
}

.content-area textarea:focus {
    outline: none;
    border-color: #2d5016;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 20px;
}

.btn {
    padding: 10px 20px;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
    transition: background 0.3s;
}

.btn-primary {
    background: linear-gradient(135deg, #2d5016, #4a7c59);
    color: white;
    box-shadow: 0 4px 15px rgba(45, 80, 22, 0.3);
}

.btn-primary:hover {
    background: linear-gradient(135deg, #1a3009, #2d5016);
    box-shadow: 0 6px 20px rgba(45, 80, 22, 0.5);
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #545b62;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    margin: 2px;
    font-weight: bold;
    transition: all 0.3s;
}

.btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 25px;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0,0,0,0.1);
    border: 1px solid rgba(0,0,0,0.05);
}

.table th {
    background: linear-gradient(135deg, #2d5016, #4a7c59);
    color: white;
    font-weight: 600;
    padding: 18px 12px;
    text-align: center;
    font-size: 14px;
    white-space: nowrap;
    position: relative;
}

.table th::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: rgba(255, 255, 255, 0.2);
}

.table td {
    padding: 16px 12px;
    text-align: center;
    border-bottom: 1px solid rgba(0,0,0,0.05);
    font-size: 14px;
    vertical-align: middle;
    transition: background-color 0.2s ease;
}

.table tbody tr:hover {
    background: rgba(45, 80, 22, 0.02);
}

.table tbody tr:nth-child(even) {
    background: rgba(0,0,0,0.01);
}

.table tbody tr:last-child td {
    border-bottom: none;
}

@media (max-width: 768px) {
    .glass-box {
        padding: 30px 20px;
        margin: 10px;
        max-width: 90vw;
    }
    
    .splash-title {
        font-size: clamp(1.8rem, 6vw, 2.5rem);
    }
    
    .category-container {
        padding-top: 10vh;
        max-width: 100%;
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .category-grid {
        grid-template-columns: 1fr;
        gap: 20px;
        max-width: 400px;
    }
    
    .category-card {
        min-height: 180px;
        aspect-ratio: 16/9;
    }
    
    .category-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
        padding: 15px;
    }
    
    .secondary-buttons {
        flex-direction: column;
        gap: 10px;
    }
    
    .secondary-btn {
        width: 100%;
        padding: 12px;
        background: rgba(0, 0, 0, 0.6);
        color: #fff;
        border: 2px solid rgba(212, 175, 55, 0.8);
    }
    
    .secondary-btn:hover {
        background: rgba(212, 175, 55, 0.9);
        color: #000;
    }
    
    .form-row {
        grid-template-columns: 1fr;
    }
    
    .nav-buttons {
        flex-direction: column;
        gap: 8px;
    }
    
    .nav-btn {
        width: 100%;
        padding: 12px;
        text-align: center;
        font-size: 14px;
    }
    
    .dashboard-header {
        flex-direction: column;
        gap: 10px;
        text-align: center;
        padding: 15px;
    }
    
    .dashboard-header h1 {
        font-size: 20px;
    }
    
    .dashboard {
        padding: 10px;
    }
    
    .content-area {
        padding: 15px;
        overflow-x: auto;
    }
    
    .professional-form {
        padding: 20px 15px;
        margin: 10px;
        max-width: calc(100vw - 20px);
    }
    
    .professional-form input, .professional-form select {
        padding: 12px;
        font-size: 16px;
    }
    
    .table {
        font-size: 12px;
        min-width: 600px;
    }
    
    .table th, .table td {
        padding: 8px 4px;
        font-size: 11px;
    }
    
    .btn-sm {
        padding: 4px 8px;
        font-size: 10px;
    }
    
    .bank-grid, .inventory-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .reports-summary {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .summary-card {
        padding: 15px;
    }
    
    .inventory-controls {
        flex-direction: column;
        gap: 10px;
    }
    
    .form-actions {
        flex-direction: column;
        gap: 10px;
    }
    
    .form-actions .btn {
        width: 100%;
        padding: 12px;
    }

    /* Mobile-specific inventory styles */
    .inventory-container {
        padding: 0 5px;
    }

    .inventory-tabs {
        flex-wrap: wrap;
        gap: 5px;
    }

    .tab-btn {
        padding: 10px 16px;
        font-size: 14px;
        min-width: 80px;
        flex: 1;
        min-height: 44px; /* Touch-friendly */
    }

    .inventory-actions {
        flex-direction: column;
        gap: 10px;
        margin-bottom: 15px;
    }

    .inventory-actions .btn {
        width: 100%;
        padding: 12px;
        min-height: 44px;
        font-size: 16px;
    }

    .search-container input {
        font-size: 16px !important; /* Prevents zoom on iOS */
        padding: 12px !important;
        min-height: 44px !important;
        border-radius: 8px !important;
        margin-bottom: 8px !important;
        -webkit-appearance: none; /* Removes iOS styling */
        appearance: none;
    }

    .search-container input::-webkit-search-decoration,
    .search-container input::-webkit-search-cancel-button,
    .search-container input::-webkit-search-results-button,
    .search-container input::-webkit-search-results-decoration {
        -webkit-appearance: none; /* Removes default search styling */
    }

    .table-container {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        margin: 0 -5px;
        padding: 0 5px;
    }

    .table {
        min-width: 800px; /* Ensure horizontal scroll */
        font-size: 14px;
    }

    .table th, .table td {
        padding: 10px 8px;
        white-space: nowrap;
        min-width: 80px;
    }

    .table th {
        font-size: 12px;
        padding: 12px 8px;
    }

    .btn-sm {
        padding: 8px 12px;
        font-size: 12px;
        min-height: 36px;
        min-width: 60px;
    }

    /* Modal styling improvements */
    .modal {
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.7);
        backdrop-filter: blur(8px);
        z-index: 1000;
        display: flex;
        align-items: center;
        justify-content: center;
        animation: modalFadeIn 0.3s ease-out;
    }
    
    @keyframes modalFadeIn {
        from { opacity: 0; }
        to { opacity: 1; }
    }
    
    .modal > div {
        background: white;
        border-radius: 16px;
        box-shadow: 0 20px 60px rgba(0,0,0,0.3);
        max-width: 600px;
        width: 90%;
        max-height: 90vh;
        overflow: hidden;
        animation: modalSlideIn 0.3s ease-out;
    }
    
    @keyframes modalSlideIn {
        from { transform: translateY(-50px); opacity: 0; }
        to { transform: translateY(0); opacity: 1; }
    }
    
    .modal h3 {
        color: #2d5016;
        margin-bottom: 20px;
        font-size: 1.5rem;
        font-weight: 700;
        text-align: center;
        position: relative;
    }
    
    .modal h3::after {
        content: '';
        position: absolute;
        bottom: -8px;
        left: 50%;
        transform: translateX(-50%);
        width: 50px;
        height: 2px;
        background: linear-gradient(90deg, #2d5016, #4a7c59);
        border-radius: 1px;
    }
    
    .modal form {
        padding: 20px;
        max-height: calc(90vh - 120px);
        overflow-y: auto;
    }
    
    .modal .form-group {
        margin-bottom: 20px;
    }
    
    .modal .form-group label {
        display: block;
        margin-bottom: 8px;
        color: #333;
        font-weight: 600;
        font-size: 14px;
    }
    
    .modal input, .modal select, .modal textarea {
        width: 100%;
        padding: 12px 16px;
        border: 2px solid #e1e5e9;
        border-radius: 8px;
        font-size: 15px;
        transition: all 0.3s ease;
        background: rgba(255, 255, 255, 0.9);
        backdrop-filter: blur(10px);
    }
    
    .modal input:focus, .modal select:focus, .modal textarea:focus {
        outline: none;
        border-color: #2d5016;
        box-shadow: 0 0 0 3px rgba(45, 80, 22, 0.1);
        background: white;
    }
    
    .modal textarea {
        resize: vertical;
        min-height: 80px;
    }
    
    .modal .form-actions {
        display: flex;
        gap: 12px;
        justify-content: flex-end;
        margin-top: 30px;
        padding-top: 20px;
        border-top: 1px solid #e1e5e9;
    }
    
    /* Modal improvements for mobile */
    .modal {
        margin: 10px;
        max-height: calc(100vh - 20px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .modal > div {
        margin: 0;
        max-width: none;
        width: calc(100vw - 20px);
        max-height: calc(100vh - 20px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .modal form {
        max-height: calc(100vh - 120px);
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }

    .modal input, .modal select, .modal textarea {
        font-size: 16px !important; /* Prevents zoom on iOS */
        padding: 12px !important;
        min-height: 44px !important;
    }

    .modal .btn {
        min-height: 44px;
        padding: 12px 20px;
        font-size: 16px;
    }

    /* Responsive table alternative for very small screens */
    @media (max-width: 480px) {
        .table {
            font-size: 12px;
        }

        .table th, .table td {
            padding: 8px 4px;
        }

        .btn-sm {
            padding: 6px 8px;
            font-size: 11px;
        }
    }
}