/* ====================================
   Global Reset for Embed Mode
   ==================================== */
html, body {
    margin: 0;
    padding: 0;
    border: 0;
    outline: 0;
    vertical-align: baseline;
}

/* ====================================
   Body Styling
   ==================================== */
body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #e8f0f7;
    margin: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

/* ✅ Add this for iframe mode */
body.embedded {
    display: block !important;
    align-items: flex-start !important;
    justify-content: flex-start !important;
    min-height: auto !important;
    height: auto !important;
    padding: 10px 0 !important;
}


/* ====================================
   Form Styling
   ==================================== */
form {
    background: #ffffff;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 6px 30px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 500px;
    margin: 20px auto;                 /* ✅ Keeps spacing inside iframe tight */
}

fieldset {
    border: 3px solid #0077b6;
    padding: 20px;
    box-sizing: border-box;
    margin: 0;
    border-radius: 8px;
}

legend {
    font-size: 1.8em;
    font-weight: bold;
    text-align: center;
    margin-bottom: 15px;
    color: #0077b6;
}

/* ====================================
   Input Styling
   ==================================== */
label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

input[type="text"],
input[type="email"],
select {
    width: 100%;
    padding: 12px;
    margin-bottom: 20px;
    border: 1px solid #ccc;
    border-radius: 5px;
    font-size: 16px;
    background-color: #f9f9f9;
}

input[type="text"]:focus,
input[type="email"]:focus,
select:focus {
    border-color: #0077b6;
    box-shadow: 0 0 5px rgba(0, 119, 182, 0.2);
    outline: none;
}

/* ====================================
   Button Styling
   ==================================== */
button {
    width: 100%;
    padding: 12px;
    background-color: #0077b6;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-size: 16px;
    font-weight: bold;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #005f86;
}

/* ====================================
   Modal Styling
   ==================================== */
#alertModal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

#modalContent {
    background: #ffffff;
    padding: 20px;
    border-radius: 8px;
    max-width: 500px;
    width: 100%;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);
    text-align: center;
}

#modalContent button {
    margin-top: 20px;
    padding: 10px 15px;
}

/* ====================================
   MAC Address Hidden Field
   ==================================== */
#macLabel,
#macAddress {
    display: none;
}

/* ====================================
   Progress Bar Styling
   ==================================== */
#progressBar {
    height: 20px;
    width: 100%;
    background-color: blue;
    border-radius: 5px;
}

#progressFill {
    height: 100%;
    width: 0%;
    background-color: green;
    border-radius: 5px;
    color: white;
    text-align: center;
    line-height: 20px; /* Align text vertically */
}

#progressText {
    color: white;
}

/* ====================================
   Responsive Design
   ==================================== */
@media (max-width: 768px) {
    form {
        padding: 20px;
        margin: 10px auto;
    }

    legend {
        font-size: 1.5em;
    }
}

@media (max-width: 480px) {
    form {
        padding: 15px;
        margin: 10px auto;
    }

    legend {
        font-size: 1.3em;
    }
}
