/* === 🔊 Highlight Speak on Hover === */
/* Adds yellow background and dashed outline when speech highlighting is active */
.highlight-speak {
    background-color: yellow !important;
    outline: 2px dashed #000 !important;
}

/* === 📏 Text Spacing for Accessibility === */
/* Increases line height, letter spacing, and word spacing for readability */
body.text-spacing * {
    line-height: 1.8 !important;
    letter-spacing: 0.12em !important;
    word-spacing: 0.16em !important;
}

/* === 🔤 Dyslexic Font Override === */
/* Applies dyslexia-friendly fonts like Comic Sans or OpenDyslexic */
body.dyslexic-font * {
    font-family: 'Comic Sans MS', 'OpenDyslexic', Arial, sans-serif !important;
}

/* === 🎯 Widget Background When Enabled === */
/* Changes widget background when any toggle is active */
#accessibility-widget.solid {
    background-color: #0050a0 !important;
    opacity: 1 !important;
}

/* === 🎯 Widget & Toggle Reset === */
/* Prevents unwanted styling from global themes, filters, or contrast modes */
#accessibility-widget,
#accessibility-widget *,
#accessibility-toggle {
    background-color: initial !important;
    color: inherit !important;
    filter: none !important;
    -webkit-filter: none !important;
}

#accessibility-widget {
    background-color: #0050a0 !important;
    color: white !important;
}

#accessibility-widget button,
#accessibility-widget select {
    background-color: white !important;
    color: #0050a0 !important;
}

#accessibility-widget button:hover {
    background-color: #f0f0f0 !important;
}

/* === 🪟 Modal Popup Styles === */
/* Styling for the popup modal window with 3D and bevel effects */
#popupModal {
    display: none;
    position: fixed;
    top: 5%;
    left: 50%;
    transform: translate(-50%, 0);
    background: linear-gradient(145deg, #ffffff, #f9f9f9);
    color: #000;
    padding: 2rem;
    border: 2px solid #888;
    z-index: 9999;
    max-width: 80%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow:
        inset 2px 2px 5px #ccc,
        inset -2px -2px 5px #fff,
        0 6px 15px rgba(0,0,0,0.3),
        0 0 10px rgba(0,0,0,0.1);
    border-radius: 12px;
    font-family: 'Segoe UI', sans-serif;
}

/* === 🆗 Popup Buttons === */
/* Adds 3D-style bevel and hover effects to modal buttons */
#popupModal button {
    background: linear-gradient(to bottom, #ffffff, #e0e0e0);
    border: 1px solid #aaa;
    border-radius: 6px;
    padding: 0.5rem 1rem;
    font-weight: bold;
    box-shadow:
        inset 0 1px 0 #fff,
        inset 0 -1px 0 #ccc,
        2px 2px 5px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: all 0.2s ease-in-out;
}

#popupModal button:hover {
    background: linear-gradient(to bottom, #f1f1f1, #d0d0d0);
    box-shadow:
        inset 0 1px 0 #eee,
        inset 0 -1px 0 #bbb,
        1px 1px 3px rgba(0, 0, 0, 0.25);
}

#popupModal button:active {
    box-shadow:
        inset 1px 1px 3px rgba(0, 0, 0, 0.3),
        0 1px 2px rgba(255, 255, 255, 0.6);
    background: linear-gradient(to bottom, #dcdcdc, #f4f4f4);
}

/* === 📱 Responsive Modal Adjustment === */
@media (max-width: 768px) {
    #popupModal {
        max-width: 95%;
        padding: 1.5rem;
    }
}

/* === 📐 Compact Feature Section === */
/* Reduces padding and margin spacing in feature section */
section.features13 {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}
section.features13 .mbr-section-content {
    margin-top: 0 !important;
    margin-bottom: 0 !important;
}
section.features13 .item {
    margin-bottom: 0.5rem !important;
}
section.features13 .item-wrapper {
    padding-bottom: 0 !important;
    margin-bottom: 0 !important;
}

/* === 🟢 SCROLLING BANNER === */
.ticker-wrap {
    position: relative;
    overflow: hidden;
    background: rgba(255, 255, 255, 0.85);
    color: #b81c5c;
    padding: 1rem 0;
    width: 100%;
    font-size: 1.8rem;
    z-index: 1000;
    border: 1px solid #ccc;
    box-shadow:
        0 4px 6px rgba(0, 0, 0, 0.1),
        0 8px 20px rgba(0, 0, 0, 0.1);
    border-radius: 12px;
    backdrop-filter: blur(6px);
    margin-top: 0.5rem;
}
.ticker {
    display: inline-block;
    white-space: nowrap;
    animation: scroll var(--scroll-speed, 20s) linear infinite;
}
.ticker__item {
    display: inline-block;
    padding: 0 2rem;
    font-weight: bold;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}
@keyframes scroll {
    0% { transform: translateX(100%); }
    100% { transform: translateX(-100%); }
}

/* === 🧷 Accessibility Toggle Button === */
#accessibility-toggle {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 70px;
    height: 70px;
    background: transparent;
    border: none;
    z-index: 10000;
    cursor: pointer;
}
#accessibility-toggle img {
    width: 100%;
    height: 100%;
}

/* === 🧰 Accessibility Widget Container === */
#accessibility-widget {
    position: fixed;
    bottom: 0px;
    right: 20px;
    margin-bottom: 90px;
    background: #0050a0;
    color: white;
    border-radius: 10px;
    padding: 12px;
    z-index: 9999;
    font-size: 14px;
    display: none;
    width: 220px;
    box-shadow: 2px 2px 8px rgba(0,0,0,0.3);
    transition: transform 0.3s ease, opacity 0.3s ease;
    transform: translateY(20px);
    opacity: 0;
    pointer-events: none;
}
#accessibility-widget.show {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
}
#accessibility-widget button,
#accessibility-widget select {
    display: block;
    margin: 6px 0;
    width: 100%;
    padding: 6px;
    background-color: white;
    color: #0050a0;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
}
#accessibility-widget button:hover {
    background-color: #f0f0f0;
}

/* === 🌓 High Contrast Mode === */
body.high-contrast {
    background-color: #000 !important;
    color: #fff !important;
}
body.high-contrast * {
    background: transparent !important;
    color: white !important;
    border-color: white !important;
}

/* === 🔍 Font Size Modes === */
html.large-text *, body.large-text * {
    font-size: 115% !important;
}
html.small-text *, body.small-text * {
    font-size: 90% !important;
}

/* === 🎨 Color Filters === */
body.filter-yellow {
    background-color: #fff8dc !important;
    color: #000 !important;
}
body.filter-blue {
    background-color: #e6f7ff !important;
    color: #000 !important;
}
body.filter-cream {
    background-color: #fdfde7 !important;
    color: #000 !important;
}
html.filter-grayscale, body.filter-grayscale {
    -webkit-filter: grayscale(100%);
    filter: grayscale(100%);
}
body[class^="filter-"] *, body[class*=" filter-"] * {
    background-color: transparent !important;
    color: inherit !important;
}

/* === 🔐 Admin Login Button === */
#admin-login-btn {
    position: fixed;
    bottom: 0px;
    left: 20px;
    background-color: #444;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 6px 10px;
    font-size: 14px;
    cursor: pointer;
    z-index: 9999;
    opacity: 0.7;
}
#admin-login-btn:hover {
    opacity: 1;
}

/* === ✏️ Shortcut Modal Styles === */
.shortcut-modal {
    position: fixed;
    top: 10%;
    left: 50%;
    transform: translateX(-50%);
    background: #fff;
    border: 1px solid #ccc;
    padding: 1.5rem;
    z-index: 9999;
    width: 300px;
    box-shadow: 0 0 10px rgba(0,0,0,0.2);
    display: none;
}
.shortcut-modal input {
    width: 100%;
    margin-bottom: 0.5rem;
    padding: 5px;
}
.shortcut-modal img {
    max-width: 100%;
    height: auto;
    margin-bottom: 0.5rem;
}

/* === 🧱 Shortcut Grid Styles === */
#shortcutGrid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    margin-top: 20px;
    gap: 40px 30px;
}

.shortcut {
    display: flex !important;
    flex-direction: column !important;
    justify-content: flex-end !important;
    align-items: center !important;
    text-align: center !important;
    padding: 10px !important;
    width: 100% !important;
    max-width: 200px !important;
    min-height: 260px !important;
    position: relative !important;
}
.shortcut img {
    width: 200px !important;
    height: 200px !important;
    object-fit: contain !important;
    image-rendering: auto !important;
    display: block !important;
    margin: 0 auto 15px !important;
    max-width: none !important;
}
.shortcut img {
  /* existing styles... */
  transition: transform 0.3s ease;
}

.shortcut:hover img {
  transform: scale(1.05);
}

.shortcut span {
    display: block;
    font-weight: bold;
    font-size: 1.25rem;
    text-align: center;
    color: var(--shortcut-text-color) !important;
    margin-top: 10px;
    min-height: 2.4em;
    line-height: 1.4;
}


/* === 🛠️ Edit/Delete Shortcut Buttons (Improved Clickability) === */
.edit-icon, .delete-icon {
    position: absolute;
    width: 36px;
    height: 36px;
    background: #fff;
    border-radius: 50%;
    border: 1px solid #ccc;
    font-size: 20px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 10;
    transition: background-color 0.2s ease, border-color 0.2s ease, transform 0.1s ease;
}

.edit-icon {
    top: 8px;
    right: 8px;
}

.edit-icon:hover {
    background-color: #dff0ff;
    border-color: #00b1eb;
    transform: scale(1.15);
}

.delete-icon {
    top: 8px;
    left: 8px;
}

.delete-icon:hover {
    background-color: #fdd;
    border-color: #f66;
    transform: scale(1.15);
}

.shortcut.admin-edit .edit-icon,
.shortcut.admin-edit .delete-icon {
    display: flex;
}



/* === 📱 Responsive Grid Columns === */
#shortcutGrid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 40px 30px;
    padding: 20px;
    justify-items: center;
    max-width: 100%;
}
@media (max-width: 992px) {
    #shortcutGrid {
        grid-template-columns: repeat(3, 1fr);
    }
}
@media (max-width: 576px) {
    #shortcutGrid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* === 📎 3D Accessibility Header Button === */
.accessibility-header-button {
    background-color: #0050a0;
    color: white;
    font-weight: bold;
    padding: 0.5rem 1rem;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.3),
        inset 0 -1px 0 rgba(0, 0, 0, 0.2),
        0 4px 6px rgba(0, 0, 0, 0.3);
    transition: all 0.2s ease-in-out;
}
.accessibility-header-button:hover {
    transform: translateY(-1px);
    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.4),
        inset 0 -1px 0 rgba(0, 0, 0, 0.1),
        0 6px 10px rgba(0, 0, 0, 0.35);
}
/* === 🖱️ Hover effect for shortcut icons === */
.shortcut:hover {
  transform: translateY(-5px) scale(1.03);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  background-color: #f9f9f9;
  border-radius: 12px;
}
/* === 🧭 Vertical Edge Tabs === */
.edge-tab {
  position: fixed;
  right: 0;
  top: 40%;
  transform: rotate(-90deg);
  transform-origin: right top;
  background-color: #08b4ec;
  color: white;
  padding: 10px 20px;
  font-weight: bold;
  font-size: 14px;
  border-radius: 10px 10px 0 0;
  cursor: pointer;
  z-index: 10001;
  box-shadow: -2px 2px 6px rgba(0,0,0,0.2);
  transition: background 0.3s ease;
}

#support-tab {
  top: 48%;
}

.edge-tab:hover {
  background-color: #00a0d1;
}

/* === 📩 Sliding Edge Panel === */
.edge-panel {
  position: fixed;
  top: 10%;
  right: -320px;
  width: 300px;
  background: white;
  border: 2px solid #08b4ec;
  border-radius: 10px 0 0 10px;
  padding: 15px;
  box-shadow: -4px 4px 10px rgba(0,0,0,0.2);
  transition: right 0.4s ease;
  z-index: 10000;
}

.edge-panel.show {
  right: 0;
}

.edge-panel h3 {
  margin-top: 0;
  color: #08b4ec;
}

.edge-panel input,
.edge-panel textarea {
  width: 100%;
  margin: 8px 0;
  padding: 8px;
  border: 1px solid #ccc;
  border-radius: 6px;
  font-size: 14px;
}

.edge-panel button {
  width: 100%;
  background: #08b4ec;
  color: white;
  padding: 10px;
  border: none;
  border-radius: 6px;
  font-weight: bold;
  cursor: pointer;
}

.edge-panel button:hover {
  background: #00a0d1;
}

.emoji-rating {
  text-align: center;
  font-size: 28px;
  margin-bottom: 10px;
}

.emoji-rating span {
  margin: 0 5px;
  cursor: pointer;
}

.emoji-rating span.selected {
  transform: scale(1.3);
}

/* Force wider Google Translate dropdown */
.goog-te-combo {
  min-width: 200px;
  max-width: 260px;
  font-size: 14px;
}

/* Optionally increase padding around the container */
#google_translate_element {
  margin-right: 10px;
}

.goog-te-menu-frame.skiptranslate {
  width: 260px !important;
  height: auto !important;
  overflow: visible !important;
}
/* 🟢 Accessibility grayscale mode */
.filter-grayscale {
  filter: grayscale(100%);
}
#accessibility-widget {
  position: fixed;
  bottom: 100px;
  right: 20px;
  z-index: 9999;
  background: white;
  padding: 1rem;
  border: 2px solid #ccc;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0,0,0,0.1);
  filter: none !important; /* Prevent filters like grayscale */
}
:root {
  --shortcut-text-color: #b81c5c;
}

.shortcut span {
  color: var(--shortcut-text-color) !important;
}


