@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&family=Ubuntu:wght@400;500;700&display=swap');

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    text-decoration: none;
}

html {
    scroll-behavior: smooth;
}

::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #FFFFFF;
}

::-webkit-scrollbar-thumb {
    background: #888;
}

::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* ---------------------------------- Laptops and Desktops ------------------------- */

@media (min-width: 1200px) {

    .max-width {
        max-width: 1800px;
        margin: auto;
    }

    section .title {
        position: relative;
        text-align: center;
        color: #000000;
        font-size: 40px;
        font-weight: 500;
        margin-top: 5%;
        font-family: 'Ubuntu', sans-serif;
    }

    .fre {
        display: flex;
        color: #000000;
        /* Color of Name, and moving text in first page*/
        background-size: cover;
        background-attachment: fixed;
        font-family: 'Ubuntu', sans-serif;
    }

    .fill1 {
        position: relative;
        margin-top: 10%;
        margin-bottom: 10%;
        top: 0%;
        left: 0%;
        transform: translate(-50%, -50%);
        float: left;
    }

    .fill1 {
        position: relative;
        margin-top: 10px;
    }

    .radio-container {
        display: flex;
        align-items: center;
    }

    .form {
        margin-right: 20px;
    }

    input[type="radio"] {
        margin-right: 5px;
    }


    /* .inputs{
    display: flex;
    flex-direction: column;
} */

    /* Matrix Styles */
    .matrix {
        border-collapse: collapse;
        margin: 20px 0;
        font-family: 'Courier New', Courier, monospace;
    }

    .matrix td {
        border: 1px solid #ccc;
        padding: 8px 12px;
        text-align: center;
    }

    .matrix tr:nth-child(even) {
        background-color: #f2f2f2;
    }

    .matrix tr:hover {
        background-color: #e6e6e6;
    }

    /* Improved container layout for large screens */
    .container {
        flex-wrap: nowrap;
        max-width: 1600px;
        margin: 0 auto;
    }

    .simulation-section {
        flex: 2;
    }

    canvas {
        max-width: 100%;
        height: auto;
    }

    .columns-container {
        flex-wrap: nowrap;
    }

}

/* ----------------------------------------- Big Tabs ------------------------------------------ */

@media (max-width: 1200px) and (min-width: 768px) {


    .max-width {
        max-width: 1024px;
        padding: 0 40px;
        margin: auto;
    }

    section .title {
        position: relative;
        text-align: center;
        color: #000000;
        font-size: 40px;
        font-weight: 500;
        margin-top: 10%;
        width: 80%;
        font-family: 'Ubuntu', sans-serif;
    }

    .fre {
        display: flex;
        color: #000000;
        /* Color of Name, and moving text in first page*/
        background-size: cover;
        background-attachment: fixed;
        font-family: 'Ubuntu', sans-serif;
    }

    .fill1 {
        position: relative;
        margin-left: 25%;
        margin-top: 20%;
        top: 0%;
        left: 0%;
        transform: translate(-50%, -50%);
        float: left;
    }

    .form1 {
        position: relative;
        margin-left: -20%;
        margin-top: 30%;
        margin-bottom: 20%;
    }

    .figureLast {
        margin-left: -30%;
    }

    .container {
        flex-wrap: wrap;
    }

    .input-section,
    .output-section {
        flex: 1 0 45%;
    }

    .simulation-section {
        flex: 1 0 100%;
        order: -1;
        margin-bottom: 20px;
    }

    canvas {
        width: 100%;
        max-width: 700px;
        height: auto;
    }

    .columns-container {
        flex-direction: row;
    }

    .center-column {
        flex: 1.5;
    }

}

/* ----------------------------------------- Small Tabs ------------------------------------------ */

@media (max-width: 768px) and (min-width: 720px) {


    .max-width {
        max-width: 1024px;
        padding: 0 40px;
        margin: auto;
    }

    section .title {
        position: relative;
        text-align: center;
        color: #000000;
        font-size: 40px;
        font-weight: 500;
        margin-top: 10%;
        font-family: 'Ubuntu', sans-serif;
    }

    .fre {
        display: flex;
        color: #000000;
        /* Color of Name, and moving text in first page*/
        background-size: cover;
        background-attachment: fixed;
        font-family: 'Ubuntu', sans-serif;
    }

    .fill1 {
        position: relative;
        margin-left: 25%;
        margin-top: 20%;
        top: 0%;
        left: 0%;
        transform: translate(-50%, -50%);
        float: left;
    }

    .form1 {
        position: relative;
        margin-left: 20%;
        margin-top: 30%;
        margin-bottom: 20%;
    }

    .figureLast {
        margin-left: 0%;
    }

    .container {
        flex-direction: column;
    }

    .input-section,
    .output-section,
    .simulation-section {
        flex: 1 0 100%;
        max-width: 100%;
    }

    .simulation-section {
        order: -1;
        margin-bottom: 20px;
    }

    canvas {
        width: 100%;
        max-width: 600px;
        height: auto;
    }

    .columns-container {
        flex-direction: column;
    }

    .left-column,
    .center-column,
    .right-column {
        width: 100%;
        margin: 10px 0;
    }

    .button-container {
        flex-direction: column;
    }

    .action-btn {
        width: 100%;
    }

}

/* ----------------------------------------------- Large Phones ---------------------------------- */

@media (max-width: 720px) and (min-width: 420px) {


    .max-width {
        max-width: 715px;
        padding: 0 40px;
        margin: auto;
    }

    section .title {
        position: relative;
        text-align: center;
        color: #000000;
        font-size: 40px;
        font-weight: 500;
        margin-top: 10%;
        width: 80%;
        font-family: 'Ubuntu', sans-serif;
    }

    .fre {
        display: flex;
        color: #000000;
        /* Color of Name, and moving text in first page*/
        background-size: cover;
        background-attachment: fixed;
        font-family: 'Ubuntu', sans-serif;
    }

    .fill1 {
        position: relative;
        margin-left: 35%;
        margin-top: 20%;
        top: 0%;
        left: 0%;
        transform: translate(-50%, -50%);
        float: left;
    }

    .form1 {
        position: relative;
        margin-left: 20%;
        margin-top: 30%;
        margin-bottom: 20%;
    }

    .figureLast {
        margin-left: 0%;
    }

    .container {
        flex-direction: column;
        padding: 10px;
    }

    .header {
        padding: 15px;
    }

    .input-section,
    .output-section,
    .simulation-section {
        flex: 1 0 100%;
        max-width: 100%;
        padding: 15px;
    }

    .simulation-section {
        order: -1;
    }

    canvas {
        width: 100%;
        max-width: 500px;
        height: auto;
    }

    .columns-container {
        flex-direction: column;
    }

    .left-column,
    .center-column,
    .right-column {
        width: 100%;
        margin: 10px 0;
        padding: 15px;
    }

    button {
        padding: 12px 15px;
        font-size: 16px;
    }

    label {
        font-size: 16px;
    }

    input[type="number"],
    input[type="range"] {
        padding: 12px;
        font-size: 16px;
    }

    .button-container {
        flex-direction: column;
        gap: 10px;
    }

}

/* ------------------------------------- Small Phones ------------------------------------ */

@media (max-width: 420px) {


    .max-width {
        max-width: 460px;
        padding: 0 40px;
        margin: auto;
    }

    section .title {
        position: relative;
        text-align: center;
        color: #000000;
        font-size: 40px;
        font-weight: 500;
        margin-top: 10%;
        width: 80%;
        font-family: 'Ubuntu', sans-serif;
    }

    .fre {
        display: flex;
        color: #000000;
        /* Color of Name, and moving text in first page*/
        background-size: cover;
        background-attachment: fixed;
        font-family: 'Ubuntu', sans-serif;
    }

    .fill1 {
        position: relative;
        margin-left: 30%;
        margin-top: 20%;
        top: 0%;
        left: 0%;
        transform: translate(-50%, -50%);
        float: left;
    }


    .form1 {
        position: relative;
        margin-left: 0%;
        margin-top: 30%;
        margin-bottom: 20%;
    }

    .figureLast {
        margin-left: 0%;
    }

    .max-width {
        padding: 0 15px;
    }

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

    .header {
        padding: 10px;
        margin-bottom: 10px;
    }

    .header h1 {
        font-size: 24px;
    }

    .input-section,
    .output-section,
    .simulation-section {
        flex: 1 0 100%;
        max-width: 100%;
        padding: 10px;
        margin-bottom: 15px;
    }

    .simulation-section {
        order: -1;
    }

    section .title {
        font-size: 28px;
    }

    canvas {
        width: 100%;
        height: auto;
    }

    .columns-container {
        flex-direction: column;
        gap: 10px;
    }

    .left-column,
    .center-column,
    .right-column {
        width: 100%;
        margin: 5px 0;
        padding: 10px;
    }

    .controls,
    .results {
        padding: 10px;
    }

    button {
        padding: 12px;
        font-size: 16px;
        margin-top: 8px;
    }

    .button-container {
        flex-direction: column;
        gap: 8px;
    }

    .action-btn {
        min-width: auto;
        width: 100%;
    }

    input[type="number"],
    input[type="range"] {
        padding: 10px;
        margin: 8px 0;
    }

    label {
        margin-top: 8px;
        font-size: 15px;
    }

}

/* Add a new media query for very small devices */
@media (max-width: 320px) {
    .header h1 {
        font-size: 20px;
    }

    section .title {
        font-size: 24px;
    }

    .input-section,
    .output-section,
    .simulation-section {
        padding: 8px;
    }

    button {
        padding: 10px;
        font-size: 14px;
    }

    .results {
        max-height: 250px;
    }

    .controls,
    .results {
        padding: 8px;
    }
}

/* Global responsive improvements */
@media (hover: none) and (pointer: coarse) {

    /* Better touch targets for mobile devices */
    button,
    input[type="radio"]+label {
        min-height: 44px;
    }

    input[type="range"] {
        height: 30px;
    }
}

/* Improve flexibility of canvas for all screen sizes */
canvas {
    max-width: 100%;
    height: auto;
    margin: 0 auto;
}

/* Make images responsive */
img {
    max-width: 100%;
    height: auto;
}

/* Responsive table improvements */
@media (max-width: 600px) {
    table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
    }

    td,
    th {
        padding: 8px;
    }
}

/* ----------------------------------------- Plot Button -----------------------------------------------------*/

.buttonTotal {
    display: block;
    margin-bottom: 40px;
    font-size: 100%;
    position: relative;
    padding: 10px 20px;
    background-color: #98CB3B;
    color: #FFFFFF;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    white-space: nowrap;
    user-select: none;
    -webkit-user-select: none;
    touch-action: manipulation;
    margin-left: 0%;
    margin-top: 10%;
}

.buttonTotal:hover {
    background-color: #2C9AD1;
    transform: scale(1.05);
}

/* ---------------------------------------------------- Tabs -------------------------------------------- */

.tab {
    overflow: hidden;
    border: 1px solid #FFFFFF;
    background-color: #FFFFFF;
}

/* Style the buttons inside the tab */
.tab button {
    background-color: inherit;
    border: none;
    outline: none;
    cursor: pointer;
    padding: 14px 16px;
    font-size: 17px;
}

/* Change background color of buttons on hover */
.tab button:hover {
    background-color: #ddd;
}

/* Create an active/current tablink class */
.tab button.active {
    background-color: #ccc;
    border-style: solid;
    border-radius: 10px;
    border-color: #98CB3B;
    color: #176696;
}

/* Style the tab content */
.tabcontent {
    display: none;
    padding: 6px 12px;
    border: 1px solid #ccc;
    border-top: none;
}

/* ------------------------------------------ Table ------------------------------------ */

table,
td,
tr {
    padding: 10%;
    border: 3px solid black;
    border-collapse: collapse;
}

th {
    border: 3px solid black;
    background-color: #AAA;
}

/* ------------------------------------------- Image ----------------------------------- */

.expandable-figure {
    max-width: 100%;
    cursor: pointer;
    margin-left: -5%;
    margin-top: 10%;
}

.expanded {
    max-width: none;
}


/* CSS for Columns Layout */
.columns-container {
    display: flex;
    justify-content: space-between;
    margin-top: 20px;
    /* Adjust as needed */
    flex-wrap: wrap;
    gap: 15px;
    /* Use gap for consistent spacing */
}

.left-column {
    flex: 1;
    margin-right: 10px;
    /* Adjust spacing between columns */
    background-color: white;
    /* Grey background */
    border: 2px solid #98CB3B;
    /* Light green border */
    border-radius: 10px;
    padding: 20px;
}

.center-column {
    flex: 2;
    /* Twice the width of left/right columns */
    background-color: white;
    /* White background */
    border: 2px solid #000000;
    /* Black border */
    border-radius: 10px;
    padding: 20px;
}

.right-column {
    flex: 1;
    margin-left: 10px;
    /* Adjust spacing between columns */
    background-color: white;
    /* Grey background */
    border: 2px solid #98CB3B;
    /* Light green border */
    border-radius: 10px;
    padding: 20px;
}


body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding: 0;
    display: flex;
    flex-direction: column;
    background: linear-gradient(135deg, #f5f7fa, #c3cfe2);
    color: #333;
    min-height: 100vh;
}

.header {
    text-align: center;
    margin-bottom: 20px;
    padding: 20px;
    background: #4a90e2;
    color: white;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.container {
    display: flex;
    flex-wrap: wrap;
    padding: 20px;
    gap: 20px;
    justify-content: center;
}


.input-section,
.output-section {
    flex: 1;
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-width: 400px;
    box-sizing: border-box;
}

.simulation-section {
    flex: 3;
    background: white;
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    text-align: center;
    box-sizing: border-box;
}

canvas {
    border: 1px solid #ccc;
    display: block;
    margin: 0 auto;
    background-color: #fff;
}

.controls,
.results {
    background-color: #f9f9f9;
    padding: 15px;
    border-radius: 5px;
    margin-bottom: 20px;
    box-sizing: border-box;
}

.results {
    overflow-y: auto;
    max-height: 300px;
    /* Increased height to avoid scrollbars */
    padding: 10px;
    background-color: #fff;
    border: 1px solid #ddd;
    border-radius: 5px;
}

.transmitter-image,
.receiver-image {
    max-width: 100px;
    max-height: 100px;
}

.receiver {
    transition: transform 0.2s ease-in-out;
}

button {
    background-color: #4a90e2;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    width: 100%;
    margin-top: 10px;
    font-size: 14px;
}

button:hover {
    background-color: #357abd;
}

input[type="number"],
input[type="range"] {
    width: calc(100% - 20px);
    padding: 10px;
    margin: 10px 0;
    border-radius: 5px;
    border: 1px solid #ccc;
    box-sizing: border-box;
    font-size: 14px;
}

input[type="range"] {
    padding: 0;
}

label {
    font-weight: bold;
    margin-top: 10px;
    display: block;
    color: #333;
}

/* Radio button styling */
input[type="radio"] {
    margin-right: 10px;
}

input[type="radio"]+label {
    display: inline-block;
    margin-bottom: 10px;
    font-weight: normal;
    color: #555;
}

/* Slider value display */
#wallPositionDisplay,
#wallPositionDisplay3 {
    margin-top: 10px;
    font-size: 14px;
    color: #555;
}

/* Output section styling */
.output-section h2 {
    margin-top: 0;
}

.results p {
    margin: 5px 0;
    font-size: 14px;
    color: #333;
}



.button-container {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.action-btn {
    padding: 10px 20px;
    border-radius: 8px;
    border: none;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    min-width: 130px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.calculate-btn {
    background-color: #4CAF50;
    color: white;
}

.calculate-btn:hover {
    background-color: #3e8e41;
}

.reset-btn {
    background-color: #f44336;
    color: white;
}

.reset-btn:hover {
    background-color: #d32f2f;
}


/* ADD THIS TO THE END OF YOUR CSS FILE */
.v-content ol li {
    transition: all 0.3s ease;
    padding: 8px;
    border-radius: 4px;
    border-left: 4px solid transparent;
}

.active-instruction {
    background-color: #e3f2fd; /* Light blue background */
    border-left: 4px solid #2196F3 !important; /* Blue accent border */
    color: #0d47a1; /* Darker blue text */
    font-weight: 500;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}