/* General Body Styles */
body {
    font-family: 'Inter', Arial, sans-serif;
    margin: 0;
    padding: 20px;
    background-color: #f0f2f5;
    color: #333;
    line-height: 1.6;
}

/* Main Container */
.container {
    max-width: 1200px;
    margin: 20px auto;
    background-color: #ffffff;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    border: 1px solid #e0e0e0;
}

/* Header */
h2 {
    color: #2c3e50;
    text-align: center;
    margin-bottom: 35px;
    font-size: 2.2em;
    font-weight: 700;
    text-shadow: 1px 1px 2px rgba(0,0,0,0.05);
}

/* Search Form */
form {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 40px;
    flex-wrap: wrap; /* Allow wrapping on small screens */
    gap: 15px; /* Space between form elements */
}
form label {
    margin-right: 10px;
    font-weight: 600;
    color: #555;
    font-size: 1.1em;
}
form input[type="text"] {
    padding: 12px 18px;
    border: 1px solid #ccc;
    border-radius: 8px;
    width: 280px;
    font-size: 1.05em;
    transition: all 0.3s ease;
    box-shadow: inset 0 1px 3px rgba(0,0,0,0.06);
}
form input[type="text"]:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.25);
    outline: none;
}
form button {
    padding: 12px 25px;
    background-color: #007bff;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.05em;
    font-weight: 600;
    transition: background-color 0.3s ease, transform 0.2s ease;
    box-shadow: 0 2px 5px rgba(0, 123, 255, 0.2);
}
form button:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 123, 255, 0.3);
}
form button:active {
    transform: translateY(0);
    box-shadow: 0 1px 3px rgba(0, 123, 255, 0.2);
}

/* CAPTCHA Specific Styles */
.captcha-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 15px;
    flex-wrap: wrap;
    justify-content: center;
}
.captcha-container img {
    border: 1px solid #ddd;
    border-radius: 4px;
    vertical-align: middle;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}
.captcha-container input[type="text"] {
    width: 150px; /* Adjust width for captcha input */
}
.captcha-container .refresh-captcha {
    background: none;
    border: none;
    color: #007bff;
    cursor: pointer;
    font-size: 0.9em;
    text-decoration: underline;
    transition: color 0.3s ease;
}
.captcha-container .refresh-captcha:hover {
    color: #0056b3;
}


/* Section Styling */
.info-section {
    background-color: #fdfdfd;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    padding: 25px;
    margin-bottom: 25px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}
.info-section h3 {
    color: #34495e;
    margin-top: 0;
    margin-bottom: 20px;
    font-size: 1.6em;
    border-bottom: 2px solid #e0e0e0;
    padding-bottom: 10px;
}

/* Table Styling */
.data-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
    font-size: 0.95em;
}
.data-table th, .data-table td {
    border: 1px solid #e9ecef;
    padding: 12px 15px;
    text-align: left;
    vertical-align: top;
}
.data-table th {
    background-color: #eef4f9;
    color: #495057;
    font-weight: 600;
    white-space: nowrap; /* Prevent wrapping for headers */
}
.data-table tr:nth-child(even) {
    background-color: #f9fbfd;
}
.data-table tr:hover {
    background-color: #eef2f7;
}

/* Specific Layouts for sections */
.personal-info {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
}
.personal-info div {
    flex: 1 1 45%; /* Allow two columns on wider screens */
    min-width: 280px; /* Minimum width before wrapping */
    background-color: #f8f9fa;
    padding: 15px 20px;
    border-radius: 8px;
    border: 1px solid #dee2e6;
}
.personal-info div strong {
    color: #007bff;
    display: block;
    margin-bottom: 5px;
    font-size: 1.05em;
}

/* Responsive Grid for Blocks */
.score-grids {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Auto-fit columns */
    gap: 25px;
}

/* No Results / Error Messages */
.no-results, .error-message {
    text-align: center;
    padding: 20px;
    border-radius: 8px;
    margin-top: 30px;
    font-size: 1.1em;
    font-weight: 500;
}
.no-results {
    background-color: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}
.error-message {
    background-color: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .container {
        padding: 20px;
        margin: 10px auto;
    }
    form {
        flex-direction: column;
    }
    form input[type="text"], form button {
        width: 100%;
        max-width: 300px; /* Constrain width on mobile */
    }
    .personal-info div {
        flex: 1 1 100%; /* Single column on small screens */
    }
    .data-table th, .data-table td {
        padding: 8px 10px;
        font-size: 0.9em;
    }
    .data-table {
        display: block;
        overflow-x: auto; /* Enable horizontal scroll for tables on small screens */
        white-space: nowrap; /* Prevent content from wrapping in table cells */
    }
    .info-section {
        padding: 15px;
    }
    h2 {
        font-size: 1.8em;
    }
    .info-section h3 {
        font-size: 1.4em;
    }
    .captcha-container {
        flex-direction: column;
    }
    .captcha-container input[type="text"] {
        width: 100%;
        max-width: 200px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 10px;
    }
    .container {
        padding: 15px;
    }
    h2 {
        font-size: 1.6em;
    }
    .info-section h3 {
        font-size: 1.2em;
    }
}
