body {
    font-family: 'Roboto', sans-serif;
    background-color: #f4f4f4;
    color: #333333;
    line-height: 1.6;
    margin: 0;
    padding: 20px;
    box-sizing: border-box;
}

h1, h2, h3 {
    font-weight: 500;
    margin-bottom: 15px;
}

h4, h5, h6 {
    font-weight: 500;
    margin-bottom: 5px;
}

a {
    color: black;
    text-decoration: none;
    font-weight: bold;
}

a:hover {
    color: #2980b9;
}

.container-header {
    width: 1500px;
    max-width: 100%;
    display: block;
    margin: 0 auto;
    gap: 30px;
    padding: 20px;
}

.container {
    width: 1500px;
    max-width: 100%;
    display: flex;
    margin: 0 auto;
    gap: 30px;
    padding: 20px;
}

.input-section, .output-section {
    flex: 1;
}

#file-upload {
    margin-top: 10px;
}

.upload-container {
    display: flex;
    justify-content: left;
    gap: 20px;
    margin-top: 20px;
}

#output {
    border: 1px solid #ccc;
    padding: 10px;
    min-height: 300px;
}

.work-in-progress{
    color: #bbbbbb;
    width: 1500px;
    max-width: 100%;
    display: block;
    margin: 0 auto;
    gap: 30px;
    padding: 20px;
}

.error-output{
    display: none;
}

.oracc-output{
    font-family: 'Source Code Pro', 'Fira Mono', 'Roboto Mono', monospace;
}

/* Upload section */
.drop-zone {
    width: 100%;
    height: 25px;
    border: 2px dashed #000000;
    border-radius: 40px;
    font-family: Arial, sans-serif;
    text-align: center;
    padding: 20px;
    margin: 20px auto;
    cursor: pointer;
    transition: background 0.3s ease;
}

.drop-zone:hover, .drop-zone.dragover {
    background: rgba(0, 123, 255, 0.466);
}

.drop-zone p {
    margin: 0;
    position: relative;
    top: 50%;
    transform: translateY(-50%);
}

.file-input {
    display: none;
}

#file-name {
    margin-top: 10px;
    font-style: italic;
    color: #666;
}

.loading{
  position: fixed;
  top: 12px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;

  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;

  border: 1px solid #490000;
  background: rgb(255, 214, 220);
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(0,0,0,.12);

  max-width: min(720px, calc(100vw - 24px));
}

.loading[hidden]{ display: none !important; }

@media (max-width: 480px){
  .loading{
    top: 8px;
    padding: 8px 10px;
    border-radius: 8px;
    max-width: calc(100vw - 16px);
  }
}

.spinner{width:18px;height:18px;border:3px solid #c5c5c5;border-top-color:#490000;border-radius:50%;animation:spin .8s linear infinite}
@keyframes spin{to{transform:rotate(360deg)}}
.submsg{font-size:.875rem;color:#6b6b6b}

/* Layout styling */
.mode-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    padding: 5px;
    border: 2px solid transparent;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.mode-option span {
    font-size: 14px;
}

.mode-option.selected {
    border-color: #00255e;
    background-color: #3498db;
}

.mode-option:hover {
    background-color: rgba(0, 123, 255, 0.466);
}

.processing-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    cursor: pointer;
    padding: 5px;
    border: 2px solid transparent;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.processing-option span {
    font-size: 14px;
}

.processing-option.selected {
    border-color: #00255e;
    background-color: #3498db;
}

.processing-option:hover {
    background-color: rgba(0, 123, 255, 0.466);
}

#processing-button-disabled {
    background-color: rgba(255, 0, 34, 0.1);
    cursor: not-allowed;
}


#input-text {
    width: 100%;
    padding: 10px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
}

.example-generation {
    height: 45px;
    width: 100%;
    display: flex;
}

#input-form-example {
    width: 70%;
}

#example-text-id {
    height: 40px;
    width: 95%;
    margin: 0px 10px 10px 10px;
}

.generate-button {
    height: 40px;
    margin: 0px 10px 0px 0px;
    background-color: #3498db;
    color: white;
    border: 2px solid transparent;
    border-radius: 5px;
}

.generate-button:hover {
    background-color: #2980b9;
}

.char-buttons {
    margin: 10px 0;
}

.char-buttons button {
    margin: 2px;
    font-size: 14px;
}

/* Oracc Layout styling */
.oracc-mode-options {
    flex-grow: 1;
    margin-top: 0px;
}

.custom-checkbox {
    display: block;
    position: relative;
    padding-left: 35px;
    margin-bottom: 12px;
    cursor: pointer;
    font-size: 16px;
    user-select: none;
}

.custom-checkbox input {
    position: absolute;
    opacity: 0;
    cursor: pointer;
    height: 0;
    width: 0;
}

.checkmark {
    position: absolute;
    top: 0;
    left: 0;
    height: 25px;
    width: 25px;
    background-color: #eee;
    border-radius: 4px;
}

.custom-checkbox:hover input ~ .checkmark {
    background-color: rgba(0, 123, 255, 0.466);
}

.custom-checkbox input:checked ~ .checkmark {
    background-color: #3498db;
}

.checkmark:after {
    content: "";
    position: absolute;
    display: none;
}

.custom-checkbox input:checked ~ .checkmark:after {
    display: block;
}

.custom-checkbox .checkmark:after {
    left: 9px;
    top: 5px;
    width: 5px;
    height: 10px;
    border: solid white;
    border-width: 0 3px 3px 0;
    transform: rotate(45deg);
}

.label-text {
    line-height: 25px;
}



/* Buttons styling */
.button-container {
    display: block;
    width: 100%;
}

.button-container-analysis {
    display: flex;
    width: 100%;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 10px;
}

.mode-group {
    display: flex;
    width: 100%;
    justify-content: center;
    align-items: center;
    gap: 20px;
    margin-top: 10px;
}

.oracc-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 0px;
}

.custom-button {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 4px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.custom-button:hover {
    background-color: #2980b9;
}

.custom-button:active {
    transform: translateY(1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.custom-button:disabled {
    background-color: rgba(255, 0, 34, 0.1);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.custom-button span {
    font-size: 14px;
}


/* query by ORACC ID */

.check-lists {
    list-style-type: none;
    padding: 0;
}

.combo { position: relative; max-width: 800px; }

#combo-input { width: 100%; padding: 8px 10px; }

#text-combo-input { width: 100%; padding: 8px 10px; margin-top: 10px; }

.combo-list {
  position: absolute; 
  left: 0; 
  right: 0; 
  z-index: 10;
  max-height: 180px; 
  overflow: auto; 
  margin: 4px 0 0; 
  padding: 0;
  list-style: none; 
  border: 1px solid #ddd; 
  background: #fff; 
  display: none;
}
.combo-list.open { display: block; }

.combo-list li { padding: 6px 10px; cursor: pointer; }

.combo-list li:hover, .combo-list li.active { background: #f0f0f0; }

.combo-list li.selected { font-weight: 600; }

.combo-list li.selected::after { content: " ✓"; }

.number-input {
    width: 60px;
    height: 25px;
    padding: 10px;
    margin-top: 5px;
    border: 1px solid #ccc;
    border-radius: 4px;
    box-sizing: border-box;
}

/* Table styling */
table {
    font-family: Noto Sans;
    font-size: 16px;
    border-collapse: collapse;
    width: 100%;
    margin-top: 20px;
}

th, td {
    border: 1px solid #ddd;
    padding: 8px;
    text-align: left;
}

th {
    background-color: #f2f2f2;
    font-weight: bold;
}

tr:nth-child(even) {
    background-color: #f9f9f9;
}

tr:hover {
    background-color: #f5f5f5;
}

/* render document styling */
.cuneiform-table {
    font-family: Noto Sans;
    font-size: 16px;
}

/* Footer styling */
.container-footer {
    width: 1500px;
    max-height: auto;
    max-width: 100%;
    margin: 0 auto;
    gap: 10px;
    padding-left: 20px;
    padding-right: 20px;
    background-color: #e2e2e2;
    align-items: center;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin: 0 auto;
}

.footer-left, .footer-center, .footer-right {
    flex: 1;
}

.footer-left {
    text-align: left;
}

.footer-center {
    text-align: center;
}

.footer-right {
    align-items: center;
    color: black;
    text-align: right;
}

.footer-content a {
    font-weight: bold;
    color: black;
    text-decoration: none;
}

.footer-content a:hover {
    color: #2980b9;
}

/* Responsive design */
@media (max-width: 768px) {
    .container {
        padding: 10px;
    }
}