.container {
    width: 90%;
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
    text-align: center;
    position: relative;
}

.container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image:
        linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
    background-size: 20px 20px;
    pointer-events: none;
    z-index: 0;
}

h1 {
    font-size: 2.5rem;
    margin-bottom: 30px;
    font-weight: 700;
    background: linear-gradient(45deg, #4ade80, #22d3ee);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}


.stats-container {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.stat-circle {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    position: relative;
    background-color: rgba(10, 25, 41, 0.7);
    border: 2px solid transparent;
}


.stat-circle.effective-clicks {
    border-color: #d8b4fe;
    background: linear-gradient(rgba(10, 25, 41, 0.7), rgba(10, 25, 41, 0.7)) padding-box,
        linear-gradient(45deg, #d8b4fe, #8b5cf6) border-box;
}

.stat-circle.total-clicks {
    border-color: #fde68a;
    background: linear-gradient(rgba(10, 25, 41, 0.7), rgba(10, 25, 41, 0.7)) padding-box,
        linear-gradient(45deg, #fde68a, #f59e0b) border-box;
}

.stat-circle.accuracy {
    border-color: #93c5fd;
    background: linear-gradient(rgba(10, 25, 41, 0.7), rgba(10, 25, 41, 0.7)) padding-box,
        linear-gradient(45deg, #93c5fd, #3b82f6) border-box;
}

.stat-number {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.stat-label {
    font-size: 0.85rem;
    opacity: 0.8;
}


.timer-container {
    margin-bottom: 20px;
    font-size: 1.5rem;
    font-weight: 600;
}

.timer-label {
    color: #94a3b8;
    margin-right: 10px;
}

.timer-value {
    color: #22d3ee;
    font-size: 1.8rem;
}


.game-board {
    display: flex;
    justify-content: center;
    margin-bottom: 30px;
}

.grid-container {
    display: grid;
    grid-template-columns: repeat(3, 100px);
    grid-template-rows: repeat(3, 100px);
    gap: 2px;
    background-color: #334155;
    padding: 2px;
    border-radius: 8px;
}

.grid-cell {
    width: 100px;
    height: 100px;
    background-color: #0f172a;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
}

.grid-cell:hover {
    background-color: #1e293b;
}

.grid-cell.active {
    background-color: #3b82f6;
    box-shadow: 0 0 15px rgba(59, 130, 246, 0.5);
}


.start-button {
    background: linear-gradient(45deg, #4ade80, #22d3ee);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-bottom: 30px;
    box-shadow: 0 4px 15px rgba(74, 222, 128, 0.4);
}

.start-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(74, 222, 128, 0.6);
}

.start-button:active {
    transform: translateY(-1px);
}

.start-button:disabled {
    background: linear-gradient(45deg, #475569, #334155);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}


.time-options {
    display: flex;
    justify-content: center;
    gap: 10px;
    flex-wrap: wrap;
}

.time-option {
    background-color: #1e293b;
    color: #cbd5e1;
    border: 1px solid #334155;
    padding: 10px 20px;
    border-radius: 25px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 500;
}

.time-option:hover {
    background-color: #334155;
    color: #ffffff;
    border-color: #475569;
}

.time-option.active {
    background-color: #3b82f6;
    color: #ffffff;
    border-color: #3b82f6;
}


.result-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.result-modal.show {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background-color: #0f172a;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    text-align: center;
    position: relative;
    max-width: 400px;
    width: 90%;
    border: 1px solid #334155;
}

.modal-content h2 {
    font-size: 1.8rem;
    margin-bottom: 20px;
    color: #3b82f6;
}

.score-details {
    margin-bottom: 30px;
}

.apm-score {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #4ade80;
}

.apm-score span:first-child {
    margin-right: 10px;
}

.apm-score span:last-child {
    color: #22d3ee;
}

.accuracy-text {
    font-size: 1.1rem;
    color: #94a3b8;
}

.final-accuracy {
    color: #93c5fd;
    font-weight: 600;
}

.share-section {
    margin-bottom: 30px;
}

.share-section p {
    margin-bottom: 15px;
    color: #cbd5e1;
}

.share-buttons {
    display: flex;
    justify-content: center;
    gap: 15px;
}

.share-btn {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    font-weight: bold;
    transition: all 0.3s ease;
}

.share-btn.facebook {
    background-color: #1877f2;
    color: white;
}

.share-btn.instagram {
    background: linear-gradient(45deg, #e1306c, #f56040, #fcaf45, #4267b2);
    color: white;
}

.share-btn.twitter {
    background-color: #1da1f2;
    color: white;
}

.share-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
}

.modal-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.close-button,
.restart-button {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    transition: all 0.3s ease;
}

.close-button {
    background-color: #334155;
    color: #94a3b8;
}

.close-button:hover {
    background-color: #475569;
    color: #ffffff;
}

.restart-button {
    background: linear-gradient(45deg, #4ade80, #22d3ee);
    color: white;
}

.restart-button:hover {
    transform: rotate(90deg);
}


@media (max-width: 768px) {
    .container {
        width: 95%;
        padding: 15px;
    }

    h1 {
        font-size: 2rem;
    }

    .stats-container {
        gap: 20px;
    }

    .stat-circle {
        width: 100px;
        height: 100px;
    }

    .stat-number {
        font-size: 1.5rem;
    }

    .grid-container {
        grid-template-columns: repeat(3, 80px);
        grid-template-rows: repeat(3, 80px);
    }

    .grid-cell {
        width: 80px;
        height: 80px;
    }

    .timer-value {
        font-size: 1.5rem;
    }

    .time-options {
        gap: 8px;
    }

    .time-option {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
}

@media (max-width: 480px) {
    .stat-circle {
        width: 90px;
        height: 90px;
    }

    .stat-number {
        font-size: 1.3rem;
    }

    .stat-label {
        font-size: 0.75rem;
    }

    .grid-container {
        grid-template-columns: repeat(3, 70px);
        grid-template-rows: repeat(3, 70px);
    }

    .grid-cell {
        width: 70px;
        height: 70px;
    }

    .start-button {
        padding: 12px 30px;
        font-size: 1rem;
    }

    .modal-content {
        padding: 30px 20px;
    }

    .modal-content h2 {
        font-size: 1.5rem;
    }

    .apm-score {
        font-size: 1.8rem;
    }
}


.apm-info-container {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
}

.info-section {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 15px;
    padding: 25px;
    margin-bottom: 30px;
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.info-section:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.info-section h2 {
    color: #4caf50;
    margin-bottom: 20px;
    font-size: 1.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.info-section h3 {
    color: #8bc34a;
    margin: 20px 0 10px;
    font-size: 1.3rem;
}

.info-section p {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 15px;
    color: #e0e0e0;
}

.info-section ol {
    margin: 15px 0 15px 30px;
    font-size: 1.1rem;
    line-height: 1.7;
    color: #e0e0e0;
}

.info-section li {
    margin-bottom: 10px;
}


.comparison-container {
    display: flex;
    gap: 20px;
    margin: 20px 0;
}

.comparison-item {
    flex: 1;
    background: rgba(255, 255, 255, 0.08);
    padding: 20px;
    border-radius: 10px;
    transition: transform 0.3s ease, background 0.3s ease;
}

.comparison-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}


.calculation-steps {
    background: rgba(255, 255, 255, 0.08);
    padding: 20px;
    border-radius: 10px;
    margin: 20px 0;
}


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

.importance-item {
    background: rgba(255, 255, 255, 0.08);
    padding: 20px;
    border-radius: 10px;
    transition: transform 0.3s ease, background 0.3s ease;
}

.importance-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}

.importance-item h3 {
    color: #8bc34a;
    margin-bottom: 10px;
}


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

.benchmark-item {
    background: rgba(255, 255, 255, 0.08);
    padding: 20px;
    border-radius: 10px;
    transition: transform 0.3s ease, background 0.3s ease;
}

.benchmark-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}

.benchmark-item h3 {
    color: #8bc34a;
    margin-bottom: 15px;
}

.benchmark-item p {
    margin-bottom: 0;
}

.benchmark-item strong {
    color: #4caf50;
}


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

.tip-item {
    background: rgba(255, 255, 255, 0.08);
    padding: 20px;
    border-radius: 10px;
    transition: transform 0.3s ease, background 0.3s ease;
}

.tip-item:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-5px);
}

.tip-item h3 {
    color: #8bc34a;
    margin-bottom: 10px;
}


@media (max-width: 768px) {
    .apm-info-container {
        padding: 0 15px;
    }

    .info-section {
        padding: 20px 15px;
    }

    .info-section h2 {
        font-size: 1.5rem;
    }

    .info-section h3 {
        font-size: 1.2rem;
    }

    .info-section p,
    .info-section ol {
        font-size: 1rem;
    }

    .comparison-container {
        flex-direction: column;
    }

    .importance-grid,
    .benchmarks-container,
    .improvement-tips {
        grid-template-columns: 1fr;
    }
}