@import url('common.css');

/* Hero Section */
.hero {
    position: relative;
    min-height: 80vh;
    padding: 4rem 0;
    background: url('../images/21.jpeg') center/cover no-repeat;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('../images/21.jpeg') center/cover no-repeat;
    filter: blur(8px);
    transform: scale(1.1);
    z-index: 1;
    pointer-events: none;
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.3);
    z-index: 2;
    pointer-events: none;
}

.hero-wrapper {
    position: relative;
    z-index: 3;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
    min-height: 60vh;
}

.hero-image {
    position: relative;
    z-index: 4;
}

.hero-image img {
    width: 100%;
    height: auto;
    max-width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
    animation: fadeInLeft 1s ease-out;
}

.hero-content {
    position: relative;
    z-index: 4;
    color: var(--white);
    text-align: left;
    pointer-events: auto;
}

.hero-title {
    font-size: 3rem;
    margin-bottom: 1.5rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    animation: fadeInRight 1s ease-out;
    color: var(--white);
}

.hero-description {
    font-size: 1.2rem;
    line-height: 1.8;
    margin-bottom: 2rem;
    color: var(--white);
    text-shadow: 1px 1px 2px rgba(0,0,0,0.5);
    animation: fadeInRight 1s ease-out 0.2s both;
}

.btn-cta {
    font-size: 1.2rem;
    padding: 1rem 2.5rem;
    animation: fadeInRight 1s ease-out 0.4s both;
    position: relative;
    z-index: 5;
    pointer-events: auto;
}

@keyframes fadeInLeft {
    from {
        opacity: 0;
        transform: translateX(-30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInRight {
    from {
        opacity: 0;
        transform: translateX(30px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Mini Game Section */
.mini-game-section {
    padding: 4rem 0;
    position: relative;
}

.section-title {
    text-align: center;
    font-size: 2.75rem;
    margin-bottom: 3rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 800;
    letter-spacing: -1px;
}

.mini-game-container {
    max-width: 600px;
    margin: 0 auto;
    padding: 2.5rem;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.mini-maze {
    text-align: center;
}

.maze-info {
    margin-bottom: 1rem;
    color: var(--dark-gray);
    font-size: 0.9rem;
}

.round-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.75rem;
    font-weight: 600;
}

.round-label {
    color: var(--secondary-color);
}

.round-number {
    color: var(--primary-color);
    font-size: 1.2rem;
    min-width: 30px;
    text-align: center;
}

.desktop-instruction {
    display: block;
}

.mobile-instruction {
    display: none;
}

.maze-grid {
    display: grid;
    gap: 2px;
    background-color: var(--text-color);
    border: 2px solid var(--text-color);
    max-width: 450px;
    margin: 0 auto 1.5rem;
    aspect-ratio: 1;
}

.maze-cell {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    transition: all 0.2s;
}

.maze-cell.wall {
    background-color: var(--secondary-color);
}

.maze-cell.path {
    background-color: var(--white);
}

.maze-cell.player {
    background-color: var(--primary-color);
    border-radius: 50%;
    position: relative;
}

.maze-cell.player::after {
    content: '';
    width: 60%;
    height: 60%;
    background-color: var(--white);
    border-radius: 50%;
}

.maze-cell.exit {
    background-color: var(--success-color);
    border-radius: 50%;
}

.maze-cell.exit::after {
    content: '';
    width: 70%;
    height: 70%;
    background-color: var(--white);
    border-radius: 2px;
}

.maze-controls {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.maze-status {
    min-height: 1.5rem;
    color: var(--success-color);
    font-weight: 500;
    font-size: 1.1rem;
}

/* Mobile Controls */
.mobile-controls {
    display: none;
    margin: 1.5rem auto;
    max-width: 200px;
}

.control-row {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.control-btn {
    width: 60px;
    height: 60px;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    border-radius: 10px;
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.15s;
    box-shadow: 0 3px 10px rgba(0,0,0,0.2);
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
    display: flex;
    align-items: center;
    justify-content: center;
}

.control-btn:active {
    transform: scale(0.9);
    background-color: #357abd;
    box-shadow: 0 1px 5px rgba(0,0,0,0.2);
}

.control-btn:hover {
    background-color: #357abd;
}

.control-btn:focus {
    outline: 2px solid var(--white);
    outline-offset: 2px;
}

.btn-reset {
    padding: 0.75rem 2rem;
    background-color: var(--accent-color);
    color: var(--white);
    border: none;
    border-radius: 5px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.3s;
}

.btn-reset:hover {
    background-color: #c0392b;
}

/* Main Content */
.main-content {
    padding: 4rem 0;
}

.description-section {
    text-align: center;
    margin-bottom: 4rem;
    padding: 3rem;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.description-text {
    font-size: 1.2rem;
    line-height: 1.8;
    color: var(--text-color);
}

.description-text strong {
    color: var(--primary-color);
    font-size: 1.3rem;
}

/* Benefits Section */
.benefits-section {
    margin-bottom: 4rem;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.benefit-card {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    padding: 0;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.benefit-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.2);
    border-color: rgba(255, 255, 255, 0.5);
}

.benefit-image {
    width: 100%;
    height: 200px;
    overflow: hidden;
    background-color: var(--light-gray);
    display: block;
    position: relative;
}

.benefit-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
    display: block;
}

.benefit-card:hover .benefit-image img {
    transform: scale(1.05);
}

.benefit-card h3 {
    color: var(--secondary-color);
    margin: 1.5rem 1.5rem 1rem;
}

.benefit-card p {
    color: var(--dark-gray);
    line-height: 1.6;
    padding: 0 1.5rem 1.5rem;
    margin: 0;
}

/* How It Works Section */
.how-it-works-section {
    margin-bottom: 4rem;
    padding: 3rem;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.step-card {
    background: rgba(255, 255, 255, 0.7);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
    position: relative;
}

.step-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    background: rgba(255, 255, 255, 0.9);
}

.step-number {
    width: 60px;
    height: 60px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    font-weight: bold;
    margin: 0 auto 1rem;
}

.step-card h3 {
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.step-card p {
    color: var(--dark-gray);
    line-height: 1.6;
}

/* Statistics Section */
.statistics-section {
    padding: 4rem 3rem;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    margin-bottom: 4rem;
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.statistics-section .section-title {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.stat-card {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    padding: 2rem;
    border-radius: 16px;
    text-align: center;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
    background: rgba(255, 255, 255, 0.95);
}

.stat-number {
    font-size: 3rem;
    font-weight: bold;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 1.1rem;
    color: var(--dark-gray);
    font-weight: 500;
}

/* Registration Section */
.registration-section {
    text-align: center;
    padding: 4rem 3rem;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 20px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: var(--text-color);
}

.registration-box h2 {
    font-size: 2.75rem;
    margin-bottom: 1rem;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    font-weight: 800;
}

.registration-box p {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: var(--text-color);
}

/* Fade In Animation */
.fade-in {
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Responsive Design */
@media (max-width: 968px) {
    .hero-wrapper {
        grid-template-columns: 1fr;
        gap: 2rem;
        text-align: center;
    }

    .hero-content {
        text-align: center;
    }

    .hero-image {
        order: 2;
    }

    .hero-content {
        order: 1;
    }
}

@media (max-width: 768px) {
    .hero {
        padding: 2rem 0;
        min-height: auto;
    }

    .hero-wrapper {
        min-height: auto;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-description {
        font-size: 1rem;
    }

    .section-title {
        font-size: 2rem;
    }

    .benefits-grid,
    .steps-grid,
    .stats-grid {
        grid-template-columns: 1fr;
    }

    .registration-box h2 {
        font-size: 2rem;
    }

    .maze-grid {
        max-width: 100%;
        max-width: 350px;
    }

    .maze-cell.player::after {
        width: 50%;
        height: 50%;
    }

    .maze-cell.exit::after {
        width: 60%;
        height: 60%;
    }

    .desktop-instruction {
        display: none;
    }

    .mobile-instruction {
        display: block;
    }

    .mobile-controls {
        display: block;
    }

    .mini-game-container {
        padding: 1.5rem;
    }

    .maze-info {
        font-size: 0.85rem;
    }

    .stat-number {
        font-size: 2.5rem;
    }
}

@media (max-width: 480px) {
    .maze-grid {
        max-width: 100%;
        max-width: 300px;
    }

    .control-btn {
        width: 55px;
        height: 55px;
        font-size: 1.4rem;
    }

    .control-row {
        gap: 0.4rem;
    }

    .mobile-controls {
        max-width: 180px;
    }

    .mini-game-container {
        padding: 1rem;
    }

    .maze-info {
        font-size: 0.8rem;
        margin-bottom: 0.75rem;
    }
}

