/*-----------------------------------------------------------------------------
 * A collection is a bunch of photos belonging together, for instance an album
 * or search results, that can be presented in three ways: gallery, list or
 * single view.
 *-----------------------------------------------------------------------------
 */


/* Note: The collection-header resides in main-header */

/* Layout */   /* TODO: this is used by search too => make main-header with title and toolbar 
.collection-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}
    */

/* Title */
.collection-header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.back-button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: #f0f0f0;
  color: #666;
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}

.back-button:hover {
  background: var(--accent-color);
  color: white;
}

.collection-title {
  font-family: var(--title-font);
  font-size: var(--title-size);
  font-variant: small-caps;
  font-weight: var(--title-weight);
  letter-spacing: 0;
  margin: 0;
}

/* Toolbar */
.collection-toolbar {
   display: flex;
   gap: 0px;
   align-items: center;
}

/* The different views. The gallery view is in a separate file, gallery.css since it is
 * not only used in collections, but also to show for instance albums (not a collection,
 * although you could argue that it is a collection of thumbnails, but then, we don't want
 * to show these in list or single view.
 */



/*--------------------------------------------------------------------------
 * Photo gallery
 */

.view-list {
}

.view-list-item {
    position: relative;
    margin-bottom: 10px;
}

.view-list-item img {
    width: 100%;
    object-fit: cover;
    display: block;
}

.view-single {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    /* Fixed height so arrows stay in same position regardless of photo size */
    height: calc(100vh - 180px);
    width: 100%;
    text-align: center;
}

.single-photo-container {
    position: relative;
    display: block;
    width: fit-content;
    margin: 0 auto;
}

.view-single img {
    /* Constrain to container width and viewport height */
    max-width: 100%;
    max-height: calc(100vh - 180px);
    width: auto;
    height: auto;
    object-fit: contain;
    display: block;
}

/* Use dvh for browsers that support it (better on mobile) */
@supports (height: 100dvh) {
    .view-single img {
        max-height: calc(100dvh - 180px);
    }
}

/* Single photo navigation */
.single-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.4);
    color: white;
    font-size: var(--icon-md);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, opacity 0.2s;
    z-index: 10;
}

.single-nav:hover {
    background: rgba(0, 0, 0, 0.6);
}

.single-nav:disabled {
    opacity: 0.3;
    cursor: default;
}

.single-nav-prev {
    left: 16px;
}

.single-nav-next {
    right: 16px;
}

/* Hide navigation arrows on touch devices (they can swipe) */
@media (hover: none) {
    .single-nav {
        display: none;
    }
}

.single-photo-counter {
    position: absolute;
    bottom: 8px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.5);
    color: white;
    padding: 4px 6px;
    border-radius: 4px;
    font-size: var(--label-size);
    z-index: 10;
    opacity: 0.4;
    transition: opacity 0.2s ease;
}

.single-photo-container:hover .single-photo-counter {
    opacity: 1;
}


/* A gallery shows a number of photos, whether it are albums thumbnails or a collection of
 * photos (album, by tag, search result) in a number of rows with a specific layout as
 * defined in config.php (GALLERY_ROW_HEIGHT).
 * 
 * ACTUALLY: this file not only specifies gallery view, but also others like list and single view.
 Maybe rename to view.css?
 */

.gallery {
    display: flex;
    flex-direction: column;
    gap: var(--gallery-gap);
    width: 100%;
    box-sizing: border-box;
}

.gallery-row {
    display: flex;
    gap: var(--gallery-gap);
    width: 100%;
}

.gallery-item {
    height: var(--gallery-row-height);
    overflow: hidden;
    position: relative;        /* important for overlay */
    border-radius: 4px;
    height: var(--gallery-row-height);
    display: block;  
    flex-basis: 60%;
    flex-shrink: 0;
    cursor: pointer;
}

.gallery-item.gallery-placeholder {
    cursor: default;
}

.selection-overlay {
    position: absolute;
    top: 8px;
    right: 8px;
    z-index: 2;
    pointer-events: none;
    opacity: 0;

  display: flex;
  align-items: flex-start;
  justify-content: flex-end;
  padding: 8px;

  /*background: rgba(0, 0, 0, 0.25);*/
  transition: opacity 0.15s ease;
}

.selection-overlay input[type="checkbox"] {
  width: 20px;
  height: 20px;
  accent-color: var(--accent-color);
  background: white;
  border-radius: 4px;
}

.selection-mode .selection-overlay {
  opacity: 1;
  pointer-events: auto;
}

/* Photo actions overlay (likes + comments) */
.photo-actions-overlay {
    position: absolute;
    bottom: 8px;
    left: 8px;
    z-index: 2;
    display: flex;
    gap: 2px;
    background: rgba(0, 0, 0, 0.5);
    border-radius: 4px;
    padding: 4px 6px;
    opacity: 0.4;
    transition: opacity 0.2s ease;
}

.gallery-item:hover .photo-actions-overlay,
.view-list-item:hover .photo-actions-overlay,
.single-photo-container:hover .photo-actions-overlay,
.photo-actions-overlay.visible,
.photo-actions-overlay:focus-within {
    opacity: 1;
}

.like-btn,
.comment-btn,
.info-btn,
.feature-btn {
    display: flex;
    align-items: center;
    gap: 4px;
    background: none;
    border: none;
    border-radius: 4px;
    padding: 2px 6px;
    cursor: pointer;
    color: white;
    font-size: var(--body-size);
    transition: background 0.15s ease, transform 0.1s ease;
}

.like-btn:hover,
.comment-btn:hover,
.info-btn:hover,
.feature-btn:hover {
    background: rgba(255, 255, 255, 0.15);
}

.like-btn:active,
.comment-btn:active,
.info-btn:active,
.feature-btn:active {
    transform: scale(0.95);
}

.like-btn i,
.comment-btn i,
.info-btn i,
.feature-btn i {
    font-size: var(--body-size);
    transition: color 0.15s ease;
}

.like-btn.liked i {
    color: #ef4444;
}

.feature-btn.featured i {
    color: #22c55e;
}

.like-btn .like-count,
.comment-btn .comment-count {
    font-size: var(--label-size);
    min-width: 0;
}

.like-btn .like-count:empty,
.comment-btn .comment-count:empty {
    display: none;
}

/* Double-tap heart animation */
.double-tap-heart {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0);
    pointer-events: none;
    z-index: 10;
    animation: heartPop 0.8s ease-out forwards;
}

.double-tap-heart i {
    font-size: 80px;
    color: #ef4444;
    filter: drop-shadow(0 2px 8px rgba(0, 0, 0, 0.3));
}

.double-tap-heart.unlike i {
    color: #9ca3af;
}

@keyframes heartPop {
    0% {
        transform: translate(-50%, -50%) scale(0);
        opacity: 1;
    }
    15% {
        transform: translate(-50%, -50%) scale(1.2);
    }
    30% {
        transform: translate(-50%, -50%) scale(0.95);
    }
    45% {
        transform: translate(-50%, -50%) scale(1);
    }
    80% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 1;
    }
    100% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0;
    }
}

/* Comment Modal */
.comment-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
}

.comment-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
}

.comment-modal-content {
    position: relative;
    background: white;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    max-height: 80vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.comment-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    border-bottom: 1px solid #eee;
}

.comment-modal-header h3 {
    margin: 0;
    font-size: var(--title-size);
    font-weight: 600;
}

.comment-modal-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-color);
    color: var(--text-on-accent, white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: background 0.15s, transform 0.15s;
}

.comment-modal-close:hover {
    background: var(--accent-color-hover);
    transform: scale(1.1);
}

.comment-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 16px 20px;
    min-height: 200px;
    max-height: 400px;
}

.comment-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.comment-loading {
    text-align: center;
    color: #666;
    padding: 40px 0;
}

.comment-empty {
    text-align: center;
    color: #999;
    padding: 40px 0;
}

.comment-item {
    display: flex;
    gap: 12px;
}

.comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #e0e0e0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    font-size: var(--icon-sm);
    flex-shrink: 0;
}

.comment-content {
    flex: 1;
    min-width: 0;
}

.comment-header {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
}

.comment-author {
    font-weight: 600;
    font-size: var(--body-size);
    color: #333;
}

.comment-time {
    font-size: var(--label-size);
    color: #999;
}

.comment-text {
    font-size: var(--body-size);
    color: #333;
    line-height: 1.4;
    word-wrap: break-word;
}

.comment-modal-footer {
    padding: 12px 20px;
    border-top: 1px solid #eee;
}

.comment-form {
    display: flex;
    gap: 10px;
}

.comment-form input {
    flex: 1;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: 20px;
    font-size: var(--body-size);
    outline: none;
    transition: border-color 0.15s;
}

.comment-form input:focus {
    border-color: var(--accent-color);
}

.comment-submit {
    background: var(--accent-color);
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: filter 0.15s;
}

.comment-submit:hover {
    filter: brightness(1.1);
}

.comment-submit:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.comment-login-prompt {
    text-align: center;
    color: #666;
    font-size: var(--body-size);
}

.comment-login-prompt a {
    color: var(--accent-color);
    text-decoration: none;
}

.comment-login-prompt a:hover {
    text-decoration: underline;
}

.like-btn .like-count:empty {
    display: none;
}

.gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.gallery-placeholder {
   background: transparent;
}


/*--------------------------------------------------------------------------
 * Album gallery
 */

.gallery-item .album-overlay {
   position: absolute;
   bottom: 0;
   left: 0;
   width: 100%;
   height: 40px;
   background-color: rgba(0,0,0,0.6);
   color: #fff;
   display: flex;
   align-items: center;
   justify-content: center;
   font-family: var(--title-font);
   font-size: var(--body-size);
   box-sizing: border-box;
   font-variant: small-caps;
}


.select-dropdown {
    position: relative;
    display: inline-block;
    z-index: 1;
}

/* Select button text */
#select-mode {
    padding-right: 8px;
}

/* Dropdown toggle arrow - larger clickable area */
.dropdown-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    margin: -8px -12px -8px 0;
    border-left: 1px solid rgba(255, 255, 255, 0.3);
    cursor: pointer;
    border-radius: 0 4px 4px 0;
}

.dropdown-toggle:hover {
    background: rgba(255, 255, 255, 0.15);
}

.select-dropdown-menu {
    position: absolute;
    top: 100%;
    right: 0;
    min-width: 160px;
    background: #fff;
    border: 1px solid #ccc;
    box-shadow: 0 4px 12px rgba(0,0,0,.15);
    border-radius: 6px;
    padding: 0px;
    z-index:9999;
    font-family: var(--button-font);
    font-size: var(--button-sm-size);
    font-weight: var(--body-weight);
}

.select-dropdown-menu[hidden] {
    display: none;
}

.select-dropdown[aria-expanded="true"] .select-dropdown-menu {
    display: block;
}

.select-dropdown-title {
  padding: 8px 16px;
  font-weight: normal;
  border-bottom: 1px solid #eee;
  background-color: var(--accent-color);
  color: white;
}

/* Menu items */
.select-dropdown-item {
  width: 100%;
  padding: 8px 16px;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  font-family: var(--button-font);
  font-size: var(--button-sm-size);
  font-weight: var(--body-weight);
}

/* Highlight on hover */
.select-dropdown-item:hover,
.select-dropdown-item:focus {
  background-color: #f0f0f0;
}

/* Empty state for no photos */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 60px 20px;
  text-align: center;
  color: #666;
}

.empty-state p {
  margin: 0;
  font-size: var(--body-size);
}

.empty-state .empty-hint {
  margin-top: 10px;
  font-size: var(--body-size);
  color: #999;
}

/* Loading overlay for downloads */
.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 10000;
}

.loading-content {
  background: white;
  padding: 40px 60px;
  border-radius: 12px;
  text-align: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.loading-content i {
  font-size: var(--icon-lg);
  color: var(--accent-color);
  margin-bottom: 20px;
}

.loading-content p {
  margin: 0;
  font-size: var(--body-size);
  color: #333;
}

.loading-content .loading-hint {
  margin-top: 10px;
  font-size: var(--label-size);
  color: #999;
}

/* Map View */
.view-map {
    width: 100%;
    height: calc(100vh - 180px); /* Full viewport minus header and toolbar */
    min-height: 400px;
    position: relative;
}

#map-container {
    width: 100%;
    height: 100%;
    border-radius: 8px;
    overflow: hidden;
}

.map-info {
    position: absolute;
    top: 10px;
    right: 10px;
    background: white;
    padding: 6px 8px 6px 12px;
    border-radius: 4px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.2);
    font-size: var(--label-size);
    color: #666;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 8px;
}

.map-info.warning {
    background: #fff3cd;
    color: #856404;
}

/* Leaflet popup customization */
.leaflet-popup-content {
    margin: 0;
    padding: 0;
}

.map-popup {
    text-align: center;
}

.map-popup img {
    max-width: 200px;
    max-height: 150px;
    border-radius: 4px;
    display: block;
}

.map-popup-name {
    margin-top: 8px;
    font-size: var(--label-size);
    color: #666;
    max-width: 200px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.map-popup-nav-bar {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 8px;
}

.map-popup-nav {
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 50%;
    background: #f0f0f0;
    color: #333;
    font-size: var(--label-size);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.15s;
}

.map-popup-nav:hover:not(:disabled) {
    background: var(--accent-color);
    color: white;
}

.map-popup-nav:disabled {
    opacity: 0.3;
    cursor: default;
}

.map-popup-counter {
    font-size: var(--label-size);
    color: #666;
    min-width: 40px;
    text-align: center;
}

/* Marker cluster styling */
.marker-cluster {
    background-clip: padding-box;
    border-radius: 20px;
}

.marker-cluster div {
    width: 30px;
    height: 30px;
    margin-left: 5px;
    margin-top: 5px;
    text-align: center;
    border-radius: 15px;
    font: 12px "Helvetica Neue", Arial, Helvetica, sans-serif;
    font-weight: bold;
}

.marker-cluster span {
    line-height: 30px;
}

.marker-cluster-small {
    background-color: rgba(181, 226, 140, 0.6);
}
.marker-cluster-small div {
    background-color: rgba(110, 204, 57, 0.6);
}

.marker-cluster-medium {
    background-color: rgba(241, 211, 87, 0.6);
}
.marker-cluster-medium div {
    background-color: rgba(240, 194, 12, 0.6);
}

.marker-cluster-large {
    background-color: rgba(253, 156, 115, 0.6);
}
.marker-cluster-large div {
    background-color: rgba(241, 128, 23, 0.6);
}

/* Map loading state */
.map-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    color: #666;
}

.map-loading i {
    margin-right: 10px;
}

/* Map settings control (inside map-info) */
.map-settings-btn {
    width: 24px;
    height: 24px;
    border: none;
    border-radius: 3px;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #999;
    font-size: var(--label-size);
    padding: 0;
    flex-shrink: 0;
}

.map-settings-btn:hover {
    background: rgba(0, 0, 0, 0.08);
    color: #666;
}

.map-settings-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 4px;
    background: white;
    border-radius: 4px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2);
    padding: 8px 0;
    min-width: 180px;
}

.map-setting-label {
    padding: 8px 12px 4px;
    font-size: var(--label-size);
    color: #666;
    font-weight: 500;
}

.map-setting-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 6px 12px;
    cursor: pointer;
    font-size: var(--label-size);
    color: #333;
}

.map-setting-option:hover {
    background: #f4f4f4;
}

.map-setting-option input[type="radio"] {
    margin: 0;
    cursor: pointer;
}

/*-----------------------------------------------------------------------------
 * Slideshow
 *-----------------------------------------------------------------------------
 */

.slideshow-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: #000;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slideshow-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.slideshow-controls {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: center;
    gap: 20px;
    opacity: 0;
    transition: opacity 0.3s;
}

.slideshow-overlay:hover .slideshow-controls {
    opacity: 1;
}

.slideshow-btn {
    width: 48px;
    height: 48px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    font-size: var(--icon-md);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, transform 0.2s;
}

.slideshow-btn:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: scale(1.1);
}

.slideshow-btn-large {
    width: 64px;
    height: 64px;
    font-size: var(--hero-size);
}

.slideshow-counter {
    position: absolute;
    bottom: 40px;
    right: 40px;
    color: rgba(255, 255, 255, 0.7);
    font-size: var(--body-size);
    opacity: 0;
    transition: opacity 0.3s;
}

.slideshow-overlay:hover .slideshow-counter {
    opacity: 1;
}

.slideshow-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: white;
    font-size: var(--icon-md);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    opacity: 0;
}

.slideshow-overlay:hover .slideshow-close {
    opacity: 1;
}

.slideshow-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* =====================================================================================================================
   Photo Info Modal
===================================================================================================================== */

.info-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.info-modal-content {
    max-width: 400px;
    z-index: 1;
}

.info-modal-body {
    padding: 16px 20px;
    min-height: auto;
    max-height: 500px;
}

.info-modal-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-color);
    color: var(--text-on-accent, white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: background 0.15s, transform 0.15s;
}

.info-modal-close:hover {
    background: var(--accent-color-hover);
    transform: scale(1.1);
}

.info-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.info-row {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.info-label {
    font-size: var(--label-size);
    color: #888;
    display: flex;
    align-items: center;
    gap: 6px;
}

.info-label i {
    width: 14px;
    text-align: center;
}

.info-value {
    font-size: var(--body-size);
    color: #333;
    padding-left: 20px;
}

.info-divider {
    height: 1px;
    background: #eee;
    margin: 8px 0;
}

.info-section-title {
    font-size: var(--label-size);
    font-weight: 600;
    text-transform: uppercase;
    color: #999;
    letter-spacing: 0.5px;
}

/* =====================================================================================================================
   Share Modal
===================================================================================================================== */

.share-modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
}

.share-modal-content {
    max-width: 450px;
    z-index: 1;
}

.share-modal-body {
    padding: 20px;
    min-height: auto;
}

.share-modal-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-color);
    color: var(--text-on-accent, white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: background 0.15s, transform 0.15s;
}

.share-modal-close:hover {
    background: var(--accent-color-hover);
    transform: scale(1.1);
}

.share-options {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.share-options label {
    font-size: var(--body-size);
    color: #666;
}

.share-select {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: var(--body-size);
    background: white;
    cursor: pointer;
}

.share-select:focus {
    outline: none;
    border-color: var(--accent-color);
}

.share-result {
    background: #f8f9fa;
    padding: 16px;
    border-radius: 8px;
}

.share-url-container {
    display: flex;
    gap: 8px;
    align-items: center;
}

.share-url {
    flex: 1;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: var(--body-size);
    background: white;
    color: #333;
}

.share-url:focus {
    outline: none;
    border-color: var(--accent-color);
}

.share-hint {
    margin: 12px 0 0;
    font-size: var(--label-size);
    color: #888;
    text-align: center;
}

.share-loading {
    text-align: center;
    padding: 20px;
    color: #666;
}

.share-loading i {
    margin-right: 8px;
}

.share-error {
    color: #dc3545;
}

.share-error i {
    margin-right: 8px;
}

/* Login Required Modal */
.login-modal-content {
    max-width: 340px;
    background: var(--bg-card, white);
}

.login-modal-close {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: var(--accent-color);
    color: var(--text-on-accent, white);
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: background 0.15s, transform 0.15s;
}

.login-modal-close:hover {
    background: var(--accent-color-hover);
    transform: scale(1.1);
}

.login-modal-body {
    text-align: center;
    min-height: auto;
    padding: 24px 20px 20px;
}

.login-modal-body p {
    margin: 0 0 20px;
    color: var(--text-secondary, #666);
    font-size: var(--body-size);
}

.login-modal-btn {
    display: inline-block;
    background: var(--accent-color);
    color: var(--text-on-accent, white) !important;
    padding: 12px 32px;
    border-radius: 6px;
    text-decoration: none;
    font-weight: 500;
    transition: background 0.15s;
}

.login-modal-btn:hover {
    background: var(--accent-color-hover);
}

