@charset "utf-8";

*, *::before, *::after {
    box-sizing: border-box;
}

html, body {
    background: #666633;
    width: 100%;
    height: 100%;
    margin: 0px;
    padding: 0px;
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    color: #cccccc;
}

table#main {
    max-width: 800px;
    width: 100%;
    height: 100%;
    border-width: 0px;
}

td#header {
    height: 100px;
    color: #cccccc;
}

td#navigation {
    height: 50px;
    color: #cccccc;
}

td#container {
    color: #cccccc;
}

td#footer {
    height: 50px;
    color: #cccccc;
}

a {color: #ffffff; text-decoration: none;}
a:link {color: #ffffff; text-decoration: none;}
a:visited {color: #ffffff; text-decoration: none;}
a:active {color: #770000; text-decoration: none;}
a:hover {color: #770000; text-decoration: none;}

.logo {
    background-color: #CCCC99;
    color: #333333;
    font-size: 11px;
}

.unixdate {
    color: #222222;
    font-style: italic;
}

.highlight {
    background: #ffff00;
    color: #222222;
}
.title {
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 16px;
    font-weight: bold;
    color: #000000;
}
.subTitle {
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 14px;
    font-weight: bold;
    color: #000000;
}
.listTitle {
    background-color: #000000;
    font-family: Verdana, Arial, Helvetica, sans-serif;
    font-size: 12px;
    font-weight: bold;
    color: #FFFFFF;
}

/* Responsive: generated images */
img {
    max-width: 100%;
    height: auto;
}

/* Search form — modern panel layout */
.search-form {
    width: 100%;
}

.search-form-table {
    display: flex;
    align-items: stretch;
    gap: 0;
    width: 100%;
    background: rgba(0, 0, 0, 0.35);
    border: 1px solid rgba(204, 204, 153, 0.25);
    border-radius: 6px;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4), inset 0 1px 0 rgba(204, 204, 153, 0.08);
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.search-form-table:focus-within {
    border-color: rgba(204, 204, 153, 0.55);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5), 0 0 0 2px rgba(204, 204, 153, 0.12);
}

.search-form-main {
    flex: 1 1 auto;
    min-width: 0;
}

.search-textarea {
    display: block;
    width: 100%;
    min-height: 110px;
    padding: 14px 16px;
    background: transparent;
    border: none;
    outline: none;
    resize: vertical;
    color: #cccccc;
    font-family: 'Courier New', Courier, monospace;
    font-size: 14px;
    line-height: 1.6;
    caret-color: #CCCC99;
    transition: color 0.15s ease;
}

.search-textarea::placeholder {
    color: rgba(204, 204, 204, 0.38);
    font-style: italic;
}

.search-textarea:focus {
    color: #e8e8d0;
}

/* Divider between textarea and controls panel */
.search-form-controls {
    flex: 0 0 auto;
    width: 210px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 14px 14px 14px 14px;
    background: rgba(0, 0, 0, 0.25);
    border-left: 1px solid rgba(204, 204, 153, 0.18);
}

/* .search-fieldset kept as alias for .search-form-controls (media queries reference it) */
.search-fieldset {
    /* intentionally empty — class alias handled above */
}

.search-controls-label {
    display: block;
    font-family: 'Courier New', Courier, monospace;
    font-size: 10px;
    font-weight: bold;
    letter-spacing: 0.12em;
    color: rgba(204, 204, 153, 0.6);
    text-transform: uppercase;
    padding-bottom: 2px;
    border-bottom: 1px solid rgba(204, 204, 153, 0.15);
}

.search-select {
    width: 100%;
    padding: 7px 10px;
    background: rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(204, 204, 153, 0.22);
    border-radius: 4px;
    color: #cccccc;
    font-family: 'Courier New', Courier, monospace;
    font-size: 12px;
    cursor: pointer;
    appearance: none;
    -webkit-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23CCCC99' fill-opacity='0.5'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 9px center;
    padding-right: 26px;
    transition: border-color 0.15s ease, background-color 0.15s ease;
}

.search-select:focus {
    outline: none;
    border-color: rgba(204, 204, 153, 0.55);
    background-color: rgba(0, 0, 0, 0.55);
}

.search-select:hover {
    border-color: rgba(204, 204, 153, 0.4);
}

.search-select option {
    background: #333320;
    color: #cccccc;
}

.search-submit {
    width: 100%;
    margin-top: auto;
    padding: 9px 12px;
    background: #CCCC99;
    border: none;
    border-radius: 4px;
    color: #2a2a18;
    font-family: 'Courier New', Courier, monospace;
    font-size: 12px;
    font-weight: bold;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    cursor: pointer;
    transition: background-color 0.15s ease, transform 0.1s ease, box-shadow 0.15s ease;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

.search-submit:hover {
    background: #e0e0b0;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.45);
    transform: translateY(-1px);
}

.search-submit:active {
    background: #b8b878;
    transform: translateY(0);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}

/* Responsive: override hardcoded HTML width attributes on inner tables */
td#header table,
td#navigation table {
    width: 100% !important;
}

/* Responsive: header spacer columns shrink on small screens */
td#header table td:first-child,
td#header table td:last-child,
td#navigation table td:first-child,
td#navigation table td:last-child {
    width: 40px;
}

/* Mobile: screens narrower than 600px */
@media screen and (max-width: 600px) {
    table#main {
        padding: 0 8px;
    }

    /* Stack textarea and controls vertically */
    .search-form-table {
        flex-direction: column;
    }
    .search-form-main {
        width: 100%;
    }
    .search-form-controls {
        width: 100% !important;
        flex-direction: row;
        flex-wrap: wrap;
        align-items: center;
        gap: 8px;
        border-left: none;
        border-top: 1px solid rgba(204, 204, 153, 0.18);
    }
    .search-controls-label {
        width: 100%;
        border-bottom: none;
        padding-bottom: 0;
    }
    .search-select {
        flex: 1 1 auto;
    }
    .search-submit {
        flex: 0 0 auto;
        width: auto;
        margin-top: 0;
        padding: 9px 20px;
    }
    .search-textarea {
        width: 100% !important;
        min-height: 90px;
    }
    .search-fieldset {
        width: 100% !important;
    }

    /* Remove header padding columns */
    td#header table td:first-child,
    td#header table td:last-child,
    td#navigation table td:first-child,
    td#navigation table td:last-child {
        display: none;
    }

    /* Search results: hide domain column, keep title and date readable */
    td.col-domain {
        display: none;
    }
    td.col-date {
        width: auto !important;
        white-space: nowrap;
        font-size: 11px;
    }

    /* Prevent results table overflow */
    table.results-table {
        table-layout: fixed;
        width: 100% !important;
        word-break: break-word;
    }
}

/* Tablet: screens between 601px and 800px */
@media screen and (min-width: 601px) and (max-width: 800px) {
    table#main {
        padding: 0 12px;
    }

    td#header table td:first-child,
    td#header table td:last-child,
    td#navigation table td:first-child,
    td#navigation table td:last-child {
        width: 20px;
    }

    td.col-domain {
        width: 110px !important;
    }
    td.col-date {
        width: 100px !important;
    }
}