/* Trip Gallery Manager - Frontend Styles */

@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&display=swap');

#tgm-root {
    font-family: 'Poppins', sans-serif;
    color: #222;
    max-width: 960px;
    margin: 0 auto;
}

/* Buttons */
#tgm-root .tgm-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 9px 20px;
    border-radius: 7px;
    font-size: .9rem;
    font-weight: 600;
    font-family: 'Poppins', sans-serif;
    cursor: pointer;
    transition: background .18s, color .18s, border-color .18s, transform .12s;
    text-decoration: none;
    line-height: 1.3;
    box-shadow: none;
}
#tgm-root .tgm-btn:active { transform: scale(.97); }

#tgm-root .tgm-btn-primary { background: #fff; color: #1E3B4C; border: 2px solid #1E3B4C; }
#tgm-root .tgm-btn-primary:hover,
#tgm-root .tgm-btn-primary:focus { background: #E6B84C; color: #1E3B4C; border-color: #E6B84C; outline: none; box-shadow: none; }

#tgm-root .tgm-btn-full { width: 100%; justify-content: center; }

#tgm-root .tgm-btn-ghost { background: transparent; color: #555; border: 1.5px solid #e2e2e8; }
#tgm-root .tgm-btn-ghost:hover,
#tgm-root .tgm-btn-ghost:focus { background: #E6B84C; color: #1E3B4C; border-color: #E6B84C; outline: none; box-shadow: none; }
#tgm-root .tgm-btn-sm { padding: 5px 14px; font-size: .82rem; }

#tgm-root .tgm-btn-lock { background: #fff; color: #1E3B4C; border: 2px solid #1E3B4C; white-space: nowrap; }
#tgm-root .tgm-btn-lock:hover,
#tgm-root .tgm-btn-lock:focus { background: #E6B84C; color: #1E3B4C; border-color: #E6B84C; outline: none; box-shadow: none; }

#tgm-root .tgm-btn-open { background: #fff; color: #1E3B4C; border: 2px solid #1E3B4C; white-space: nowrap; }
#tgm-root .tgm-btn-open:hover,
#tgm-root .tgm-btn-open:focus { background: #E6B84C; color: #1E3B4C; border-color: #E6B84C; outline: none; box-shadow: none; }

#tgm-root .tgm-link {
    background: none;
    border: none;
    color: #1E3B4C;
    text-decoration: underline;
    cursor: pointer;
    padding: 0;
    font-size: inherit;
    box-shadow: none;
}

/* Inputs */
#tgm-root .tgm-input {
    width: 100%;
    box-sizing: border-box;
    padding: 11px 14px;
    border: 1.5px solid #e2e2e8;
    border-radius: 7px;
    font-size: .95rem;
    margin-bottom: 12px;
    transition: border-color .2s;
    background: #fff;
}
#tgm-root .tgm-input:focus {
    outline: none;
    border-color: #E6B84C;
    box-shadow: 0 0 0 3px rgba(230,184,76,.15);
}
#tgm-root .tgm-error {
    color: #c0392b;
    font-size: .84rem;
    min-height: 18px;
    margin: 4px 0 0;
}

/* Trip Cards */
#tgm-root .tgm-trips { display: flex; flex-direction: column; gap: 14px; }
#tgm-root .tgm-trip-card { border: 1.5px solid #e2e2e8; border-radius: 10px; overflow: hidden; background: #fff; box-shadow: 0 2px 16px rgba(0,0,0,.08); }

#tgm-root .tgm-trip-header {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 22px;
    background: #1E3B4C;
    color: #ffffff;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: background .18s, color .18s;
    outline: none;
    box-shadow: none;
}
#tgm-root .tgm-trip-header:hover { background: #E6B84C; color: #1E3B4C; }
#tgm-root .tgm-trip-header:focus,
#tgm-root .tgm-trip-header:focus-visible,
#tgm-root .tgm-trip-header:active { background: #1E3B4C; color: #ffffff; outline: none; box-shadow: none; }

#tgm-root .tgm-trip-name { font-size: 1.05rem; font-weight: 700; }
#tgm-root .tgm-trip-chevron { font-size: .8rem; transition: transform .2s; }
#tgm-root .tgm-trip-header.is-collapsed .tgm-trip-chevron { transform: rotate(-90deg); }
#tgm-root .tgm-trip-desc { margin: 0; padding: 10px 22px; background: #f3f3f8; color: #555; font-size: .88rem; border-bottom: 1px solid #e2e2e8; }

/* Date Rows */
#tgm-root .tgm-date-list { display: block; background: #ffffff; }
#tgm-root .tgm-date-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 13px 22px;
    border-bottom: 1px solid #e2e2e8;
}
#tgm-root .tgm-date-row:last-child { border-bottom: none; }
#tgm-root .tgm-date-icon { font-size: 1rem; flex-shrink: 0; }
#tgm-root .tgm-date-name { flex: 1; font-size: .94rem; color: #333; }

/* Modal */
.tgm-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,.55);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity .2s;
}
.tgm-overlay.is-open { opacity: 1; pointer-events: all; }
.tgm-modal {
    background: #fff;
    border-radius: 14px;
    padding: 40px 36px 36px;
    max-width: 400px;
    width: calc(100% - 40px);
    position: relative;
    box-shadow: 0 8px 40px rgba(0,0,0,.2);
    text-align: center;
    transform: translateY(16px);
    transition: transform .22s;
    font-family: 'Poppins', sans-serif;
}
.tgm-overlay.is-open .tgm-modal { transform: translateY(0); }
.tgm-modal-close {
    position: absolute;
    top: 14px;
    right: 16px;
    background: none;
    border: none;
    font-size: 1.4rem;
    color: #aaa;
    cursor: pointer;
    line-height: 1;
    box-shadow: none;
}
.tgm-modal-close:hover { color: #555; background: none; }
.tgm-modal-icon { font-size: 2.4rem; margin-bottom: 8px; display: block; }
.tgm-modal-title { margin: 0 0 6px; font-size: 1.2rem; }
.tgm-modal-sub { margin: 0 0 20px; color: #666; font-size: .88rem; }
.tgm-modal .tgm-input { text-align: left; }
.tgm-modal .tgm-btn-primary { margin-top: 4px; }

/* Panel */
#tgm-root .tgm-panel-header {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}
#tgm-root .tgm-panel-title-wrap { flex: 1; }
#tgm-root .tgm-panel-title { margin: 0; font-size: 1.3rem; padding-top: 6px; }
#tgm-root .tgm-user-bar { display: flex; align-items: center; gap: 10px; padding-top: 8px; font-size: .88rem; color: #555; }

/* Tabs */
#tgm-root .tgm-tabs {
    display: flex;
    border-bottom: 2.5px solid #e2e2e8;
    margin-bottom: 26px;
}
#tgm-root .tgm-tab {
    background: none;
    border: none;
    padding: 12px 26px;
    font-size: .94rem;
    font-weight: 600;
    color: #888;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    margin-bottom: -2.5px;
    transition: color .18s, border-color .18s;
    outline: none;
    box-shadow: none;
}
#tgm-root .tgm-tab.is-active { color: #1E3B4C; border-bottom-color: #E6B84C; }
#tgm-root .tgm-tab:hover:not(.is-active) { color: #1E3B4C; border-bottom-color: #E6B84C; }

/* Gallery */
#tgm-root .tgm-masonry { columns: 3; column-gap: 12px; }
@media (max-width: 700px) { #tgm-root .tgm-masonry { columns: 2; } }
@media (max-width: 440px) { #tgm-root .tgm-masonry { columns: 1; } }

#tgm-root .tgm-photo {
    break-inside: avoid;
    position: relative;
    margin-bottom: 12px;
    border-radius: 8px;
    overflow: hidden;
    background: #eee;
}
#tgm-root .tgm-photo img { display: block; width: 100%; border-radius: 8px; transition: transform .3s ease; }
#tgm-root .tgm-photo:hover img { transform: scale(1.04); }
#tgm-root .tgm-photo-hover {
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,.38);
    display: flex;
    align-items: flex-end;
    justify-content: flex-end;
    padding: 12px;
    opacity: 0;
    transition: opacity .22s;
    border-radius: 8px;
}
#tgm-root .tgm-photo:hover .tgm-photo-hover { opacity: 1; }
#tgm-root .tgm-dl-btn {
    background: rgba(255,255,255,.95);
    color: #1E3B4C;
    padding: 6px 14px;
    border-radius: 6px;
    font-size: .82rem;
    font-weight: 700;
    text-decoration: none;
    transition: background .18s;
}
#tgm-root .tgm-dl-btn:hover { background: #fff; }
#tgm-root .tgm-gallery-empty { text-align: center; padding: 60px 20px; color: #aaa; font-size: 1rem; }
#tgm-root .tgm-loading { text-align: center; color: #aaa; padding: 40px 0; font-size: .95rem; }

/* Auth */
#tgm-root .tgm-auth { max-width: 420px; margin: 0 auto; }
#tgm-root .tgm-auth-switch { display: flex; gap: 10px; margin-bottom: 24px; }
#tgm-root .tgm-auth-tab { background: none; border: 2px solid #e2e2e8; padding: 8px 22px; border-radius: 8px; font-size: .9rem; font-weight: 600; color: #777; cursor: pointer; transition: all .18s; box-shadow: none; }
#tgm-root .tgm-auth-tab.is-active { border-color: #E6B84C; color: #1E3B4C; background: #E6B84C; }
#tgm-root .tgm-auth-pane h3 { margin-top: 0; margin-bottom: 18px; font-size: 1.05rem; }

/* Upload */
#tgm-root .tgm-upload { max-width: 540px; margin: 0 auto; }
#tgm-root .tgm-uploader-header { margin-bottom: 20px; }
#tgm-root .tgm-uploader-header h3 { margin: 0 0 4px; }
#tgm-root .tgm-uploader-header p { margin: 0; color: #666; font-size: .88rem; }

#tgm-root .tgm-dropzone {
    border: 2.5px dashed #c8c8d8;
    border-radius: 10px;
    padding: 10px;
    text-align: center;
    cursor: pointer;
    transition: border-color .2s, background .2s;
}
#tgm-root .tgm-dropzone.is-over { border-color: #1E3B4C; background: #f0f4f6; }
#tgm-root .tgm-dropzone-inner { padding: 30px 20px; }
#tgm-root .tgm-drop-icon { font-size: 2rem; display: block; margin-bottom: 8px; }
#tgm-root .tgm-dropzone-inner p { margin: 4px 0; color: #555; font-size: .9rem; }
#tgm-root .tgm-drop-or { color: #aaa; font-size: .82rem; }
#tgm-root .tgm-drop-hint { font-size: .78rem; color: #aaa; margin: 8px 0 0; }

#tgm-root .tgm-queue { margin: 16px 0 12px; display: flex; flex-direction: column; gap: 8px; }
#tgm-root .tgm-queue-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 12px;
    background: #f7f8fa;
    border-radius: 7px;
    font-size: .84rem;
    color: #444;
}
#tgm-root .tgm-queue-thumb { width: 42px; height: 42px; object-fit: cover; border-radius: 5px; flex-shrink: 0; }
#tgm-root .tgm-queue-name { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
#tgm-root .tgm-queue-size { color: #999; flex-shrink: 0; }

#tgm-root #tgm-upload-actions { display: flex; gap: 10px; margin-bottom: 12px; }
#tgm-root .tgm-upload-msg { color: #E6B84C; font-size: .88rem; font-weight: 600; min-height: 20px; }

/* Disclaimer checkbox */
#tgm-root .tgm-disclaimer-label {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: .82rem;
    color: #555;
    margin-bottom: 14px;
    cursor: pointer;
    line-height: 1.5;
}
#tgm-root .tgm-disclaimer-label input[type="checkbox"] {
    margin-top: 3px;
    flex-shrink: 0;
    width: 16px;
    height: 16px;
    accent-color: #1E3B4C;
    cursor: pointer;
}

/* Forgot password / success */
#tgm-root .tgm-forgot-wrap { margin: 8px 0 0; font-size: .82rem; }
#tgm-root .tgm-success { color: #0f7960; font-size: .88rem; font-weight: 600; min-height: 18px; margin: 4px 0 0; }

/* Password reset form */
#tgm-root .tgm-reset-wrap {
    max-width: 420px;
    margin: 40px auto;
    background: #fff;
    border: 1.5px solid #e2e2e8;
    border-radius: 10px;
    padding: 36px;
    box-shadow: 0 2px 16px rgba(0,0,0,.08);
}
#tgm-root .tgm-reset-wrap h3 { margin-top: 0; margin-bottom: 20px; font-size: 1.1rem; }
