/* CSS Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', 'Helvetica', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8f9fa;
}

/* Header Styles */
header {
    background: linear-gradient(135deg, #2c3e50 0%, #3498db 100%);
    color: white;
    text-align: center;
    padding: 60px 20px 40px;
    margin-bottom: 40px;
}

header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.subtitle {
    font-size: 1.2rem;
    opacity: 0.9;
    font-weight: 300;
}

/* Main Content */
main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Intro Section */
.intro {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin-bottom: 40px;
}

.intro h2 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 20px;
    border-bottom: 3px solid #3498db;
    padding-bottom: 10px;
}

.intro p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
}

/* Cleaning Services Section */
.cleaning-services {
    display: grid;
    gap: 30px;
    margin-bottom: 50px;
}

.service-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: grid;
    grid-template-columns: auto 300px 1fr;
    min-height: 280px;
}

.service-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0,0,0,0.15);
}

/* Rank Number */
.rank {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
    display: flex;
    align-items: center;
    justify-content: center;
    width: 80px;
    position: relative;
}

.rank-number {
    color: white;
    font-size: 2rem;
    font-weight: bold;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

/* Service Image */
.service-image {
    position: relative;
    overflow: hidden;
}

.service-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.service-card:hover .service-image img {
    transform: scale(1.05);
}

/* Service Content */
.service-content {
    padding: 30px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.service-content h3 {
    color: #2c3e50;
    font-size: 1.8rem;
    margin-bottom: 10px;
    font-weight: 600;
}

/* Rating Section */
.rating-section {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
}

.stars {
    display: flex;
    gap: 2px;
}

.star {
    font-size: 1.2rem;
    color: #ddd;
}

.star.filled {
    color: #f39c12;
}

.star.half {
    background: linear-gradient(90deg, #f39c12 50%, #ddd 50%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.rating-text {
    font-size: 0.9rem;
    color: #666;
    font-weight: 500;
}

.service-description {
    color: #666;
    font-size: 1rem;
    line-height: 1.6;
    margin-bottom: 20px;
    flex-grow: 1;
}

/* Service Features */
.service-features {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 25px;
}

.feature {
    background: #ecf0f1;
    color: #2c3e50;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.9rem;
    font-weight: 500;
}

/* Contact Section */
.contact-section {
    border-top: 1px solid #ecf0f1;
    padding-top: 20px;
}

.contact-btn {
    background: linear-gradient(135deg, #27ae60, #229954);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 8px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 100%;
    margin-bottom: 10px;
}

.contact-btn:hover {
    background: linear-gradient(135deg, #229954, #1e8449);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(39, 174, 96, 0.3);
}

.contact-info {
    color: #7f8c8d;
    font-size: 0.9rem;
    font-style: italic;
    text-align: center;
}

/* About Section */
.about-bismarck {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin-bottom: 40px;
}

.about-bismarck h2 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 20px;
    border-bottom: 3px solid #3498db;
    padding-bottom: 10px;
}

.about-bismarck h3 {
    color: #34495e;
    font-size: 1.5rem;
    margin: 30px 0 15px 0;
}

.about-bismarck p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
    margin-bottom: 20px;
}

.about-bismarck ul {
    list-style: none;
    padding-left: 0;
}

.about-bismarck li {
    padding: 10px 0;
    border-bottom: 1px solid #ecf0f1;
    font-size: 1rem;
    line-height: 1.6;
}

.about-bismarck li:last-child {
    border-bottom: none;
}

.about-bismarck li strong {
    color: #2c3e50;
}

/* Service Areas */
.service-areas {
    background: white;
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.1);
    margin-bottom: 40px;
}

.service-areas h2 {
    color: #2c3e50;
    font-size: 2rem;
    margin-bottom: 20px;
    border-bottom: 3px solid #3498db;
    padding-bottom: 10px;
}

.service-areas p {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #555;
    margin-bottom: 25px;
}

.areas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
}

.areas-grid span {
    background: #ecf0f1;
    padding: 12px 20px;
    border-radius: 8px;
    text-align: center;
    font-weight: 500;
    color: #2c3e50;
    transition: background-color 0.3s ease;
}

.areas-grid span:hover {
    background: #d5dbdb;
}

/* Footer */
footer {
    background: #2c3e50;
    color: white;
    text-align: center;
    padding: 40px 20px;
    margin-top: 50px;
}

footer p {
    margin-bottom: 10px;
}

footer small {
    opacity: 0.8;
}

footer .admin-access {
    margin-top: 10px;
    font-size: 0.8rem;
    opacity: 0.6;
}

footer kbd {
    background: rgba(255,255,255,0.2);
    padding: 2px 4px;
    border-radius: 3px;
    font-size: 0.8rem;
}

/* Stats Modal */
.stats-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(5px);
}

.stats-modal-content {
    background-color: white;
    margin: 5% auto;
    border-radius: 15px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    overflow: hidden;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-50px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.stats-header {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.stats-header h2 {
    margin: 0;
    font-size: 1.5rem;
}

.close-stats {
    font-size: 2rem;
    cursor: pointer;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.close-stats:hover {
    opacity: 1;
}

.stats-body {
    padding: 30px;
}

.total-stats {
    text-align: center;
    margin-bottom: 30px;
    padding: 20px;
    background: linear-gradient(135deg, #27ae60, #229954);
    border-radius: 10px;
    color: white;
}

.total-clicks-display span {
    display: block;
    font-size: 3rem;
    font-weight: bold;
    margin-bottom: 5px;
}

.total-clicks-display label {
    font-size: 1.1rem;
    opacity: 0.9;
}

.companies-stats {
    max-height: 300px;
    overflow-y: auto;
}

.stats-company-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px;
    margin-bottom: 10px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #3498db;
}

.stats-company-info h4 {
    margin: 0 0 5px 0;
    color: #2c3e50;
    font-size: 1.1rem;
}

.stats-company-info .last-click-time {
    font-size: 0.85rem;
    color: #666;
}

.stats-click-count {
    text-align: right;
}

.stats-click-number {
    font-size: 1.8rem;
    font-weight: bold;
    color: #e74c3c;
    display: block;
}

.stats-click-label {
    font-size: 0.8rem;
    color: #666;
}

.stats-footer {
    padding: 20px;
    background: #f8f9fa;
    text-align: center;
    border-top: 1px solid #dee2e6;
}

.stats-btn {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 6px;
    margin: 0 5px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.stats-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(52, 152, 219, 0.3);
}

.stats-btn.danger {
    background: linear-gradient(135deg, #e74c3c, #c0392b);
}

.stats-btn.danger:hover {
    box-shadow: 0 5px 15px rgba(231, 76, 60, 0.3);
}

/* Responsive Design */
@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }

    .subtitle {
        font-size: 1rem;
    }

    .service-card {
        grid-template-columns: 1fr;
        grid-template-rows: auto auto 1fr;
    }

    .rank {
        width: 100%;
        height: 60px;
        flex-direction: row;
        justify-content: center;
    }

    .service-image {
        height: 200px;
    }

    .service-content {
        padding: 20px;
    }

    .intro, .about-bismarck, .service-areas {
        padding: 25px;
    }

    .intro h2, .about-bismarck h2, .service-areas h2 {
        font-size: 1.6rem;
    }

    .areas-grid {
        grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
        gap: 10px;
    }
}

@media (max-width: 480px) {
    main {
        padding: 0 15px;
    }

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

    .service-content h3 {
        font-size: 1.5rem;
    }

    .contact-btn {
        padding: 12px 20px;
        font-size: 1rem;
    }
}