:root {
    --primary: #2563EB;
    --primary-dark: #183B5B;
    --sidebar: #142B4A;
    --background: #F4F7FB;
    --white: #FFFFFF;
    --text: #1E293B;
    --muted: #64748B;
    --border: #E2E8F0;
}
.admin-logo {
    width: 100px;
    height: auto;
    object-fit: contain;
    margin-bottom: 15px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: Arial, sans-serif;
}

body {
    background: var(--background);
    color: var(--text);
}

/* Login */

.login-container {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--sidebar);
}

.login-box {
    width: 350px;
    background: var(--white);
    padding: 35px;
    border-radius: 12px;
    text-align: center;
}

.login-box h1 {
    color: var(--primary-dark);
    margin-bottom: 10px;
}

.login-box p {
    margin-bottom: 20px;
}

.login-box input {
    width: 100%;
    padding: 13px;
    margin-bottom: 15px;
    border: 1px solid var(--border);
    border-radius: 6px;
}

.login-box button {
    width: 100%;
    padding: 13px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
}

#errorMessage {
    color: red;
    margin-top: 12px;
}

/* Dashboard */

header {
    background: var(--sidebar);
    color: white;
    padding: 20px 5%;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

header button {
    background: white;
    color: var(--primary-dark);
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
}

.dashboard-content {
    padding: 40px 5%;
}

.dashboard-content h1 {
    margin-bottom: 15px;
}

.dashboard-cards {
    display: flex;
    gap: 25px;
    margin: 30px 0;
    flex-wrap: wrap;
}

.card {
    background: white;
    padding: 30px;
    border-radius: 10px;
    flex: 1;
    min-width: 250px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.06);
}

.card h2 {
    margin-bottom: 15px;
    color: var(--primary-dark);
}

.card p {
    margin-bottom: 20px;
}

button {
    cursor: pointer;
}

.card button,
.date-filter button,
.filters button,
.dashboard-content > button {
    background: var(--primary);
    color: white;
    border: none;
    padding: 11px 18px;
    border-radius: 5px;
}

/* Filters */

.filters {
    display: flex;
    gap: 10px;
    margin: 25px 0;
    flex-wrap: wrap;
}

.date-filter {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 25px 0;
    flex-wrap: wrap;
}

.date-filter input {
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 5px;
}

/* Table */

.table-container {
    overflow-x: auto;
    background: white;
    border-radius: 10px;
    margin-top: 20px;
}

table {
    width: 100%;
    border-collapse: collapse;
    min-width: 650px;
}

th, td {
    padding: 15px;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

th {
    background: var(--primary-dark);
    color: white;
}

td button {
    padding: 8px 10px;
    margin: 3px;
    border: none;
    border-radius: 4px;
    background: var(--primary);
    color: white;
}

/* Mobile */

@media(max-width: 600px) {

    .login-box {
        width: 90%;
    }

    .dashboard-content {
        padding: 25px 15px;
    }

    .dashboard-cards {
        flex-direction: column;
    }

    .date-filter {
        align-items: stretch;
        flex-direction: column;
    }

}
/* NoxCare Brand */

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.header-logo {
    width: 55px;
    height: 55px;
    object-fit: contain;
}

.brand h2 {
    color: white;
    font-size: 24px;
    letter-spacing: 1px;
}
/* Professional Status Buttons */

td button {
    padding: 5px 11px;
    font-size: 12px;
    font-weight: 600;
    border: none;
    border-radius: 20px;
    cursor: pointer;
    transition: 0.2s ease;
    margin: 2px;
}

td button:hover {
    opacity: 0.85;
}

/* Pending */
td button.pending {
    background: #FEF3C7;
    color: #B45309;
}

/* Visited */
td button.visited {
    background: #DCFCE7;
    color: #15803D;
}

/* Status Badges */

.status-badge {
    display: inline-block;
    padding: 5px 11px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.status-badge.pending {
    background: #FEF3C7;
    color: #B45309;
}

.status-badge.visited {
    background: #DCFCE7;
    color: #15803D;
}

/* Action Buttons */

.action-btn {
    padding: 6px 11px;
    font-size: 12px;
    font-weight: 600;
    border: none;
    border-radius: 5px;
    margin: 2px;
    cursor: pointer;
}

.verify-btn {
    background: #DBEAFE;
    color: #1D4ED8;
}

.prescription-btn {
    background: #E0E7FF;
    color: #4338CA;
}

.action-btn:hover {
    opacity: 0.8;
}

/* Professional Appointment Summary Cards */

.dashboard-cards .card {
    background: #FFFFFF;
    padding: 22px 25px;
    border-radius: 12px;
    border: 1px solid #E2E8F0;
    border-left: 4px solid #2563EB;
    box-shadow: 0 3px 12px rgba(30, 58, 95, 0.06);
    min-width: 200px;
    max-width: 280px;
}

.dashboard-cards .card h2 {
    font-size: 15px;
    color: #64748B;
    font-weight: 600;
    margin-bottom: 12px;
}

.dashboard-cards .card h1 {
    font-size: 30px;
    color: #1E293B;
    font-weight: 700;
    margin: 0;
}

/* Pending Card */
.dashboard-cards .card:first-child {
    border-left-color: #F59E0B;
}

/* Visited Card */
.dashboard-cards .card:last-child {
    border-left-color: #16A34A;
}

/* Filter Buttons */

.filter-btn {
    padding: 8px 16px !important;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: 0.2s;
}

.all-btn {
    background: #DBEAFE !important;
    color: #1D4ED8 !important;
}

.pending-btn {
    background: #FEF3C7 !important;
    color: #B45309 !important;
}

.visited-btn {
    background: #DCFCE7 !important;
    color: #15803D !important;
}

.filter-btn:hover,
.back-btn:hover {
    opacity: 0.8;
}
/* Back Button */

.back-btn {
    background: #64748B !important;
    color: white !important;
    padding: 8px 16px !important;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
}

/* Filter Buttons */

.filter-btn {
    padding: 8px 16px !important;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
}

.all-btn {
    background: #DBEAFE !important;
    color: #1D4ED8 !important;
}

.pending-btn {
    background: #FEF3C7 !important;
    color: #B45309 !important;
}

.visited-btn {
    background: #DCFCE7 !important;
    color: #15803D !important;
}

/* Search Button */

.search-btn {
    background: #2563EB !important;
    color: white !important;
    padding: 9px 18px !important;
    border: none;
    border-radius: 6px;
    font-weight: 600;
}
.back-container {
    display: flex;
    justify-content: flex-end;
    margin-bottom: 20px;
}
/* Professional Dark Back Button */

.back-btn {
    background: #183B5B !important;
    color: #FFFFFF !important;
    padding: 8px 18px !important;
    border: none;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 600;
    transition: 0.2s;
}

.back-btn:hover {
    background: #142B4A !important;
}
/* NEW: Appointment Card Design */

.appointment-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-top: 20px;
}

.appointment-card {
    background: #FFFFFF;
    border: 1px solid #E2E8F0;
    border-radius: 12px;
    padding: 18px;
    box-shadow: 0 3px 10px rgba(0,0,0,0.05);
}

.appointment-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 10px;
}

.customer-info {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.customer-avatar {
    width: 45px;
    height: 45px;
    min-width: 45px;
    border-radius: 50%;
    background: #DBEAFE;
    color: #1D4ED8;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 20px;
    font-weight: bold;
}

.customer-details h3 {
    font-size: 16px;
    margin-bottom: 7px;
    color: #1E293B;
}

.customer-details p {
    font-size: 13px;
    color: #64748B;
    margin-bottom: 5px;
}

.appointment-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 10px;
}

.sr-number {
    font-size: 12px;
    font-weight: 600;
    color: #64748B;
}

.appointment-actions {
    display: flex;
    gap: 10px;
    margin-top: 15px;
    flex-wrap: wrap;
}

.appointment-actions .action-btn {
    flex: 1;
    min-height: 42px;
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
}

.no-appointments {
    background: white;
    padding: 25px;
    text-align: center;
    border-radius: 10px;
    color: #64748B;
}

@media (max-width: 600px) {

    .appointment-card {
        padding: 14px;
    }

    .appointment-actions {
        gap: 8px;
    }

    .appointment-actions .action-btn {
        min-width: 100%;
    }

}
/* NEW: Appointment Search */
.search-box {
    margin: 15px 0;
}

.search-box input {
    width: 100%;
    max-width: 400px;
    padding: 12px 15px;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
}

.search-box input:focus {
    border-color: #2563EB;
}
/* NEW: Search Button */
.search-box {
    display: flex;
    gap: 10px;
    margin: 15px 0;
    flex-wrap: wrap;
}

.search-box input {
    width: 100%;
    max-width: 400px;
    padding: 12px 15px;
    border: 1px solid #E2E8F0;
    border-radius: 8px;
    outline: none;
    font-size: 14px;
}

.search-btn {
    background: #2563EB;
    color: white;
    border: none;
    padding: 12px 22px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
}

.search-btn:hover {
    background: #183B5B;
} 
/* =====================================
   MY OPTICAL - EYE PRESCRIPTION
===================================== */

.prescription-page {
    min-height: 100vh;
    background: #F1F5F9;
    padding: 25px;
    color: #1E293B;
    font-family: system-ui, Arial, sans-serif;
}

/* Header */

.prescription-header {
    max-width: 950px;
    margin: 0 auto 30px;
    background: linear-gradient(120deg, #1D4ED8, #06B6D4);
    padding: 18px 24px;
    border-radius: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: white;
    box-shadow: 0 8px 20px rgba(37, 99, 235, 0.15);
}

.brand {
    display: flex;
    align-items: center;
    gap: 13px;
}

.brand img {
    width: 58px;
    height: 58px;
    object-fit: contain;
    background: white;
    padding: 5px;
    border-radius: 13px;
}

.brand p {
    font-size: 12px;
    color: #DBEAFE;
}

.brand h2 {
    font-size: 23px;
    font-weight: 800;
}

.admin-label {
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    background: rgba(255,255,255,0.18);
    padding: 9px 13px;
    border-radius: 30px;
}

/* Heading */

.prescription-heading,
.prescription-card {
    max-width: 950px;
    margin-left: auto;
    margin-right: auto;
}

.prescription-heading {
    margin-bottom: 22px;
}

.prescription-heading h1 {
    font-size: 27px;
    font-weight: 800;
    color: #173B67;
}

.prescription-heading p {
    color: #64748B;
    font-size: 14px;
    margin-top: 5px;
}

/* White Cards */

.prescription-card {
    background: #FFFFFF;
    padding: 25px;
    border: 1px solid #E2E8F0;
    border-radius: 17px;
    margin-bottom: 22px;
    box-shadow: 0 4px 15px rgba(15, 23, 42, 0.035);
}

.prescription-card > h3 {
    font-size: 17px;
    font-weight: 750;
    color: #173B67;
    margin-bottom: 20px;
}

/* Customer Details */

.customer-details {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.customer-details label,
.prescription-inputs label,
.pd-box label {
    display: block;
    color: #64748B;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 8px;
}

.customer-details p {
    font-size: 15px;
    font-weight: 700;
    color: #1E40AF;
}

/* Eye Cards */

.eye-card {
    background: #F8FAFF;
    border: 1px solid #DBEAFE;
    border-radius: 13px;
    padding: 20px;
    margin-bottom: 17px;
}

.eye-card h4 {
    color: #1D4ED8;
    font-size: 16px;
    font-weight: 750;
    margin-bottom: 18px;
}

.eye-card h4 span {
    color: #64748B;
    font-size: 13px;
    font-weight: 500;
}

/* Inputs */

.prescription-inputs {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.prescription-page input {
    width: 100%;
    height: 45px;
    border: 1px solid #CBD5E1;
    background: #FFFFFF;
    border-radius: 9px;
    padding: 0 13px;
    font-size: 14px;
    color: #173B67;
    outline: none;
    transition: 0.2s;
}

.prescription-page input:focus {
    border-color: #2563EB;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.10);
}

.prescription-page input::placeholder {
    color: #A0AEC0;
}

/* PD */

.pd-box {
    max-width: 300px;
    margin-top: 22px;
}

/* Buttons */

.prescription-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 30px;
}

.prescription-actions button {
    min-width: 145px;
    padding: 13px 20px;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    transition: 0.2s;
}

.back-btn {
    background: #EFF6FF;
    color: #1D4ED8;
}

.back-btn:hover {
    background: #DBEAFE;
}

.save-btn {
    background: linear-gradient(120deg, #2563EB, #0891B2);
    color: white;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.17);
}

.save-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.25);
}

/* Mobile Responsive */

@media (max-width: 600px) {

    .prescription-page {
        padding: 13px;
    }

    .prescription-header {
        padding: 15px;
        border-radius: 14px;
        margin-bottom: 23px;
    }

    .brand img {
        width: 47px;
        height: 47px;
    }

    .brand h2 {
        font-size: 19px;
    }

    .admin-label {
        font-size: 9px;
        padding: 7px 9px;
    }

    .prescription-heading h1 {
        font-size: 23px;
    }

    .prescription-card {
        padding: 18px;
        border-radius: 14px;
    }

    .customer-details {
        grid-template-columns: 1fr;
        gap: 17px;
    }

    .prescription-inputs {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .eye-card {
        padding: 16px;
    }

    .pd-box {
        max-width: 100%;
    }

    .prescription-actions {
        flex-direction: column-reverse;
    }

    .prescription-actions button {
        width: 100%;
    }
}
/* NEW: Improve Mobile Readability */

@media (max-width: 600px) {

    .prescription-page {
        padding: 14px;
    }

    .brand p {
        font-size: 15px !important;
    }

    .brand h2 {
        font-size: 23px !important;
    }

    .admin-label {
        font-size: 13px !important;
    }

    .prescription-heading h1 {
        font-size: 30px !important;
        line-height: 1.3;
    }

    .prescription-heading p {
        font-size: 17px !important;
        line-height: 1.5;
    }

    .prescription-card {
        padding: 20px !important;
    }

    .prescription-card h3 {
        font-size: 22px !important;
        margin-bottom: 18px;
    }

    .customer-details label {
        font-size: 16px !important;
    }

    .customer-details p {
        font-size: 19px !important;
        line-height: 1.5;
        word-break: break-word;
    }

    .eye-card {
        padding: 18px !important;
    }

    .eye-card h4 {
        font-size: 21px !important;
    }

    .prescription-inputs label,
    .pd-box label {
        font-size: 17px !important;
        font-weight: 600;
    }

    .prescription-inputs input,
    .pd-box input {
        font-size: 19px !important;
        min-height: 54px;
        padding: 14px !important;
    }

    .prescription-actions button {
        font-size: 18px !important;
        min-height: 54px;
        font-weight: 600;
    }

}