/* Reset and Box Sizing */
* {
    padding: 0;
    margin: 1;
    box-sizing: border-box;
}

body {
    font-family: 'Arial', sans-serif;
    font-size: 14px; /* Smaller font for classy look */
    background-color: #f9f9f9;
    color: #333; /* Body font color preserved */
}

/* Header */
header {
    text-align: center;
    padding: 10px; /* Smaller header */
    background-color: #2f3a85;
    border-bottom: 1px solid #ddd;
}

#header-content {
    display: flex;
    align-items: center;
    justify-content: center;
}

#logo {
    width: 100px; /* Smaller logo for header */
    height: auto;
    margin-right: 8px;
}

#header-text h1 {
    margin: 0;
    font-size: 20px; /* Smaller header font */
    font-weight: normal;
    font-family: 'Georgia', sans-serif; /* New font for SpeakForMe header */
    color: #fff; /* Matches header background */
}

#header-text p {
    margin: 3px 0 0;
    font-size: 14px;
    color: #f7f4f4;
}

/* Main Content */
main {
    max-width: 1400px; /* Wider for larger table */
    margin: 0 auto;
    padding: 15px;
}

/* Introduction Section */
.intro {
    text-align: center;
    margin-bottom: 20px;
}

.intro p {
    font-size: 15px;
    margin: 5px 0;
}

.intro a {
    color: #007bff;
    text-decoration: none;
}

.intro a:hover {
    text-decoration: underline;
}

/* Form Container */
.form-container {
    background-color: #fff;
    padding: 15px;
    border-radius: 5px;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
}

/* Form Sections */
.form-section {
    margin-bottom: 15px;
}

label {
    display: block;
    margin: 8px 0 4px;
    font-size: 15px;
    font-weight: bold;
}

input[type="text"],
input[type="email"],
input[type="tel"],
textarea,
select {
    width: 100%;
    padding: 6px;
    margin-bottom: 8px;
    border: 1px solid #ddd;
    border-radius: 3px;
    font-size: 15px;
}

textarea {
    height: 80px;
    resize: vertical;
}

input[type="radio"],
input[type="checkbox"] {
    margin-right: 4px;
}

fieldset {
    border: 1px solid #ddd;
    padding: 10px;
    margin-bottom: 10px;
}

legend {
    font-size: 15px;
    font-weight: bold;
}

/* Buttons */
button {
    padding: 8px 16px;
    background-color: #007bff;
    color: #fff;
    border: none;
    border-radius: 3px;
    cursor: pointer;
    font-size: 14px;
}

button:hover {
    background-color:#0056b3;
}

/* File Upload Section */
#fileList {
    list-style: none;
    padding: 0;
}

.file-item {
    display: flex;
    align-items: center;
    margin-bottom: 5px;
    font-size: 14px;
}

.remove-file {
    background: #fff;
    color: #fa0303;
    border: none;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    text-align: center;
    cursor: pointer;
    font-size: 14px;
    line-height: 18px; /* Match line-height to height for vertical centering */
    display: flex; /* Use flex to center the "x" */
    align-items: center;
    justify-content: center;
    margin-left: 8px; /* Optional: space between file name and button */
}

/* Admin Tabs */
#tabs {
    margin-bottom: 20px;
}

#tabs button {
    padding: 8px 16px;
    margin-right: 5px;
    cursor: pointer;
    border: none;
    background-color: #669ec9;
    font-size: 14px;
    border-radius: 5px;
}

#tabs button.active {
    background-color: #0468c0;
    font-weight: bold;
}

#tabs button:hover {
    background-color: #0056b3;
}

/* Admin Table */
table {
    width: 100%;
    max-width: 1400px; /* Larger table */
    margin: 0 auto;
    border-collapse: collapse;
    background-color: #ffffff;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
    font-size: 15px; /* Table font per your update */
}

th, td {
    border: 1px solid #ddd;
    padding: 6px;
    text-align: left;
}

th {
    background-color: #e8ecef;
    font-size: 13px;
}

tr:nth-child(even) {
    background-color: #f9f9f9;
}

.emergency-yes {
    background-color: #ff6666;
    font-weight: bold;
}

.response-yes {
    background-color: #66ff66;
}

.emergency-and-response {
    background-color: #ff9966;
}

.processed {
    opacity: 0.7;
}

.warning {
    background-color: #ffff99;
}

.status-completed {
    color: green;
}

.status-error,
.status-email_failed,
.status-payment_failed {
    color: red;
}

.status-pending {
    color: orange;
}

td[data-tooltip] {
    position: relative;
    cursor: pointer;
}

td[data-tooltip]:hover:after {
    content: attr(data-tooltip);
    position: absolute;
    background: #333;
    color: #fff;
    padding: 4px;
    border-radius: 3px;
    z-index: 10;
    white-space: nowrap;
    font-size: 12px;
}

.copy-btn, .download-btn {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 5px 10px;
    margin-left: 10px;
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
}
.copy-btn:hover, .download-btn:hover {
    background-color: #0056b3;
}
.copy-btn:focus, .download-btn:focus {
    outline: 2px solid #669ec9;
}
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}
th, td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
}
th {
    background-color: #f2f2f2;
    font-weight: bold;
}
#pagination {
    margin-top: 20px;
    text-align: center;
}
#pagination button {
    background-color: #007bff;
    color: white;
    border: none;
    padding: 8px 16px;
    margin: 0 5px;
    cursor: pointer;
    border-radius: 4px;
}
#pagination button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

/* Pagination */
.pagination {
    margin-top: 10px;
    text-align: center;
}

.pagination a {
    margin: 0 5px;
    text-decoration: none;
    color: #007bff;
    font-size: 13px;
}

.pagination a:hover {
    text-decoration: underline;
}

/* Footer */
footer {
    text-align: center;
    padding: 10px;
    margin-top: 20px;
    border-top: 1px solid #ddd;
    background-color: #2f3a85;
    color: #fff;
}

footer p {
    font-size: 11px;
    margin: 0;
}

/* Contact Us Section */
.contact-us {
    margin-bottom: 15px;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    padding: 20px;
    text-align: center;
    align-items: center;
}

.contact-us div {
    font-size: 13px;
}

.contact-us a {
    color: #f7f4f4;
    text-decoration: none;
}

.contact-us a:hover {
    text-decoration: underline;
}

.contact-us img {
    width: 24px;
    height: 24px;
    margin: 0 5px;
    vertical-align: middle;
    transition: transform 0.3s ease;
}

.contact-us img:hover {
    transform: scale(1.2);
}

/* Services Section */
.services {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 20px;
    padding: 20px;
    justify-content: center;
}

.services ul {
    list-style: none;
    padding: 0;
    font-size: 12px;
}

.services li {
    margin-bottom: 8px;
    padding: 10px;
    background: #2f3a85;
    color: #fff;
    border-radius: 5px;
    transition: background 0.3s ease;
}

.services li:hover {
    background: #0056b3;
}

.services strong {
    color: #fff;
}

/* Responsive Design */
@media (max-width: 1024px) {
    main {
        max-width: 100%;
    }

    #header-content {
        flex-direction: column;
        align-items: center;
    }

    #logo {
        width: 80px;
        margin-bottom: 8px;
    }

    #header-text h1 {
        font-size: 18px;
    }

    #header-text p {
        font-size: 12px;
    }

    table {
        max-width: 100%;
    }
}

@media (max-width: 600px) {
    body {
        font-size: 13px;
        margin: 10px;
    }

    header {
        padding: 8px;
    }

    #logo {
        width: 60px;
    }

    #header-text h1 {
        font-size: 16px;
    }

    #header-text p {
        font-size: 11px;
    }

    .form-container {
        padding: 10px;
    }

    input,
    select,
    textarea {
        font-size: 13px;
        padding: 5px;
    }

    button {
        font-size: 13px;
        padding: 6px 12px;
    }

    .contact-us {
        grid-template-columns: 1fr;
    }

    .services {
        grid-template-columns: 1fr;
    }

    table {
        font-size: 13px;
    }

    th, td {
        padding: 5px;
    }
}