/* --------------------------------------------------
   GLOBAL BASE STYLES
-------------------------------------------------- */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}


body {
    font-family: "Poppins", sans-serif;
    background: #9A9A9A; 
    margin: 0;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

main {
    flex: 1;
    padding-top: 60px;
}

input {
    box-sizing: border-box;
}

h1 {
    color: red;
    font-size: 6rem;
}

/* Unified heading style */
h2 {
    color: #0057d8;
    font-size: 1.8rem;
    margin-bottom: 1rem;
    padding-left: 10px;
    text-align: left;
    padding-bottom: 15px;
}

/* Unified heading style */
h3 {
    color: #0057d8;
    font-size: 1.5rem;
    margin-bottom: 1rem;
    padding-left: 10px;
    text-align: left;
    padding-bottom: 15px;
}

.successText {
    color: #1758cf;
    font-size: 1.2rem;
    text-align: left;
    padding-left: 15px;
}

/* End of Global styling    */

/* --------------------------------------------------
   HEADER
-------------------------------------------------- */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background-color: #1302ad;
    border-bottom: 1px solid #ddd;
}

.site-title {
    margin: 0;
    font-size: 1.8rem;
    font-weight: bold;
}

.site-title a {
    text-decoration: none;
    color: #fff;
}

.site-title a:hover {
    opacity: 0.8;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Shadow box wrapper for user menu */
.user-menu-wrapper {
    display: inline-block;
    border-style: none;
    border-radius: 0;
    background: #f2f2f2;
    box-sizing: border-box;
}

/* Header menu */
.user-menu {
    position: relative;
}

.user-menu-trigger {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 180px;
    padding: 10px 12px;
    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    background: #f2f2f2;      /* match dropdown item background */
    color: black;             /* match dropdown text color */
    border-radius: 0;
    cursor: pointer;
    box-sizing: border-box;
   
}

.user-menu-trigger.open {
    border-bottom-color: transparent;
    border-bottom-left-radius: 0;
    border-bottom-right-radius: 0;
}

/* Dropdown container */
.dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    background: #f2f2f2;      /* match trigger background */
    border-radius: 0;
    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-top: none; /* seamless connection to trigger */
    padding: 0;
    width: 180px;
    box-sizing: border-box;
    display: none;
    z-index: 1000;
}

/* Menu items */
.dropdown-menu a,
.dropdown-menu .dropdown-link {
    display: block;
    width: 100%;
    padding: 10px 12px;
    text-align: left;
    background: #f2f2f2;
    color: black;
    text-decoration: none;
    border: none;
    cursor: pointer;
    font: inherit;
    box-sizing: border-box;
}

/* Hover state — darker grey */
.dropdown-menu a:hover,
.dropdown-menu .dropdown-link:hover,
.user-menu-trigger:hover {
    background: #d9d9d9;   /* darker grey hover */
}


/* Server status box */
.server-status {
  padding: 5px 12px;
  border-radius: 0px;
  font-weight: bold;
  text-align: center;
  min-width: 120px; /* keeps box consistent */
}

/* Connected state */
.server-status.ok {
  background-color: green;
  color: white;
}

/* Disconnected state */
.server-status.disconnected {
  background-color: red;
  color: white;
}

/* Register link */
a.register {
    display: inline-block;
    margin-top: 1rem;
    margin-bottom: 1rem;
    color: #666;
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.3s ease;
}

a.register:hover {
    color: #0057d8;
}

/* End of Header Styling */

/* Landing Page styling */

/* --------------------------------------------------
   LANDING PAGE
-------------------------------------------------- */

.landing-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 40px;      /* actual spacing below header */
    padding-bottom: 40px;  /* breathing room above footer */
    min-height: auto;      /* stop forcing full-screen height */
}


/* Card container — match login card geometry */
.landing-card {
   background: #f2f2f2;
    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-radius: 0;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-width: 320px;
    width: 100%;
}

/* Banner — match login banner */
.landing-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;
    border-radius: 0 0 0 0;
    margin: -20px -20px 15px -20px; /* attach to card edges */
}

/* Content area */
.landing-content {
    padding: 1.5rem;
    display: flex;
    justify-content: center;
}

.landing-image {
    width: 100px;
    height: auto;
    border-radius: 0;
    border-style: solid;
    border-width: 2px;
    border-color: rgb(114, 111, 111) white white rgb(114, 111, 111);
    background: #f2f2f2;
}

/* Buttons container */
.landing-buttons {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 1.5rem 0.5rem 1.5rem 1.5rem;
    align-items: flex-end;
}

.landing-btn {
    display: block;
    text-decoration: none;
    text-align: center;
    width: 120px;
    background-color: #f2f2f2;
    color: black;
    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-radius: 0px;
    padding: 10px 20px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.landing-btn:hover {
    background-color: #e6e6e6;
}

.landing-btn:active {
    background-color: #dcdcdc;
    border-color: #333;
}

/* End of landing page styling  */

/* Responsive */
@media (max-width: 400px) {
    form {
        width: 85%;
        padding: 1.5rem;
    }
}



/* --------------------------------------------------
   VIDEO PLAYER 
-------------------------------------------------- */

/* Outer container for all compound groups */
.groupContainer {
    max-width: 1080px;
    margin: 30px auto 0 auto;
    padding: 0px 0px 0px 0px;
    background: #f2f2f2;

    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114,111,111) rgb(114,111,111) white;
    border-radius: 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);

    display: flex;
    flex-direction: column;
    gap: 0px;
}


/* Banner for the video player page */
.groupContainer-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;
    display: flex;
    
    margin: 0px 0px 0px 0px;
    border-radius: 0;

    min-height: 48px;
    box-sizing: border-box;

    flex-shrink: 0;

    width: 100%;
}

.ttlBanner {
    width: 100%;
    height: 20px;
    margin: 0px 0px 0px 0px;
    border-radius: 0;
    background: transparent;
}

.wrapperDiv {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 65vh;
    object-fit: contain;
    overflow: hidden; /* prevents spill */
}

#videoContainer {
    width: 100%;
    height: 65vh;
    object-fit: contain;
    display: flex;
    background: black;
    justify-content: center;
    align-items: center;
    padding: 0;
        
}

.videoPlayer {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
    display: flex;          /* fixes narrow-video alignment */
    margin-left: auto;      /* ensures centering */
    margin-right: auto;
}

.focusPlay {
    background: black;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 65vh;
    padding: 0;
        
}

.activePhaseThumbnail {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    cursor: pointer;
}

.fallbackImage { /* in case no video is pending */
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
    border-radius: 0;
    padding: 0;
}

/* Thumbnail */
.thumbnailPlayImage {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;  /* no cropping */
    display: block;
    cursor: pointer;
    border-radius: 0;
    padding: 0;
    box-sizing: border-box;
    transition: transform 0.15s ease;
}

.thumbnailPlayImage:hover {
    opacity: 0.85;
   
}

/* Styling for the pixelated thumbnail phase */

/* Outer wrapper  */
.thumbnailWrapper {
    height: 65vh;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Inner thumbnail container */
.thumbnail {
    height: 100%;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Thumbnail image — match videoPlayer width + padding */
.thumbnailImage {
    height: 100%;
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
}

/* End of pixelated thumbnail phase */

/* Styling for rendered messages    */

.errorMessage {
    color: #1e4dd8;          /* blue */
    font-weight: bold;       /* bold text */
    text-align: center;      /* centered */
    padding: 10px 15px;
    margin: 10px auto;
    background-color: #e8f0ff; /* soft blue background */
    border: 1px solid #b5c8ff;
    border-radius: 0px;
    width: fit-content;
    max-width: 80%;
}

.successMessage {
    color: #1e4dd8;          /* blue */
    font-weight: bold;       /* bold text */
    text-align: center;      /* centered */
    padding: 10px 15px;
    margin: 10px auto;
    background-color: #e8f0ff; /* soft blue background */
    border: 1px solid #b5c8ff;
    border-radius: 0px;
    width: fit-content;
    max-width: 80%;
}

/* end of rendered message styling */

/* Admin page styling */

/* Wrapper that enables horizontal scrolling */
.admin-table-wrapper {
    width: 100%;
    overflow-x: auto;      /* enables horizontal scroll */
    overflow-y: hidden;
    margin-left: 10px;     /* keep your indent */
    padding-bottom: 12px; 
}

/* Admin user table styling */
.admin-user-table {
    border-collapse: collapse;
    margin-left: 10px;
    min-width: 800px;  
    width: auto;
}

.admin-user-table th,
.admin-user-table td {
    border: 1px solid #ccc;
    padding: 8px 12px;
    text-align: left;
}

.admin-user-table th {
    background-color: #f2f2f2;
    font-weight: bold;
}

.admin-user-table tr:nth-child(even) {
    background-color: #fafafa;
}

.admin-user-table select {
    padding: 4px;
}

.save-user-btn {
    padding: 4px 10px;
    cursor: pointer;
}

.delete-user-btn {
    padding: 4px 10px;
    background-color: #d9534f;
    color: white;
    border: none;
    cursor: pointer;
}

.delete-user-btn:hover {
    background-color: #c9302c;
}

.admin-section-title {
    margin-top: 40px;
    font-size: 1.4rem;
    font-weight: 700;
}

.admin-group-header {
    margin-top: 20px;
    font-size: 1.2rem;
    font-weight: 600;
}

/* Constrain video table section */
.video-table-wrapper {
    width: 75%;
    margin-right: 0;
    margin-left: 10px;
}

/* Scroll container for wide tables */
.video-scroll-container {
    width: 100%;
    overflow-x: auto;
    overflow-y: hidden;
    margin-bottom: 20px;
}

/* Prevent table from shrinking */
.admin-video-table {
    margin-left: 10px;
    min-width: 600px; /* adjust as needed */
    border-collapse: collapse;
    width: 100%;
}

.admin-video-table th,
.admin-video-table td {
    border: 1px solid #ccc;
    padding: 8px 12px;
    text-align: left;
}

.admin-video-table th {
    background-color: #f2f2f2;
    font-weight: bold;
}

.admin-video-table tr:nth-child(even) {
    background-color: #fafafa;
}

/* Narrower date columns */
.col-stream-date,
.col-upload-date {
    width: 100px;       /* adjust as needed */
    white-space: nowrap;
}

/* Keep Played column tight */
.col-played {
    width: 40px;
    text-align: center;
}

/* Let Short Title breathe */
.col-short-title {
    width: 25%;
}

/* Uploader column moderate width */
.col-uploader {
    width: 10%;
}

.col-ttl-end {
    width: 100px;
    white-space: nowrap;
}

/****************************************************/


/* Individual styling sections for forms and pages */

/* --------------------------------------------------
   SUCCESS PAGE — MATCH HOME + UPLOAD FORM
-------------------------------------------------- */

.success-wrapper {
    max-width: 350px;
    margin: 40px auto 0 auto;
    padding: 20px;
    background: #f2f2f2;

    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;

    border-radius: 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Banner (same as home-banner / upload-banner) */
.success-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;

    margin: -20px -20px 15px -20px;
    border-radius: 0;
}

/* Success text */
.success-message {
    font-size: 1.1rem;
    font-weight: 600;
    margin: 10px 0 20px 0;
}

/* Section subtitles */
.success-subtitle {
    margin-top: 20px;
    margin-bottom: 12px;
    font-size: 1.1rem;
    font-weight: 500;
}

/* Right‑aligned button row (same as upload form) */
.success-button-row {
    text-align: right;
}

/* Buttons — identical to .home-button and .upload-button */
.success-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #f2f2f2;
    color: black;
    font-weight: 700;
    font-size: 1rem;

    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;

    cursor: pointer;
    border-radius: 0;
    text-decoration: none;

    margin-bottom: 12px;
}

.success-button:hover {
    background-color: #e6e6e6;
}

/* End of success page styling */

/* --------------------------------------------------
   HOME PAGE — MATCH UPLOAD FORM STYLE
-------------------------------------------------- */

.home-wrapper {
    max-width: 400px;
    margin: 40px auto 0 auto;
    padding: 20px;
    background: #f2f2f2;

    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;

    border-radius: 0;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* Banner (same as .upload-banner) */
.home-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;

    margin: -20px -20px 15px -20px; /* attach to wrapper edges */
    border-radius: 0;
}

/* Info text */
.home-info p {
    margin: 10px 0;
    font-size: 1rem;
}

/* Section subtitles (same spacing as labels) */
.home-subtitle {
    margin-top: 20px;
    margin-bottom: 12px;
    font-size: 1.1rem;
    font-weight: 500;
}

.home-button-row {
    text-align: right;
}

/* Action buttons — identical to .upload-button */
.home-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #f2f2f2;
    color: black;
    font-weight: 700;
    font-size: 1rem;

    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;

    cursor: pointer;
    border-radius: 0;
    text-decoration: none;

    margin-bottom: 12px;
}

.home-button:hover {
    background-color: #e6e6e6;
}

/* Styling for the video summary table */
/* Wrapper for user's uploaded videos */
.user-videos-wrapper {
    background: #f2f2f2;
    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114,111,111) rgb(114,111,111) white;
    border-radius: 0;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    max-width: 400px;
    margin: 30px auto 60px auto;
}

/* Banner */
.user-videos-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.3rem;
    font-weight: 600;
    text-align: left;
    margin: -20px -20px 15px -20px;
    border-radius: 0;
}

/* List styling */
.user-video-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.user-video-item {
    padding: 10px 8px;
    border-bottom: 1px solid #ccc;
}

.user-video-item:last-child {
    border-bottom: none;
}

.user-video-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.user-video-title.past-video {
    font-weight: 400; /* normal weight */
    opacity: 0.7;     /* optional: subtle fade */
}

.user-video-date {
    font-size: 0.9rem;
    color: #555;
}

/* Empty state */
.user-video-empty {
    padding: 10px 8px;
    font-size: 1rem;
    color: #555;
}



/* End of home page styling */

/* --------------------------------------------------
   VIDEO UPLOAD FORM
-------------------------------------------------- */

/* Uniform spacing between all form rows */
.upload-form > div {
    margin-bottom: 30px;
}

/* Form spacing */
.upload-form {
    padding-top: 40px;
}

/* OUTER CARD — this is the only container now */
.form-wrapper {
    background: #f2f2f2;
    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-radius: 0px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-width: 350px;
    margin: 40px auto 0 auto;
}

/* Remove .form-container visual box — keep layout only */
.form-container {
    width: 100%;
    margin: 0;
    padding: 0;
    border: none;
    background: transparent;
}

/* Banner */
.upload-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;
    border-radius: 0px 0px 0 0;
    margin: -20px -20px 15px -20px; /* attach to wrapper edges */
}


/* File input row */
.file-input-wrapper {
    display: flex;
    align-items: flex-start;
    gap: 10px;
}

/* Button */
.file-button {
    background: #f2f2f2;
    color: black;
    padding: 2px 10px;   /* horizontal only — no vertical padding */
    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    appearance: none;
    font-size: 1rem;
    font-weight: 400;
    border-radius: 0;
    cursor: pointer;
    white-space: nowrap;
    height: 30px;
    box-sizing: border-box;

    display: flex;            /* ← perfect centering */
    align-items: center;
    justify-content: center;
}

/* Hide native file input */
.file-input-wrapper input[type="file"] {
    display: none;
}

/* Filename field */
input.file-name-display {
    flex: 1;
    padding: 10px 14px;
    font-size: 1rem;
    background: #f2f2f2;
    border: none !important;
    border-radius: 0;
    height: 42px;
    box-sizing: border-box;
}

/* Add spacing between labels and inputs */
.upload-form label {
    display: block;
    margin-bottom: 12px;   /* ← adjust to taste (4–10px works well) */
    font-weight: 400;     /* optional: makes labels clearer */
}

/* Other form inputs — with proper vertical centering */
.upload-form input[type="text"],
.upload-form input[type="date"],
.upload-form input[type="time"] {
    width: 100%;
    background: #f2f2f2;
    box-sizing: border-box;
    height: 30px;

    /* Vertical centering */
    padding: 0 8px;              /* remove vertical padding */
    line-height: 30px;           /* centers text in older browsers */
    display: flex;
    align-items: center;         /* centers text in modern browsers */

    /* Borders */
    border-style: solid;
    border-width: 2px;
    border-color: rgb(114, 111, 111) white white rgb(114, 111, 111);
    border-radius: 0px;

    font-size: 1rem;
}
.upload-form input[type="text"]:focus,
.upload-form input[type="date"]:focus,
.upload-form input[type="time"]:focus {
    border-color: black;
    background-color: #f2f2f2;
    outline: none;
}


.button-row {
    text-align: right;
}

/* Submit button */
.upload-button {
    display: inline-block;
    padding: 10px 20px;
    background-color: #f2f2f2;
    color: black;
    font-weight: 700; 
    font-size: 1rem;
    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    cursor: pointer;
    border-radius: 0px;
    margin-bottom: 80px;
    
}


input.file-name-display {
    height: 30px;
    padding: 10px 10px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    line-height: 1.2;
}

/* Progress bar styling elements */
.progress-container {
    width: 100%;
    background: #ddd;
    height: 20px;
    margin-top: 20px;
    border-radius: 0; /* match your square design */
    overflow: hidden;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: #1302ad; /* match your theme */
    transition: width 0.2s ease;
}

#convertProgressContainer {
    width: 100%;
    height: 20px;
    background: #ddd;
    border-radius: 0px;
    overflow: hidden;
    margin-top: 10px;
}

#convertProgressBar {
    height: 100%;
    width: 0%;
    background: #1302ad;
    transition: width 0.2s ease;
}

/* End of progress bar styling  */

/* --------------------------------------------------
   END -> VIDEO UPLOAD FORM
-------------------------------------------------- */

/* --------------------------------------------------
   REGISTRATION PAGE
-------------------------------------------------- */

/* Outer wrapper (same structure as login-wrapper) */
.register-wrapper {
    display: flex;
    flex-direction: column;
    /* justify-content: flex-start;   /* no vertical centering */
    align-items: center;
    padding-top: 40px;             /* consistent with login page */
}

/* Card container (matches login-card + upload form wrapper) */
.register-card {
    background: #f2f2f2;
    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-radius: 0;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-width: 300px;
    width: 100%;
}

/* Banner (matches login-banner + upload-banner) */
.register-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;
    margin: -20px -20px 15px -20px; /* attach to card edges */
}

/* Label spacing (same as login + upload) */
.register-card label {
    display: block;
    margin-bottom: 6px;
    font-weight: 400;
}

/* Inputs (same as login + upload) */
.register-card input[type="text"],
.register-card input[type="password"],
.register-card input[type="email"] {
    width: 100%;
    background: #f2f2f2;
    box-sizing: border-box;
    height: 30px;

    /* Vertical centering */
    padding: 0 8px;
    line-height: 30px;
    display: flex;
    align-items: center;

    /* Two-tone border */
    border-style: solid;
    border-width: 2px;
    border-color: rgb(114, 111, 111) white white rgb(114, 111, 111);

    border-radius: 0;
    font-size: 1rem;
    margin-bottom: 20px;
}

.register-card input[type="text"]:focus,
.register-card input[type="password"]:focus,
.register-card input[type="email"]:focus {
    border-color: black;
    background-color: #f2f2f2;
    outline: none;
}

/* Submit button row (right aligned) */
.register-button-row {
    text-align: right;
}

/* Submit button (matches login + upload) */
.register-submit {
    background-color: #f2f2f2;
    color: black;
    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-radius: 0;
    padding: 10px 20px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
}

/* Hover / focus / active states (same as login) */
.register-submit:hover {
    background-color: #dcdcdc;
}

.register-submit:focus {
    background-color: #c8c8c8;
    outline: none;
    border-color: black;
}

.register-submit:active {
    background-color: #b5b5b5;
}

/* End registration form */ 

/* --------------------------------------------------
   LOGIN PAGE
-------------------------------------------------- */

/* Outer login card (matches upload form wrapper) */
.login-card {
    background: #f2f2f2;
    border-style: solid;
    border-width: 5px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-radius: 0;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    max-width: 300px;
    width: 100%;
    
}

.login-card form {
    margin-top: 40px;   /* adjust to taste */
}

/* Banner (matches upload banner) */
.login-banner {
    background: #1302ad;
    color: #fff;
    padding: 12px 16px;
    font-size: 1.4rem;
    font-weight: 600;
    text-align: left;
    border-radius: 0 0 0 0;
    margin: -20px -20px 15px -20px; /* attach to card edges */
}

.login-wrapper {
    display: flex;
    flex-direction: column;
    /* justify-content: flex-start; */
    padding-top: 40px;   /* ← pushes form down */
    align-items: center;
    /* height: 100vh; */
}

.login-box {
    width: 350px;
    padding: 2rem;
    background: #fff;
    border-radius: 0px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
}

.login-link {
    display: inline-block;
    background: #fff;
    border-radius: 0px;
    padding: 3px 12px;
    margin: 8px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.1);
    width: 320px;
    text-align: center;
}

/* Login inputs */
.login-card input[type="text"],
.login-card input[type="password"],
.login-card input[type="email"] {
    width: 100%;
    background: #f2f2f2;
    box-sizing: border-box;
    height: 30px;

    /* Vertical centering */
    padding: 0 8px;
    line-height: 30px;
    display: flex;
    align-items: center;

    /* Two-tone border */
    border-style: solid;
    border-width: 2px;
    border-color: rgb(114, 111, 111) white white rgb(114, 111, 111);

    border-radius: 0;
    font-size: 1rem;
    margin-bottom: 20px;
}


.login-wrapper label {
    display: block;
    margin-bottom: 12px;   /* ← adjust to taste (4–10px works well) */
    font-weight: 400;     /* optional: makes labels clearer */
}


.login-wrapper input[type="text"]:focus,
.login-wrapper input[type="password"]:focus,
.login-wrapper input[type="email"]:focus {
    border-color: black;
    background-color: #f2f2f2;
    outline: none;
}

/* Submit button */
.login-wrapper input[type="submit"].login {
    width: 50%;
    background-color: #f2f2f2;
    color: black;
    border-style: solid;
    border-width: 2px;
    border-color: white rgb(114, 111, 111) rgb(114, 111, 111) white;
    border-radius: 0px;
    padding: 10px 20px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

/* Hover state */
.login-wrapper input[type="submit"].login:hover {
    background-color: #dcdcdc;   /* slightly darker gray */
}

/* Focus state (keyboard selection) */
.login-wrapper input[type="submit"].login:focus {
    background-color: #c8c8c8;   /* darker still */
    outline: none;               /* remove default blue outline */
    border-color: black;         /* optional: stronger border */
}

/* Active state (mouse click) */
.login-wrapper input[type="submit"].login:active {
    background-color: #b5b5b5;   /* darkest during click */
}

.login-button-row {
    text-align: right;
}

/* End of the login styling */





.bannerCountdown {
    margin-right: 12px;
    padding: 4px 8px;
    border-radius: 0px;
    background: rgba(0,0,0,0.4);
    color: black;
}

.bannerTitle {
    flex: 1 1 auto;
    display: flex;
    align-items: center;
    min-width: 0;
}
/* End of new Video Upload Page styling elements    */

/* Begin Thumnnail row styling  */
.thumbnail-row {
    display: flex;
    gap: 6px;
    padding: 12px;
    overflow-x: auto;
    border: none;
    background: #f2f2f2;
    min-height: 20px;
}

.thumbnail-row::-webkit-scrollbar {
    height: 8px;
}

.thumbnail-row::-webkit-scrollbar-thumb {
    background: #555;
    border-radius: 0px;
}

.bottomThumb {
    height: 80px;          /* fixed height for consistency */
    width: auto;
    object-fit: cover;
    border-radius: 0px;
    cursor: pointer;
    transition: transform 0.15s ease;
}

.bottomThumb:hover {
    transform: scale(1.05);
}

.thumbWrapper {
    position: relative;
    display: inline-block;
    margin: 0 6px;
}

.thumbWrapper img.bottomThumb {
    display: block;
}

.thumbTTLBar {
    height: 6px;
    width: 100%;
    position: absolute;
    bottom: 0;
    left: 0;
}

/* End Tuhumbnail row styling   */

/* Styling for the dev mode header text */ 
.dev-mode-indicator {
    color: white;
    font-size: 1.5rem;
    margin-left: 12px;
    padding: 2px 6px;
    background: black;
    border-radius: 4px;
    font-weight: bold;
}

/* Unified close button styling (normal + focused) */
.focusedCloseBtn {
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;

    padding: 4px 12px;
    font-size: 1.6rem;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
    user-select: none;

    color: white;
    opacity: 0.85;
    transition: opacity 0.15s ease;
}

/* Hover effect */
.focusedCloseBtn:hover {
    opacity: 1;
}

/* Dynamic header state changes for videoPlayer page */
/* Hide header smoothly */
.page-header.hide-header {
    transform: translateY(-100%);
    transition: transform 0.4s ease;
}

/* Ensure header is positioned for sliding */
.page-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 2000;
    transition: transform 0.4s ease;
}

.groupContainer.shift-up {
    transform: translateY(-60px); /* same as header height */
    transition: transform 0.4s ease;
}

.fallback-overlay {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.85);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
}

.fallback-grid {
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
    justify-content: center;
}

.fallback-grid img {
    width: 50px;
    height: auto;
    cursor: pointer;
    border: 3px solid transparent;
    border-radius: 8px;
}

.fallback-grid img:hover {
    border-color: #4caf50;
}

.active-videos-table td,
.active-videos-table th {
    padding: 3px 20px;   /* Increase horizontal spacing */
}

.active-video-thumb-cell {
    width: 60px; /* keeps column narrow */
    padding: 8px 12px;
}

.active-video-thumb {
    width: 70px;
    height: 40px;
    object-fit: cover;
    border-radius: 0px;
    display: block;
}