:root {
    --primary-red: #CC0000;
    --primary-dark: #8B0000;
    --primary-light: #FF4D4D;
    --secondary-gold: #FFD700;
    --dark-text: #333333;
    --light-text: #666666;
    --light-bg: #F8F9FA;
    --white: #FFFFFF;
    --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    --border-radius: 8px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Noto Sans', sans-serif;
    color: var(--dark-text);
    line-height: 1.6;
    background-color: var(--light-bg);
}

h1,
h2,
h3,
h4,
h5 {
    font-family: 'Noto Sans', sans-serif;
    font-weight: 600;
    margin-bottom: 1rem;
    color: var(--primary-dark);
}

h1 {
    font-size: 2.5rem;
    line-height: 1.2;
}

h2 {
    font-size: 2rem;
    border-bottom: 2px solid var(--primary-red);
    padding-bottom: 0.5rem;
    margin-bottom: 1.5rem;
}

h3 {
    font-size: 1.5rem;
    color: var(--primary-red);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 15px;
}

.uml-logo {
    height: 70px;
    width: auto;
}

.logo-text {
    display: flex;
    flex-direction: column;
}

.logo-text h3 {
    margin: 0;
    color: var(--primary-red);
    font-size: 1.5rem;
}

.logo-text p {
    font-size: 0.9rem;
    color: var(--light-text);
}

.action-buttons {
    display: flex;
    gap: 15px;
}

.btn {
    display: inline-block;
    background-color: var(--primary-red);
    color: var(--white);
    padding: 10px 20px;
    border: none;
    border-radius: var(--border-radius);
    font-family: 'Poppins', sans-serif;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s;
    text-decoration: none;
    text-align: center;
}

.btn:hover {
    background-color: var(--primary-dark);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--primary-red);
    color: var(--primary-red);
}

.btn-outline:hover {
    background-color: var(--primary-red);
    color: var(--white);
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--primary-red);
    cursor: pointer;
}

/* Main Content */
.main-content {
    padding: 40px 0;
}

.candidate-photo {
    flex: 0 0 300px;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    position: relative;
    transition: transform 0.3s ease;
}

.candidate-photo:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.candidate-photo img {
    width: 100%;
    height: 350px;
    object-fit: cover;
    display: block;
    transition: opacity 0.5s ease-in-out, transform 0.3s ease;
}

/* Image loading animation */
.candidate-photo img.loading {
    opacity: 0.5;
    filter: blur(2px);
}

/* Responsive adjustments for the random image feature */
@media (max-width: 992px) {
    .candidate-photo {
        max-width: 300px;
        width: 100%;
        margin: 0 auto;
    }

    #changeImageBtn {
        font-size: 0.7rem;
        padding: 6px 10px;
        bottom: 8px;
        right: 8px;
    }
}

@media (max-width: 768px) {
    .candidate-photo {
        max-width: 250px;
    }

    .candidate-photo img {
        height: 300px;
    }

    #changeImageBtn {
        display: block !important;
        position: relative;
        bottom: 0;
        right: 0;
        width: 100%;
        margin-top: 10px;
        border-radius: 0 0 var(--border-radius) var(--border-radius);
    }
}

.candidate-header {
    display: flex;
    align-items: center;
    gap: 40px;
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.candidate-photo {
    flex: 0 0 300px;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.candidate-photo img {
    width: 100%;
    height: auto;
    display: block;
}

.candidate-intro {
    flex: 1;
}

.candidate-intro h1 {
    color: var(--primary-red);
}

.election-badge {
    display: inline-block;
    background-color: var(--primary-red);
    color: white;
    padding: 8px 20px;
    border-radius: 30px;
    font-weight: 600;
    margin-top: 10px;
}

/* Biography Sections */
.bio-section {
    margin-bottom: 50px;
}

.bio-content {
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    margin-bottom: 30px;
}

.bio-content p {
    margin-bottom: 1.2rem;
    font-size: 1.2rem;
    text-align: justify;
}

.bio-content ul {
    margin-left: 20px;
    margin-bottom: 20px;
}

.bio-content li {
    margin-bottom: 10px;
}

/* Political Timeline Styling */
.political-timeline {
    list-style-type: none;
    margin: 25px 0;
    padding: 0;
    position: relative;
}

.political-timeline li {
    padding: 15px 20px 15px 50px;
    margin-bottom: 15px;
    background-color: #f8f9fa;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-red);
    position: relative;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05);
    transition: transform 0.2s, box-shadow 0.2s;
}

.political-timeline li:hover {
    transform: translateX(5px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
}

.political-timeline li:before {
    content: "✓";
    position: absolute;
    left: 20px;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--primary-red);
    color: white;
    width: 25px;
    height: 25px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    font-weight: bold;
}

.political-timeline li strong {
    color: var(--primary-dark);
    display: inline-block;
    min-width: 100px;
}

@media (max-width: 768px) {
    .political-timeline li {
        padding: 12px 15px 12px 45px;
    }

    .political-timeline li:before {
        left: 15px;
        width: 22px;
        height: 22px;
        font-size: 12px;
    }

    .political-timeline li strong {
        display: block;
        margin-bottom: 5px;
    }
}

.work-achievements {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(400px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

/* Cultural Organizations Styling */
.cultural-organizations {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin: 25px 0;
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: var(--border-radius);
}

.org-list p {
    margin-bottom: 8px;
    padding-left: 10px;
    border-left: 3px solid var(--primary-red);
    line-height: 1.5;
}

.org-list p strong {
    color: var(--primary-dark);
    min-width: 30px;
    display: inline-block;
}

/* Ward Work Section */
.ward-work-section {
    margin-top: 40px;
}

.ward-work {
    margin-bottom: 30px;
    padding-bottom: 20px;
    border-bottom: 1px solid #eee;
}

.ward-work:last-child {
    border-bottom: none;
}

.ward-work h4 {
    color: var(--primary-red);
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 2px solid #eee;
}

.ward-achievements {
    list-style-type: none;
    padding-left: 0;
}

.ward-achievements li {
    padding: 10px 15px 10px 40px;
    margin-bottom: 10px;
    background-color: #f8f9fa;
    border-radius: var(--border-radius);
    position: relative;
    border-left: 3px solid var(--primary-light);
}

.ward-achievements li:before {
    content: "•";
    position: absolute;
    left: 15px;
    top: 10px;
    color: var(--primary-red);
    font-size: 20px;
    font-weight: bold;
}

.final-note {
    margin-top: 40px;
    padding: 20px;
    background-color: #fff8e1;
    border-radius: var(--border-radius);
    border-left: 5px solid var(--secondary-gold);
}

.final-note p {
    margin: 0;
    font-style: italic;
}

@media (max-width: 768px) {
    .cultural-organizations {
        grid-template-columns: 1fr;
    }

    .ward-achievements li {
        padding: 8px 12px 8px 35px;
    }

    .ward-achievements li:before {
        left: 12px;
    }
}

.achievement-card {
    background-color: var(--light-bg);
    padding: 25px;
    border-radius: var(--border-radius);
    border-left: 4px solid var(--primary-red);
}

/* Modal for QR Code */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.modal-content {
    background-color: var(--white);
    padding: 30px;
    border-radius: var(--border-radius);
    max-width: 400px;
    width: 90%;
    text-align: center;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.modal-content h3 {
    margin-bottom: 20px;
    color: var(--primary-red);
}

.qr-code {
    width: 200px;
    height: 200px;
    margin: 20px auto;
    background-color: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--border-radius);
}

.qr-code img {
    max-width: 100%;
    max-height: 100%;
}

.close-modal {
    background-color: var(--primary-red);
    color: white;
    border: none;
    padding: 10px 25px;
    border-radius: var(--border-radius);
    font-weight: 600;
    cursor: pointer;
    margin-top: 20px;
    width: 100%;
}

.close-modal:hover {
    background-color: var(--primary-dark);
}

/* Manifesto Page */
.manifesto-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 30px;
}

.manifesto-item {
    background-color: var(--white);
    padding: 25px;
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    transition: transform 0.3s;
}

.manifesto-item:hover {
    transform: translateY(-5px);
}

.manifesto-icon {
    font-size: 2.5rem;
    color: var(--primary-red);
    margin-bottom: 15px;
}

/* Footer */
footer {
    background-color: var(--primary-dark);
    color: var(--white);
    padding: 20px 0 20px;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    font-size: 0.9rem;
    color: #ccc;
}

/* Responsive Styles */
@media (max-width: 992px) {
    .candidate-header {
        flex-direction: column;
    }

    .candidate-photo {
        flex: 0 0 auto;
        max-width: 300px;
        width: 100%;
    }

    .work-achievements {
        grid-template-columns: 1fr;
    }

    h1 {
        font-size: 2.2rem;
    }

    h2 {
        font-size: 1.8rem;
    }
}

@media (max-width: 768px) {
    .header-container {
        flex-wrap: wrap;
    }

    .action-buttons {
        width: 100%;
        order: 3;
        margin-top: 15px;
        justify-content: center;
        display: none;
    }

    .action-buttons.active {
        display: flex;
        padding: 15px;
    }

    .mobile-menu-btn {
        display: block;
        padding: 10px
    }

    .bio-content {
        padding: 20px;
    }

    .manifesto-container {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 480px) {
    .action-buttons {
        flex-direction: column;
    }

    .btn {
        width: 100%;
    }
}

/* Page Navigation */
.page-navigation {
    display: flex;
    justify-content: center;
    margin-top: 40px;
    gap: 15px;
}

.page-navigation .btn {
    min-width: 150px;
}

.page-content {
    display: none;
}

.page-content.active {
    display: block;
}

/* Audio Player Styles */
/* Custom Audio Player Styling */

.audio-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #f0f0f0;
}

.audio-header i {
    color: var(--primary-red);
    font-size: 1.8rem;
    background-color: rgba(204, 0, 0, 0.1);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.audio-header h4 {
    margin: 0;
    color: var(--primary-dark);
    font-size: 1.3rem;
}

.custom-audio-container {
    width: 100%;
    margin: 15px 0;
}

/* Custom styling for native audio controls */
.custom-audio-container audio {
    width: 100%;
    height: 50px;
    border-radius: 8px;
    background-color: #f8f9fa;
}

/* Style the audio controls for different browsers */
/* .custom-audio-container audio::-webkit-media-controls-panel {
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 10px;
}

.custom-audio-container audio::-webkit-media-controls-play-button {
    background-color: var(--primary-red);
    border-radius: 50%;
    margin-right: 10px;
}

.custom-audio-container audio::-webkit-media-controls-play-button:hover {
    background-color: var(--primary-dark);
}

.custom-audio-container audio::-webkit-media-controls-current-time-display,
.custom-audio-container audio::-webkit-media-controls-time-remaining-display {
    color: var(--primary-dark);
    font-family: 'Poppins', sans-serif;
    font-weight: 500;
}

.custom-audio-container audio::-webkit-media-controls-timeline {
    background-color: #e0e0e0;
    border-radius: 2px;
    height: 4px;
    margin: 0 10px;
}

.custom-audio-container audio::-webkit-media-controls-timeline::-webkit-slider-thumb {
    background-color: var(--primary-red);
}

.custom-audio-container audio::-webkit-media-controls-volume-slider {
    background-color: #e0e0e0;
    border-radius: 2px;
    height: 4px;
}

.custom-audio-container audio::-webkit-media-controls-volume-slider::-webkit-slider-thumb {
    background-color: var(--primary-red);
}

.custom-audio-container audio::-webkit-media-controls-mute-button {
    background-color: #666;
    border-radius: 50%;
    margin-left: 10px;
}

.custom-audio-container audio::-webkit-media-controls-mute-button:hover {
    background-color: #333;
} */

.audio-note {
    margin-top: 15px;
    padding: 10px 15px;
    background-color: rgba(204, 0, 0, 0.05);
    border-radius: var(--border-radius);
    border-left: 3px solid var(--primary-red);
    font-size: 0.9rem;
    color: var(--light-text);
    display: flex;
    align-items: center;
    gap: 8px;
}

.audio-note i {
    color: var(--primary-red);
    font-size: 1rem;
}

/* Mobile Responsive Design */
@media (max-width: 768px) {
    .audio-section {
        padding: 15px;
    }

    .audio-player {
        padding: 15px;
    }

    .audio-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .audio-header i {
        width: 45px;
        height: 45px;
        font-size: 1.5rem;
    }

    .audio-header h4 {
        font-size: 1.2rem;
    }

    .custom-audio-container audio {
        height: 45px;
    }

    /* Adjust audio controls for mobile */
    .custom-audio-container audio::-webkit-media-controls-panel {
        padding: 5px 8px;
    }

    /* Stack controls vertically on very small screens */
    @media (max-width: 480px) {
        .custom-audio-container audio {
            min-height: 60px;
        }

        .audio-note {
            font-size: 0.85rem;
            padding: 8px 12px;
        }
    }
}

/* Firefox specific styling */
.custom-audio-container audio::-moz-range-track {
    background-color: #e0e0e0;
    height: 4px;
    border-radius: 2px;
}

.custom-audio-container audio::-moz-range-thumb {
    background-color: var(--primary-red);
    border: none;
    width: 12px;
    height: 12px;
    border-radius: 50%;
}

/* Edge specific styling */
.custom-audio-container audio::-ms-track {
    background-color: #e0e0e0;
    height: 4px;
    border-radius: 2px;
}

.custom-audio-container audio::-ms-thumb {
    background-color: var(--primary-red);
}