/* Reset default styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Body */
body {
    font-family: Roboto, Arial, sans-serif;
    background-color: #304d6d;
    color: #a6caec;
    line-height: 1.6;
}

/* Header */
header {
    margin: 10px;
    text-align: center;
}

.header-content {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 10px;
}

.logo {
    height: auto;
    max-width: 95%;
}

/* Navbar */
.navbar {
    background-color: #a7cced;
    padding: 10px;
    text-align: center;
    display: flex;
    justify-content: center;
    margin-bottom: 0;
}

.navbar a {
    font-size: 16px;
    color: #304d6d;
    text-decoration: none;
    margin: 0 10px;
    padding: 10px 15px;
    border-radius: 5px;
    transition: background-color 0.3s ease;
    flex-grow: 1;
}

.navbar a:hover,
.navbar a.active {
    background-color: #545e75;
    color: white;
}

/* Subnav */
.subnav {
    position: relative;
    display: flex;
}

.subnavbtn {
    font-size: 16px;
    color: #304d6d;
    padding: 10px 15px;
    background-color: inherit;
    border: none;
    outline: none;
    cursor: pointer;
    border-radius: 5px;
    transition: background-color 0.3s ease;
}

.subnav:hover .subnavbtn {
    background-color: #63adf2;
    color: black;
}

.subnav-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background-color: #63adf2;
    width: 100%;
    z-index: 1;
    box-shadow: 0px 8px 16px 0px rgba(0, 0, 0, 0.2);
    border-radius: 5px;
}

.subnav:hover .subnav-content {
    display: block;
}

.subnav-content a {
    color: white;
    padding: 10px 15px;
    text-decoration: none;
    display: block;
    transition: background-color 0.3s ease;
}

.subnav-content a:hover {
    background-color: #545e75;
}

/* Main (3-block structure) */
main {
    margin-top: 10px;
    padding: 0 10px;
    display: flex;
    flex-wrap: nowrap; /* Keep blocks side-by-side */
    justify-content: space-between;
    max-width: 1200px;
    margin-left: auto;
    margin-right: auto;
}

/* Block 1: Left Ad */
#ad-left {
    width: 20%; /* Fixed width for ads */
    min-width: 160px;
    margin: 0;
}

/* Block 2: Center Content */
.center-content {
    flex: 1; /* Takes remaining space */
    max-width: 600px; /* Matches tool width */
    margin: 0 20px; /* Space between ads and content */
}

/* Block 3: Right Ad */
#ad-right1 {
    width: 20%;
    min-width: 160px;
    margin: 0;
}

#ad-left ins, #ad-right1 ins {
    display: block;
}

/* Intro Section */
.intro {
    background-color: #3b5978;
    padding: 20px;
    border-radius: 5px;
    margin-bottom: 20px;
}

.intro h3 {
    color: #a6caec;
    margin-bottom: 10px;
}

.intro p {
    color: #a6caec;
    margin-bottom: 15px;
}

.qr-code {
    max-width: 150px;
    height: auto;
    margin: 10px auto;
    display: block;
}

/* Services Section */
.services {
    padding: 20px 0;
}

.services h2 {
    color: #a6caec;
    margin-bottom: 20px;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.service-item {
    background-color: #4975a4;
    border: 1px solid #cccccc;
    border-radius: 10px;
    padding: 15px;
    transition: transform 0.3s;
}

.service-item:hover {
    transform: scale(1.05);
}

.service-item img {
    max-width: 60%;
    height: auto;
    border-radius: 5px;
}

.service-item h3 {
    color: #a6caec;
    margin: 10px 0;
}

.service-item p {
    color: #a6caec;
}

/* Tool Section */
.tool-section {
    margin: 20px 0;
}

#calculator, #dns-lookup, #scanner, #ip-details, #port-scanner, #whois-lookup, #traceroute, #ping-tool, #ssl-checker, #headers-inspector {
    width: 100%; /* Full width of center block */
    padding: 20px;
    border: 1px solid #cccccc;
    border-radius: 5px;
    background-color: #3b5978;
    margin-bottom: 20px;
}

.tool-section h2 {
    color: #a6caec;
    margin-bottom: 15px;
}

.tool-section label {
    display: block;
    margin: 10px 0 5px;
    color: #a6caec;
}

.tool-section input[type="text"] {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #cccccc;
    border-radius: 5px;
    box-sizing: border-box;
}

.tool-section button {
    background-color: #4CAF50;
    color: white;
    padding: 10px 20px;
    margin: 10px 0;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
}

#results, #scan-results, #ip-results, #port-results, #whois-results, #trace-results, #ping-results, #ssl-results, #header-results {
    margin-top: 20px;
    font-family: monospace;
    white-space: pre-wrap;
    color: #a6caec;
    border: 1px solid #cccccc;
    padding: 15px;
    min-height: 100px;
    background-color: #222d3d;
    font-size: 14px;
    line-height: 1.6;
    width: 100%;
}

/* Spinner */
.spinner {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid #a6caec;
    border-top: 3px solid #4CAF50;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    vertical-align: middle;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Footer */
footer {
    text-align: center;
    padding: 20px 0;
    background-color: #3b5978;
    color: #a6caec;
    width: 100%;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    main {
        flex-direction: column;
        padding: 0 5px;
    }

    #ad-left, #ad-right1 {
        width: 100%;
        margin: 10px 0;
    }

    .center-content {
        margin: 0;
        max-width: 100%;
    }

    .navbar {
        flex-direction: column;
        padding: 5px;
    }

    .navbar a, .subnav {
        display: block;
        width: 100%;
        margin: 5px 0;
    }

    .subnav-content {
        position: relative;
        top: 0;
        width: 100%;
    }

    .intro, .tool-section {
        width: 100%;
    }

    .services-grid {
        grid-template-columns: 1fr;
    }
}

/* Add to existing styles.css */

/* Team Grid (about.html) */
.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    padding: 20px;
}

.team-member {
    background-color: #4975a4;
    border: 1px solid #cccccc;
    border-radius: 10px;
    padding: 15px;
    text-align: center;
}

.team-member img {
    max-width: 60%;
    height: auto;
    border-radius: 5px;
}

.team-member h3 {
    color: #a6caec;
    margin: 10px 0;
}

.team-member p {
    color: #a6caec;
}

/* Contact Section (contact.html) */
.contact-section {
    text-align: center;
    padding: 20px;
    background-color: #4975a4;
    border-radius: 10px;
}

.contact-section a {
    color: #a6caec;
    text-decoration: none;
}

.contact-section a:hover {
    color: #63adf2;
}

/* Tech Tips Section (techtips.html) */
.techtips-section .tip {
    background-color: #4975a4;
    border: 1px solid #cccccc;
    border-radius: 10px;
    padding: 15px;
    margin-bottom: 20px;
    text-align: left;
}

.techtips-section h3 {
    color: white;
    margin-bottom: 10px;
}

.techtips-section p {
    color: white;
}
/* Careers Section (careers.html) */
.careers-section {
    text-align: center;
    padding: 20px;
    background-color: #4975a4;
    border-radius: 10px;
}

.careers-section h2 {
    color: white;
    margin-bottom: 15px;
}

.careers-section p {
    color: white;
    margin-bottom: 20px;
}

.careers-section a {
    color: white;
    text-decoration: none;
}

.careers-section a:hover {
    color: #63adf2;
}

.benefits-list {
    list-style: none;
    padding: 0;
    text-align: left;
    display: inline-block;
}

.benefits-list li {
    margin: 10px 0;
    color: white;
}

#dns-lookup {
    width: 100%; /* Full width of center block */
    padding: 20px;
    border: 1px solid #cccccc;
    border-radius: 5px;
    background-color: #3b5978;
    margin-bottom: 20px;
}


#results {
    margin-top: 20px;
    font-family: monospace;
    white-space: pre-wrap;
    color: #a6caec;
    border: 1px solid #cccccc;
    padding: 15px;
    min-height: 100px;
    background-color: #222d3d;
    font-size: 14px;
    line-height: 1.6;
    width: 100%;
}

.tool-section h2 {
    color: white;
    text-align: center;
    margin-bottom: 15px;
}

.tool-section label {
    display: block;
    margin: 10px 0 5px;
    color: white;
}

.tool-section input[type="text"] {
    width: 100%;
    padding: 10px;
    margin: 10px 0;
    border: 1px solid #cccccc;
    border-radius: 5px;
    box-sizing: border-box;
}

.tool-section button {
    background-color: #4CAF50;
    color: white;
    padding: 10px 20px;
    margin: 10px 0;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    width: 100%;
}


#scanner {
    width: 100%;
    padding: 20px;
    border: 1px solid #cccccc;
    border-radius: 5px;
    background-color: #3b5978;
    margin-bottom: 20px;
}

#scan-results {
    margin-top: 20px;
    font-family: monospace;
    white-space: pre-wrap;
    color: #a6caec;
    border: 1px solid #cccccc;
    padding: 15px;
    min-height: 100px;
    background-color: #222d3d;
    font-size: 14px;
    line-height: 1.6;
    width: 100%;
}