/* Reset */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
}

/* Grid Layout */
.grid-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    grid-template-rows: 1fr 1fr;
    height: calc(100vh - 60px);
    position: relative;
}

/* Divider lines */
.grid-container::before,
.grid-container::after {
    content: "";
    position: absolute;
    background: white;
    z-index: 10;
}

/* Vertical line */
.grid-container::before {
    width: 3px;
    height: 100%;
    left: 50%;
    top: 0;
    transform: translateX(-50%);
}

/* Horizontal line */
.grid-container::after {
    height: 3px;
    width: 100%;
    top: 50%;
    left: 0;
    transform: translateY(-50%);
}

/* Buttons (now links) */
.grid-btn {
    position: relative;
    text-decoration: none;
    overflow: hidden;

    background-size: cover;
    background-position: center;

    display: flex;
    align-items: center;
    justify-content: center;
}

/* Overlay */
.grid-btn::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.4);
    transition: 0.3s;
}

/* Text */
.grid-btn span {
    position: relative;
    color: white;
    font-size: 2.2rem;
    font-weight: bold;
    z-index: 1;
    text-transform: uppercase;
    letter-spacing: 2px;
}

/* Hover effect */
.grid-btn:hover::after {
    background: rgba(0,0,0,0.2);
}

/* Background images */
.btn1 { background-image: url("https://picsum.photos/800/800?random=1"); }
.btn2 { background-image: url("https://picsum.photos/800/800?random=2"); }
.btn3 { background-image: url("https://picsum.photos/800/800?random=3"); }
.btn4 { background-image: url("https://picsum.photos/800/800?random=4"); }

/* Footer */
.footer {
    position: fixed;
    bottom: 0;
    width: 100%;
    height: 60px;
    background: #222;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 25px;
}

.footer a {
    color: white;
    font-size: 1.5rem;
    transition: 0.3s;
}

.footer a:hover {
    color: #1da1f2;
}

/* ========================= */
/* 📱 Mobile Optimization */
/* ========================= */
@media (max-width: 768px) {
    .grid-container {
        grid-template-columns: 1fr;
        grid-template-rows: repeat(4, 1fr);
        height: auto;
    }

    /* Remove divider lines on mobile */
    .grid-container::before,
    .grid-container::after {
        display: none;
    }

    .grid-btn {
        height: 25vh; /* each takes 1/4 screen height */
    }

    .grid-btn span {
        font-size: 1.5rem;
    }

    .footer {
        height: 50px;
    }
}