body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background: #fff;
    margin: 0;
    color: #2c3e50;
}
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 32px 8px 32px;
    background: #fff;
    border-bottom: 1px solid #e0e0e0;
}
.header-left h2 {
    margin: 0;
    font-size: 1.4rem;
    font-weight: 400;
}
.header-right {
    display: flex;
    align-items: center;
    gap: 16px;
}
.header-right i {
    color: #b0b0b0;
    font-size: 1.1rem;
}
.header-right span {
    color: #3b5360;
    font-size: 1.3rem;
}
.profile-pic {
    width: 32px;
    height: 32px;
    background: #e0e0e0;
    border-radius: 50%;
}
nav {
    background: #3b5360;
    border-bottom: 2px solid #2ecc71;
}
nav ul {
    display: flex;
    margin: 0;
    padding: 0 0 0 16px;
    list-style: none;
}
nav li {
    color: #fff;
    padding: 18px 32px;
    font-size: 1rem;
    cursor: pointer;
    border-right: 1px solid #4a6572;
    transition: background 0.2s;
}
nav li:last-child {
    border-right: none;
}
nav li.active {
    background: #466178;
    border-bottom: 2px solid #2ecc71;
}
main {
    padding: 32px 32px 0 32px;
}
.hidden{display: none;}
.form-section {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 2px;
    padding: 24px 24px 32px 24px;
    max-width: 900px;
    margin: 0 auto;
}
.form-section-branding {
    max-width: 1000px;
}
.form-section-calendar {
    max-width: max-content;
}
.form-section h3 {
    margin-top: 0;
    font-weight: 400;
    font-size: 1.2rem;
    color: #3b5360;
}
.details-section {
    margin-top: 32px;
    margin-bottom: 16px;
}
.details-section h4 {
    margin: 0 0 12px 0;
    font-weight: 500;
    color: #3b5360;
    font-size: 1.1rem;
    border-top: 1px solid #e0e0e0;
    padding-top: 18px;
}
.form-group {
    display: flex;
    flex-direction: column;
    margin-bottom: 16px;
    flex: 1;
    min-width: 180px;
}
.form-row {
    display: flex;
    gap: 16px;
}
.text-wraping {
    white-space: nowrap;
    display: block;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    padding: 8px 12px;
    border: 1px solid #cfd8dc;
    border-radius: 2px;
    font-size: 1rem;
    background: #fafbfc;
    text-decoration: none;
    color: #000;
}
.text-wraping2 {
    display: block;
    padding: 8px 12px;
    border: 1px solid #cfd8dc;
    border-radius: 2px;
    font-size: 1rem;
    background: #fafbfc;
    text-decoration: none;
    color: #000;
}
label {
    font-size: 0.98rem;
    color: #3b5360;
    margin-bottom: 4px;
}
input[type="text"],
input[type="email"],
input[type="url"],
select {
    padding: 8px 12px;
    border: 1px solid #cfd8dc;
    border-radius: 2px;
    font-size: 1rem;
    outline: none;
    background: #fafbfc;
    transition: border 0.2s;
}
input[type="text"]:focus,
input[type="email"]:focus,
select:focus {
    border: 1.5px solid #2ecc71;
}
.phone-input {
    display: flex;
    align-items: center;
    gap: 6px;
}
.flag {
    font-size: 1.2rem;
    margin-right: 2px;
}
.country-code {
    border: none;
    background: transparent;
    font-size: 1rem;
    width: 48px;
    color: #3b5360;
    padding: 0 4px;
}
.country-code:focus {
    outline: none;
}
.email-input {
    display: flex;
    align-items: center;
    position: relative;
}
.email-input input {
    flex: 1;
    padding-right: 32px;
}
.email-icon {
    position: absolute;
    right: 8px;
    color: #b0b0b0;
    font-size: 1.1rem;
}
.form-actions {
    justify-content: center;
    margin-top: 24px;
    display: flex;
    gap: 12px;
}
.submit-btn {
    background: #2ecc71;
    color: #fff;
    border: none;
    padding: 10px 28px;
    border-radius: 2px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s;
}
.submit-btn:hover {
    background: #27ae60;
}
.reset-btn {
    background: #fff;
    color: #3b5360;
    border: 1px solid #cfd8dc;
    padding: 10px 18px;
    border-radius: 2px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.2s;
}
.reset-btn:hover {
    background: #f2f2f2;
}
/* Responsive styles */
@media (max-width: 900px) {
    .form-section {
        padding: 12px 4px 24px 4px;
        max-width: 100%;
    }
    main {
        padding: 8px;
    }
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    .form-group {
        min-width: 0;
    }
}

@media (max-width: 700px) {
    header, nav ul {
        flex-direction: column;
        align-items: flex-start;
    }
    nav ul {
        padding: 0;
    }
    nav li {
        padding: 12px 12px;
        font-size: 0.98rem;
    }
    .form-section {
        padding: 8px 2px 16px 2px;
    }
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    .form-group {
        min-width: 0;
    }
    .form-actions {
        flex-direction: column;
        gap: 8px;
    }
    .subform-table-wrapper {
        overflow-x: auto;
    }
    .subform-table {
        min-width: 600px;
        font-size: 0.95rem;
    }
}

@media (max-width: 500px) {
    .form-section h3, .form-section h4 {
        font-size: 1rem;
    }
    .submit-btn , .reset-btn {
        font-size: 0.98rem;
        padding: 8px 12px;
    }
    .subform-table {
        font-size: 0.92rem;
    }
}

/* Make subform table always scrollable on small screens */
.subform-table-wrapper {
    width: 100%;
    overflow-x: auto;
}
.subform-table {
    width: 100%;
    border-collapse: collapse;
}
.subform-table th, .subform-table td {
    padding: 8px 6px;
    border-bottom: 1px solid #e0e0e0;
    text-align: left;
}
.subform-table th {
    background: #fafbfc;
    font-weight: 500;
    font-size: 1rem;
}
.subform-table td input[type="text"] {
    width: 100%;
    min-width: 80px;
    box-sizing: border-box;
}

/* Event Details two-column layout */
#event-details-section form .form-row {
    display: flex;
    align-items: center;
    gap: 0;
    margin-bottom: 12px;
}
#event-details-section form .form-group {
    flex-direction: row;
    align-items: center;
    margin-bottom: 0;
    min-width: 0;
    width: 100%;
}
#event-details-section form label {
    flex: 0 0 180px;
    /* text-align: right; */
    margin-right: 18px;
    margin-bottom: 0;
    font-size: 1rem;
}
#event-details-section form input,
#event-details-section form select,
#event-details-section form .date-input {
    /* flex: 1 1 320px;
    max-width: 400px; */
    min-width: 120px;
}
#event-details-section form .date-input {
    display: flex;
    align-items: center;
}
#event-details-section form .date-input input {
    flex: 1;
}

@media (max-width: 700px) {
    #event-details-section form .form-row {
        flex-direction: column;
        align-items: stretch;
    }
    #event-details-section form label {
        text-align: left;
        margin-right: 0;
        margin-bottom: 4px;
    }
    #event-details-section form input,
    #event-details-section form select,
    #event-details-section form .date-input {
        max-width: 100%;
        min-width: 0;
    }
}

/* Make Event Start/End Date input fields shorter in Event Details */
#event-details-section form .form-row .date-input input[type="text"] {
    max-width: 220px;
}

/* Make date/time input fields shorter in Contact Details and Installation/Removal sections */
#contact-details-section form .form-row .date-input input[type="text"],
#installation-removal-section form .form-row .date-input input[type="text"] {
    max-width: 220px;
} 

/* Two-column layout for Contact Details and Installation/Removal sections */
#contact-details-section form .form-row,
#installation-removal-section form .form-row {
    display: flex;
    align-items: center;
    gap: 0;
    margin-bottom: 12px;
}
#contact-details-section form .form-group,
#installation-removal-section form .form-group {
    flex-direction: row;
    align-items: center;
    margin-bottom: 0;
    min-width: 0;
    width: 100%;
}
#contact-details-section form label,
#installation-removal-section form label {
    flex: 0 0 180px;
    text-align: right;
    margin-right: 18px;
    margin-bottom: 0;
    font-size: 1rem;
}
#contact-details-section form input,
#contact-details-section form select,
#contact-details-section form .date-input,
#installation-removal-section form input,
#installation-removal-section form select,
#installation-removal-section form .date-input {
    /* flex: 1 1 320px; */
    max-width: 400px;
    min-width: 120px;
}
#contact-details-section form .date-input,
#installation-removal-section form .date-input {
    display: flex;
    align-items: center;
}
#contact-details-section form .date-input input,
#installation-removal-section form .date-input input {
    flex: 1;
}

@media (max-width: 700px) {
    #contact-details-section form .form-row,
    #installation-removal-section form .form-row {
        flex-direction: column;
        align-items: stretch;
    }
    #contact-details-section form label,
    #installation-removal-section form label {
        text-align: left;
        margin-right: 0;
        margin-bottom: 4px;
    }
    #contact-details-section form input,
    #contact-details-section form select,
    #contact-details-section form .date-input,
    #installation-removal-section form input,
    #installation-removal-section form select,
    #installation-removal-section form .date-input {
        max-width: 100%;
        min-width: 0;
    }
} 

/* Contact Details: Remove gap between First Name and Last Name */
#contact-details-section .details-section .form-row {
    gap: 0;
}

/* Contact Details: Stack Email below Phone */
#contact-details-section .details-section .form-row {
    flex-direction: column;
}
#contact-details-section .details-section .form-group.phone-group,
#contact-details-section .details-section .form-group.email-group {
    width: 100%;
}

/* Contact Details: Adjust country code width in phone number */
#contact-details-section .country-code {
    width: 60px;
    min-width: 40px;
    max-width: 80px;
} 

/* Contact Details: First Name and Last Name horizontal with minor space */
#contact-details-section .details-section .form-row.name-row {
    flex-direction: row;
    gap: 8px;
}
#contact-details-section .details-section .form-row.name-row .form-group {
    flex: 1 1 0;
    min-width: 0;
} 

/* Contact Details: Two-column layout for all fields */
#contact-details-section .form-row {
    display: flex;
    align-items: center;
    margin-bottom: 18px;
}
#contact-details-section .form-row label {
    flex: 0 0 160px;
    text-align: right;
    margin-right: 18px;
    font-size: 1rem;
    margin-bottom: 0;
}
#contact-details-section .form-row .input-group {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 1 1 0;
}
#contact-details-section .form-row .input-group input[type="text"],
#contact-details-section .form-row .input-group input[type="email"] {
    min-width: 0;
    flex: 1 1 0;
}
#contact-details-section .form-row .input-group select {
    min-width: 60px;
}
#contact-details-section .form-row .input-group .flag {
    font-size: 1rem;
    margin-right: 2px;
}
#contact-details-section .form-row .input-group.email-input {
    position: relative;
}
#contact-details-section .form-row .input-group.email-input input[type="email"] {
    padding-right: 32px;
}
#contact-details-section .form-row .input-group .email-icon {
    position: absolute;
    right: 8px;
    color: #b0b0b0;
    font-size: 1.1rem;
}
@media (max-width: 700px) {
    #contact-details-section .form-row {
        flex-direction: column;
        align-items: stretch;
    }
    #contact-details-section .form-row label {
        text-align: left;
        margin-right: 0;
        margin-bottom: 4px;
    }
    #contact-details-section .form-row .input-group {
        flex-direction: column;
        gap: 8px;
    }
} 

/* Contact Details: Table-like two-column layout */
.contact-table {
    margin-top: 24px;
    margin-bottom: 24px;
}
.form-table-row {
    display: flex;
    align-items: center;
    margin-bottom: 18px;
}
.form-table-label {
    flex: 0 0 160px;
    text-align: right;
    margin-right: 18px;
    font-size: 1rem;
    color: #2c3e50;
}
.form-table-input {
    flex: 1 1 0;
    display: flex;
    align-items: center;
}
.form-table-input input[type="text"],
.form-table-input input[type="email"] {
    min-width: 0;
    flex: 1 1 0;
    margin-bottom: 0;
}
.form-table-input input[type="text"]:not(:first-child),
.form-table-input input[type="email"]:not(:first-child) {
    margin-left: 8px;
}
.form-table-input select {
    min-width: 60px;
    margin-left: 8px;
}
.form-table-input .flag {
    font-size: 1rem;
    margin-right: 2px;
}
.form-table-input.email-input {
    position: relative;
}
.form-table-input.email-input input[type="email"] {
    padding-right: 32px;
}
.form-table-input .email-icon {
    position: absolute;
    right: 8px;
    color: #b0b0b0;
    font-size: 1.1rem;
}
@media (max-width: 700px) {
    .form-table-row {
        flex-direction: column;
        align-items: stretch;
    }
    .form-table-label {
        text-align: left;
        margin-right: 0;
        margin-bottom: 4px;
    }
    .form-table-input {
        flex-direction: column;
        gap: 8px;
    }
    .form-table-input input[type="text"],
    .form-table-input input[type="email"] {
        margin-left: 0 !important;
    }
    .form-table-input select {
        margin-left: 0;
    }
} 

.loading-dock-label {
    font-size: 1.15em;
    font-weight: 600;
}

.loading-dock-desc {
    font-size: 0.98em;
    color: #555;
    margin-top: 2px;
} 

.form-check .form-check-input {
    width: 20px;
    height: 20px;
    padding: 0;
    min-height: auto;
    /* margin-top: 0; */
    min-width: 1px !important;
}
#subform-body tr{
    vertical-align: top;
}
.btn-size-chart{
    background-color: #ccc !important;
    border: 0 !important;
    padding: 3px 9px !important;
    margin-left: 5px !important;
}
.table thead th {
  background-color: #f8f9fa;  /* light gray */
  color: #000;                /* text color */
}


/* Container with horizontal scroll */
/* ===== Availability Calendar (fresh build) ===== */
:root{
  --ac-col-pod: 72px;    /* Pod # column width  */
  --ac-col-type: 132px;  /* Type column width   */
  --ac-col-name: 220px;  /* Name column width   */
}

/* scroll container */
.ac-wrap{
  overflow-x: auto;                 /* horizontal scroll when dates overflow */
  border: 1px solid #e6eaef;
  border-radius: 6px;
}

/* table sizing */
#ac-table{
  width: max-content;               /* grow to content => enables horizontal scroll */
  min-width: 100%;
  table-layout: fixed;
  border-collapse: separate;
  border-spacing: 0;
  border-collapse: separate !important;
}

/* tidy cells */
#ac-table th,#ac-table td{
  padding:.5rem .6rem;
  vertical-align: middle;
  white-space: nowrap;
}
#ac-table select.form-select-sm,
#ac-table input.form-control-sm{ width:100%; }

/* sticky header */
#ac-table thead th{
  position: sticky;
  top: 0;
  background: #f8fafc;
  z-index: 3;
  box-shadow: inset 0 -1px 0 rgba(0,0,0,.05);
}

/* sticky first 3 columns (pod/type/name) */
#ac-table .sticky-1,
#ac-table .sticky-2,
#ac-table .sticky-3{
  position: sticky;
  background: #fff;
  z-index: 4;
}
#ac-table .sticky-1{ left: 0; }
#ac-table .sticky-2{ left: var(--ac-col-pod); }
#ac-table .sticky-3{ left: calc(var(--ac-col-pod) + var(--ac-col-type)); }

/* widths that match the sticky offsets */
#ac-table .col-pod  { width: var(--ac-col-pod);  }
#ac-table .col-type { width: var(--ac-col-type); }
#ac-table .col-name { width: var(--ac-col-name); }

/* date groups */
#ac-table th.date-group{ min-width: 240px; text-align:center; }
#ac-table td.time-cell{ width: 120px; }

/* subtle divider between sticky and scrolling part */
#ac-table .sticky-3{ box-shadow: 1px 0 0 rgba(0,0,0,.06); }

/* small text in date headers */
#ac-table .date-note{ display:block; font-size:.825rem; color:#6b7280; }

/* availability calendar row divider */
#ac-table tbody tr {
  border-bottom: 2px solid #dee2e6; /* thicker line than default */
}

/* Availability Calendar: compact field layout */
.form-section-calendar .ac-compact .row{
  /* cut the Bootstrap gutter between label & input */
  --bs-gutter-x: .5rem;  /* default is 1.5rem */
}

/* reduce vertical spacing between rows */
.form-section-calendar .ac-compact .mb-3{
  margin-bottom: .5rem !important; /* default ~1rem */
}

/* make the inputs narrower on sm+ screens */
@media (min-width: 576px){
  /* override Bootstrap's col-sm-6 (50%) to a fixed, compact width */
  .form-section-calendar .ac-compact .col-sm-6{
    flex: 0 0 auto;
    width: 260px;       /* adjust to taste: 220–300px works well */
  }
}

/* visually smaller controls without changing markup */
.form-section-calendar .ac-compact .form-control{
  max-width: 260px;     /* keeps them from stretching */
  padding: .375rem .5rem;
  font-size: .95rem;
}

/* Remove Bootstrap’s row gutters */
.form-section-calendar .row.align-items-center {
  margin-left: 0;
  margin-right: 0;
}

.form-section-calendar .row.align-items-center > [class*="col-"] {
  padding-left: 0;
  padding-right: 0;
}

/* Fix label column width */
.form-section-calendar .col-sm-4.col-form-label {
  flex: 0 0 160px;   /* adjust width for labels */
  max-width: 160px;
  font-weight: 500;
  text-align: left; /* optional: right-align labels */
  margin-right: 10px; /* small space before input */
}

/* Fix input column width */
.form-section-calendar .col-sm-6 {
  flex: 0 0 240px;   /* adjust width for inputs */
  max-width: 240px;
}

/* Make inputs look consistent */
.form-section-calendar .form-control {
  width: 100%;
}

