/* General Styles */
:root {
/* original */
    --primary-color: #2c3e50;
    --secondary-color: #3498db;
    --success-color: #2ecc71;
    --danger-color: #e74c3c;
    --light-color: #ecf0f1;
    --dark-color: #2c3e50;
    --text-color: #333;
    --border-radius: 4px;
    --box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
 
 /* Copied from /index.php for website-content.php to produce accurate preview of sections  */
	--primary-dark: #004494;
	--primary-light: #e6f0ff;
	--secondary-dark: #c0392b;
	--text-light: #666;
	--background-color: #fff;
	--background-light: #f8f9fa;
	--border-color: #ddd;
	--warning-color: #ffc107;
	--transition: all 0.3s ease;
}

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

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: #f5f5f5;
}

/* Login Page Styles */
.login-page {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
}

.login-container {
    width: 100%;
    max-width: 400px;
    padding: 20px;
}

.login-box {
    background: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.login-header {
    text-align: center;
    margin-bottom: 2rem;
}

.login-header h1 {
    color: var(--primary-color);
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.login-header h2 {
    color: var(--secondary-color);
    font-size: 1.2rem;
    font-weight: normal;
}

.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.2rem;
    color: var(--dark-color);
}

.form-group input {
    padding: 0.1rem;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
    font-size: 1rem;
}

.form-group input:focus {
    outline: none;
    border-color: var(--secondary-color);
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2);
}

.form-group input,
.form-group textarea {
	padding: 5px;
	border: 1px solid var(--border-color);
	border-radius: 4px;
	font-family: inherit;
	font-size: 1rem;
}

.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: var(--border-radius);
    font-size: 1rem;
    cursor: pointer;
    text-align: center;
    text-decoration: none;
    transition: background-color 0.3s;
}

.btn-primary {
    background-color: var(--secondary-color);
    color: white;
    width: 100%;
}

.btn-primary:hover {
    background-color: #2980b9;
}

.alert {
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: var(--border-radius);
}

.alert-danger {
    background-color: #fde8e8;
    color: var(--danger-color);
    border: 1px solid #fbd5d5;
}

.login-footer {
    text-align: center;
    margin-top: 2rem;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    color: #666;
    font-size: 0.9rem;
}

/* Backoffice Layout */
.container {
    display: flex;
    min-height: 100vh;
    padding-top: 80px;
}

.sidebar {
    position: fixed;
    top: 80px;
    bottom: 0;
    left: 0;
    z-index: 100;
    padding: 20px 0;
    width: 250px;
    background-color: #f8f9fa;
    border-right: 1px solid #dee2e6;
    overflow-y: auto;
}

.sidebar-sticky {
    position: relative;
    top: 0;
    height: calc(100vh - 60px);
    padding-top: .5rem;
    overflow-x: hidden;
    overflow-y: auto;
}

.sidebar .nav-link {
    font-weight: 500;
    color: #666666;
    padding: 0.75rem 1rem;
    font-size: 1rem;
}

.sidebar .nav-link:hover {
    color: #333333;
    background-color: #e9ecef;
}

.sidebar .nav-link.active {
    color: white;
    background-color: var(--secondary-color);
}

.sidebar .nav-link i {
    margin-right: 8px;
    color: #aaaaaa;
}

.sidebar .nav-link:hover i {
    color: #666666;
}

.sidebar .nav-link.active i {
    color: white;
}

/* Hide the default navbar since we have our own header */
.navbar {
    display: none;
}

/* Ensure main content is properly positioned */
main {
    padding-top: 2rem;
    padding-bottom: 60px;
    margin-left: 250px;
    min-height: calc(100vh - 80px);
}

/* Patient Management Styles */
.patient-container {
    display: flex;
    gap: 2rem;
}

.patient-list {
    width: 300px;
    background: white;
    padding: 1rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.patient-details {
    flex: 1;
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.search-box {
    margin-bottom: 1.5rem;
}

.search-box form {
    display: flex;
    gap: 0.5rem;
}

.search-box input {
    flex: 1;
    padding: 0.75rem;
    border: 1px solid #ddd;
    border-radius: var(--border-radius);
}

.search-box button {
    padding: 0.75rem 1rem;
    background-color: var(--secondary-color);
    color: white;
    border: none;
    border-radius: var(--border-radius);
    cursor: pointer;
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }
    
    .sidebar {
        width: 100%;
    }
    
    .patient-container {
        flex-direction: column;
    }
    
    .patient-list {
        width: 100%;
    }
}

/* Backoffice Header Styles */
.backoffice-header {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    height: 80px;
    background-color: white;
    box-shadow: var(--box-shadow);
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
    padding: 0 20px;
}

.company-name {
    margin-left: 270px; /* 250px sidebar width + 20px padding */
}

.company-name h1 {
    font-size: 1.2rem;
    color: var(--primary-color);
    margin: 0;
}

.company-name h2 {
    font-size: 1rem;
    color: var(--secondary-color);
    margin: 0;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

span.welcome {
    color: var(--text-color);
    font-weight: 500;
}

.btn.btn-secondary, .btn.btn-danger {
    display: inline-block;
    padding: 0.5rem 1rem;
    text-decoration: none;
    border-radius: var(--border-radius);
    font-size: 0.9rem;
    white-space: nowrap;
}

.btn.btn-secondary {
    background-color: var(--secondary-color) !important;
    color: #fff !important;
    border: none;
}

.btn.btn-danger {
    background-color: var(--danger-color);
    color: white;
}

/* Main Layout */
.container-fluid {
    margin-top: 80px; /* Match header height */
    padding: 1.5rem;
    padding-bottom: 60px; /* Match footer height */
}

/* Table styles */
.table-responsive {
    margin-top: 1rem;
    background-color: white;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.table th {
    background-color: var(--light-color);
    border-top: none;
}

.table td, .table th {
    padding: 1rem;
    vertical-align: middle;
}

/* Button styles */
.btn-secondary {
    background-color: var(--secondary-color) !important;
    color: #fff !important;
    border: none;
}

.btn-secondary:hover {
    background-color: #2980b9 !important;
    color: #fff !important;
}

.btn-danger {
    background-color: var(--danger-color);
    color: white;
    border: none;
}

.btn-danger:hover {
    background-color: #c0392b;
}

/* Add styles for the company name to ensure visibility */
.company-name {
    position: fixed;
    top: 0;
    left: 250px;
    padding: 10px 20px;
    background-color: white;
    z-index: 1000;
    width: calc(100% - 250px);
    border-bottom: 1px solid #eee;
}

/* Footer Styles */
.footer {
    position: fixed;
    bottom: 0;
    left: 250px;
    right: 0;
    height: 50px;
    background-color: white; /* Changed from #f8f9fa to white */
    border-top: 1px solid #dee2e6;
    padding: 0.75rem;
    text-align: center;
    font-size: 0.9rem;
    color: #333333; /* Darkened text color */
    z-index: 900;
}

.footer .container {
    padding: 0;
    margin: 0;
    width: 100%;
} 

/* Copied from /index.php for website-content.php to produce preview of sections */

        /* Testimonials Section */
        .testimonials {
            padding: 80px 0;
            background-color: var(--background-light);
        }

        .testimonial-slider {
            position: relative;
            max-width: 800px;
            margin: 0 auto;
            overflow: hidden;
        }

        .testimonial-slide {
            display: none;
            animation: fadeIn 0.5s ease forwards;
        }

        .testimonial-slide.active {
            display: block;
        }

        @keyframes fadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        .testimonial-content {
            background-color: white;
            border-radius: 8px;
            padding: 30px;
            box-shadow: var(--box-shadow);
        }

        .testimonial-quote {
            position: relative;
            padding: 20px 40px;
            text-align: center;
            font-style: italic;
            color: var(--text-light);
        }

        .testimonial-quote i {
            color: var(--primary-color);
            opacity: 0.3;
            font-size: 1.5rem;
        }

        .testimonial-quote i.fa-quote-left {
            position: absolute;
            top: 0;
            left: 0;
        }

        .testimonial-quote i.fa-quote-right {
            position: absolute;
            bottom: 0;
            right: 0;
        }

        .testimonial-author {
            display: flex;
            align-items: center;
            margin-top: 20px;
            padding: 0 20px;
        }

        .testimonial-author img {
            width: 60px;
            height: 60px;
            border-radius: 50%;
            object-fit: cover;
            margin-right: 15px;
            border: 3px solid var(--primary-color);
        }

        .testimonial-author h4 {
            margin: 0;
            color: var(--primary-color);
        }

        .testimonial-author p {
            margin: 0;
            font-size: 0.9rem;
            color: var(--text-light);
        }

        .testimonial-controls {
            display: flex;
            justify-content: center;
            align-items: center;
            margin-top: 30px;
        }

        .testimonial-prev,
        .testimonial-next {
            background: none;
            border: none;
            font-size: 1.5rem;
            color: var(--primary-color);
            cursor: pointer;
            padding: 0 15px;
        }

        .testimonial-dots {
            display: flex;
            gap: 10px;
        }

        .testimonial-dot {
            width: 12px;
            height: 12px;
            border-radius: 50%;
            background-color: #ccc;
            cursor: pointer;
            transition: var(--transition);
        }

        .testimonial-dot.active {
            background-color: var(--primary-color);
        }

        /* Patient Resources Section */
        .resources {
            padding: 80px 0;
        }

        .resources-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
            gap: 30px;
        }

        .resource-card {
            background-color: white;
            border-radius: 8px;
            padding: 30px;
            text-align: center;
            box-shadow: var(--box-shadow);
            transition: var(--transition);
            border-top: 4px solid var(--primary-color);
        }

        .resource-card:hover {
            transform: translateY(-10px);
        }

        .resource-icon {
            font-size: 2.5rem;
            color: var(--primary-color);
            margin-bottom: 20px;
        }

        .resource-card h3 {
            font-size: 1.3rem;
            margin-bottom: 15px;
            color: var(--primary-color);
        }

        .resource-card p {
            color: var(--text-light);
            margin-bottom: 20px;
        }

        /* Locations Section */
        .locations {
            padding: 80px 0;
            background-color: var(--background-light);
        }

        .locations-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 30px;
        }

        .location-card {
            background-color: white;
            border-radius: 8px;
            overflow: hidden;
            box-shadow: var(--box-shadow);
 	max-width: 400px;
	margin: auto;
       }

        .location-image {
            height: 200px;
            overflow: hidden;
        }

        .location-image img {
            width: 100%;
            height: 100%;
            object-fit: cover;
        }

        .location-card h3 {
            padding: 20px 20px 10px;
            font-size: 1.5rem;
            color: var(--primary-color);
        }

        .location-card p {
            padding: 0 20px;
            margin-bottom: 10px;
        }

        .location-card i {
            color: var(--primary-color);
            margin-right: 10px;
        }

        .location-directions-btn {
            margin: 10px 20px 20px;
        }

        /* Insurance Section */
        .insurance {
            padding: 80px 0;
            background-color: var(--background-light);
        }

        .insurance-content {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 40px;
            align-items: center;
        }

        .insurance-text {
            padding-right: 20px;
        }

        .insurance-text p {
            margin-bottom: 20px;
            color: var(--text-light);
        }

        .insurance-logos {
            display: grid;
            grid-template-columns: repeat(3, 1fr);
            gap: 20px;
        }

        .insurance-logo {
            background-color: white;
            border-radius: 8px;
            padding: 20px;
            display: flex;
            align-items: center;
            justify-content: center;
            box-shadow: var(--box-shadow);
        }

        .insurance-logo img {
            max-width: 100%;
            max-height: 60px;
            object-fit: contain;
        }

        /* FAQ Section */
        .faq {
            padding: 80px 0;
        }

        .faq-container {
            max-width: 800px;
            margin: 0 auto;
        }

        .faq-item {
            margin-bottom: 15px;
            border-radius: 8px;
            overflow: hidden;
            box-shadow: var(--box-shadow);
        }

        .faq-question {
            background-color: white;
            padding: 20px;
            cursor: pointer;
            display: flex;
            justify-content: space-between;
            align-items: center;
        }

        .faq-question h3 {
            margin: 0;
            font-size: 1.1rem;
            color: var(--primary-color);
        }

        .faq-toggle {
            color: var(--primary-color);
            transition: var(--transition);
            flex-shrink: 0;
            margin-left: 10px;
        }

        .faq-item.active .faq-toggle {
            transform: rotate(45deg);
        }

        .faq-answer {
            background-color: white;
            padding: 0 20px;
            max-height: 0;
            overflow: hidden;
            transition: max-height 0.3s ease, padding 0.3s ease;
        }

        .faq-item.active .faq-answer {
            padding: 0 20px 20px;
            max-height: 1000px;
        }

        .faq-more {
            text-align: center;
            margin-top: 30px;
        }

        /* Blog Preview Section */
        .blog-preview {
            padding: 80px 0;
            background-color: var(--background-light);
        }

        .blog-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 30px;
        }

        .blog-card {
            background-color: white;
            border-radius: 8px;
            overflow: hidden;
            box-shadow: var(--box-shadow);
            transition: var(--transition);
        }

        .blog-card:hover {
            transform: translateY(-10px);
        }

        .blog-image {
            height: 200px;
            overflow: hidden;
        }

        .blog-image img {
            width: 100%;
            height: 100%;
            object-fit: cover;
            transition: var(--transition);
        }

        .blog-card:hover .blog-image img {
            transform: scale(1.1);
        }

        .blog-content {
            padding: 20px;
        }

        .blog-date {
            color: var(--text-light);
            font-size: 0.9rem;
            margin-bottom: 10px;
        }

        .blog-date i {
            margin-right: 5px;
        }

        .blog-content h3 {
            font-size: 1.2rem;
            margin-bottom: 10px;
            color: var(--primary-color);
        }

        .blog-content p {
            color: var(--text-light);
            margin-bottom: 15px;
        }

        .blog-link {
            color: var(--primary-color);
            font-weight: 500;
            display: inline-flex;
            align-items: center;
        }

        .blog-link i {
            margin-left: 5px;
            transition: var(--transition);
        }

        .blog-link:hover i {
            transform: translateX(5px);
        }

        .blog-more {
            text-align: center;
            margin-top: 30px;
        }

        /* Contact Section */
        .contact-section {
            padding: 80px 0;
            background-color: var(--background-light);
        }

        .contact-grid {
            display: grid;
            grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
            gap: 30px;
        }

        .contact-info {
            display: flex;
            flex-direction: column;
            gap: 20px;
        }

        .contact-item {
            display: flex;
            align-items: flex-start;
            gap: 15px;
        }

        .contact-item i {
            font-size: 1.5rem;
            color: var(--primary-color);
            margin-top: 5px;
        }

        .contact-item h3 {
            margin-bottom: 5px;
            color: var(--primary-color);
        }

        .contact-form {
            background-color: white;
            border-radius: 8px;
            padding: 30px;
            box-shadow: var(--box-shadow);
        }

        .question-container {
            display: flex;
            align-items: flex-start;
            margin-bottom: 20px;
        }

        .question-content {
            flex: 1;
        }

        /* Section dividers */
        .section-divider {
            border-top: 2px solid var(--gray-light);
            margin: 10px 0 10px 0;
            padding-top: 10px;
        }

        .section-title {
            font-size: 20px;
            font-weight: 700;
            color: var(--primary);
            margin-bottom: 20px;
            display: flex;
            align-items: center;
        }

        .section-title i {
            margin-right: 10px;
        }

/* Policy Page Styles */
.policy-page-container {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--background-light);
    padding: 32px 8px;
}

.policy-card {
    background: var(--background-color);
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    max-width: 700px;
    width: 100%;
    padding: 2.5rem 2rem 2rem 2rem;
    margin: 0 auto;
    border: 1px solid var(--border-color);
}

.policy-card h1 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    text-align: center;
}

.policy-content h2 {
    font-size: 1.25rem;
    color: var(--secondary-color);
    margin-top: 1.5rem;
    margin-bottom: 0.5rem;
}

.policy-content ul {
    margin-left: 1.5rem;
    margin-bottom: 1rem;
}

.policy-content p, .policy-content li {
    font-size: 1.05rem;
    line-height: 1.7;
    color: var(--text-color);
}

.policy-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 2rem;
}

@media (max-width: 600px) {
    .policy-card {
        padding: 1.2rem 0.5rem 1rem 0.5rem;
    }
    .policy-card h1 {
        font-size: 1.3rem;
    }
    .policy-content h2 {
        font-size: 1.05rem;
    }
}
.form-radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 2em; /* space between options */
    align-items: center;
    margin-bottom: 0.5em;
}

.form-radio-group label {
    display: flex;
    align-items: center;
    margin-right: 1.5em;
    font-weight: normal;
    cursor: pointer;
}

.form-radio-group input[type="radio"] {
    margin-right: 0.4em;
}

/* Optional: Make form fields more compact */
.form-row {
    display: flex;
    flex-wrap: wrap;
    gap: 2em;
    align-items: flex-start;
    margin-bottom: 1em;
}

.form-row > * {
    flex: 1 1 200px;
    min-width: 180px;
}
.radio-group {
    display: flex;
    flex-direction: row;
    gap: 2em; /* space between Yes/No */
    align-items: center;
    margin-bottom: 0.5em;
}

.radio-option {
    display: flex;
    align-items: center;
    margin-right: 1.5em;
    font-weight: normal;
    cursor: pointer;
}

.radio-option input[type="radio"] {
    margin-right: 0.4em;
}