/* ================================
   PAGE LAYOUT
================================ */

/* Serif font for the title */
@import url('https://fonts.googleapis.com/css2?family=Merriweather:wght@700&display=swap');
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;600;700&display=swap');

/* Base Font */
body {
  font-family: 'Inter', sans-serif;
}

/* Main wrapper */
.home-content {
    display: flex;
    gap: 4rem;
    margin: 3rem auto;
    max-width: 1250px;
    justify-content: center;   /* CENTERED */
    align-items: flex-start;
    padding-bottom: 4rem;
}


/* ================================
   CREATE TEST CARD
================================ */
.create-test-card {
    width: 420px;
    background: #fff;
    border: 2px dashed #d4d4d4;
    padding: 2.2rem;
    border-radius: 6px;
    position: relative;
    display: flex;
    flex-direction: column;
}

.create-test-card h2 {
    font-size: 1.45rem;
    margin-bottom: 1rem;
    font-weight: 700;
}

/* Labels */
.create-test-card label {
    display: block;
    font-size: 0.95rem;
    margin-top: 1.1rem;
    font-weight: 600;
}

/* Selects */
.create-test-card select {
    margin-top: 0.35rem;
    padding: 0.45rem 0.65rem;
    border-radius: 6px;
    border: 1px solid #cbd5df;
    background: white;
    font-size: 0.92rem;
}

/* Time row */
.time-row {
    display: flex;
    align-items: center;
    gap: 0.45rem;
}

/* Difficulty radio group */
.difficulty-group {
    margin-top: 0.4rem;
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
}

.difficulty-group label {
    font-size: 0.88rem;
    font-weight: 400;
}

/* Toggle Switch */
.toggle {
    position: relative;
    width: 38px;
    height: 20px;
    display: inline-block;
    margin-left: 8px;
}

.toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    background: #bfbfbf;
    border-radius: 20px;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    transition: 0.25s;
}

.slider:before {
    content: "";
    position: absolute;
    height: 14px;
    width: 14px;
    left: 3px;
    top: 3px;
    background: white;
    border-radius: 50%;
    transition: 0.25s;
}

.toggle input:checked + .slider {
    background: #000;
}

.toggle input:checked + .slider:before {
    transform: translateX(18px);
}

/* Create Test Button */
.primary-btn {
    margin-top: 1.3rem;
    background: #000;
    color: white;
    padding: 0.55rem 1.4rem;
    border-radius: 25px;
    border: none;
    font-size: 0.95rem;
    cursor: pointer;
    font-weight: 600;
    transition: 0.2s;
}

.primary-btn:hover {
    background: #333;
}

/* Illustration */
.create-test-illustration {
    margin-top: 1.8rem;
    display: flex;
    justify-content: center;
}

.create-test-illustration img {
    width: 170px;
    height: auto;
}

/* ================================
   RECENT TESTS
================================ */
.recent-tests-card {
    flex: 1;
    margin-top: 0.2rem;
}

.recent-tests-card h2 {
    font-size: 1.45rem;
    font-weight: 700;
    margin-bottom: 1rem;
}

.recent-tests-list {
    display: flex;
    flex-direction: column;
    gap: 1.1rem;
}

.empty-text {
    color: #757575;
    font-size: 0.95rem;
}

/* Test item */
.recent-test-item {
    background: #d8edf4;
    padding: 1rem 1.4rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 2rem;
}

/* Score */
.recent-test-score {
    font-size: 1.55rem;
    font-weight: 700;
}

/* Info set */
.recent-test-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    font-size: 0.85rem;
}

/* Responsive */
@media (max-width: 900px) {
    .home-content {
        flex-direction: column;
        align-items: center;
    }

    .create-test-card {
        width: 100%;
        max-width: 420px;
    }
}


/* Illustration under Create Test */
.create-test-illustration {
    display: flex;
    justify-content: center;
    margin-top: 1.4rem;
}

/* Resize image to match design */
.typing-img {
    width: 180px;
    height: auto;
    object-fit: contain;
    display: block;
    margin-top: 0.8rem;
}
