/* Art Collection - Fayez Sarofim Style */

:root {
    --gold: #C4922E;
    --gold-dark: #A67B1F;
    --bronze: #CD7F32;
    --text-dark: #333;
    --text-light: #666;
    --bg-light: #f9f9f9;
    --bg-white: #fff;
    --border: #e0e0e0;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Georgia', 'Times New Roman', serif;
    color: var(--text-dark);
    background: var(--bg-white);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.site-header {
    border-bottom: 1px solid var(--border);
    padding: 2rem 3rem;
}

.header-content {
    max-width: 1400px;
    margin: 0 auto;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-title {
    font-size: 1.5rem;
    font-weight: normal;
}

.site-title a {
    text-decoration: none;
    color: inherit;
}

.title-art {
    color: var(--text-dark);
    letter-spacing: 0.2em;
    font-weight: normal;
}

.title-of {
    font-style: italic;
    color: var(--text-light);
    margin: 0 0.5rem;
}

.title-name {
    color: var(--gold);
    letter-spacing: 0.15em;
}

.header-nav {
    display: flex;
    gap: 2rem;
}

.header-nav a {
    color: var(--text-dark);
    text-decoration: none;
    font-size: 0.9rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.header-nav a:hover {
    color: var(--gold);
}

/* Main Content */
.main-content {
    flex: 1;
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 3rem;
    width: 100%;
}

/* Footer */
.site-footer {
    margin-top: auto;
}

.footer-content {
    max-width: 1400px;
    margin: 0 auto;
    padding: 1.5rem 3rem;
}

.footer-bar {
    height: 8px;
    background: linear-gradient(to right, var(--gold), var(--bronze));
}

.footer-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.85rem;
    letter-spacing: 0.1em;
    text-transform: uppercase;
}

.footer-nav a {
    color: var(--text-dark);
    text-decoration: none;
}

.footer-nav a:hover {
    color: var(--gold);
}

.footer-category {
    color: var(--text-light);
}

.nav-arrows {
    display: flex;
    gap: 2rem;
}

/* Gallery */
.gallery-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.gallery-header h2 {
    font-weight: normal;
    font-size: 1.5rem;
    letter-spacing: 0.1em;
}

.category-filter {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.category-filter label {
    font-size: 0.9rem;
    color: var(--text-light);
}

.gallery-stats {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 2rem;
}

.gallery-item {
    text-decoration: none;
    color: inherit;
    transition: transform 0.2s;
}

.gallery-item:hover {
    transform: translateY(-4px);
}

.gallery-image {
    aspect-ratio: 1;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 0.75rem;
}

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

.gallery-info {
    text-align: center;
}

.gallery-title {
    font-size: 1rem;
    margin-bottom: 0.25rem;
}

.gallery-artist {
    font-size: 0.85rem;
    color: var(--text-light);
}

/* Artwork Detail */
.artwork-detail {
    display: grid;
    grid-template-columns: 2fr 3fr;
    gap: 4rem;
    align-items: center;
    min-height: calc(100vh - 250px);
}

.artwork-image-container {
    display: flex;
    align-items: center;
    justify-content: center;
}

.artwork-image {
    max-width: 100%;
    max-height: 70vh;
    height: auto;
    display: block;
    object-fit: contain;
}

.artwork-info {
    padding: 2rem 0;
}

.artwork-artist {
    margin-bottom: 2rem;
}

.artist-name {
    font-size: 1.35rem;
    font-weight: normal;
    margin: 0 0 0.35rem 0;
    color: var(--text-dark);
}

.artist-info {
    font-size: 0.95rem;
    color: var(--text-light);
    margin: 0;
}

.artwork-title {
    font-size: 1.65rem;
    font-weight: normal;
    margin-bottom: 1.25rem;
    color: var(--text-dark);
    line-height: 1.3;
}

.artwork-title em {
    font-style: italic;
}

.artwork-year {
    font-style: normal;
}

.artwork-medium,
.artwork-dimensions {
    font-size: 1rem;
    margin-bottom: 0.4rem;
    color: var(--text-dark);
}

.artwork-description {
    margin-top: 2rem;
    font-size: 1rem;
    line-height: 1.85;
    color: var(--text-dark);
}

.artwork-description p {
    margin: 0;
}

.artwork-actions {
    margin-top: 2.5rem;
}

.artwork-actions .btn-edit-link {
    background: transparent;
    color: var(--text-light);
    border: 1px solid var(--border);
    font-size: 0.8rem;
    padding: 0.5rem 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.artwork-actions .btn-edit-link:hover {
    color: var(--gold);
    border-color: var(--gold);
}

.artwork-actions .btn-assign {
    background: var(--gold);
    color: white;
    border: none;
    font-size: 0.8rem;
    padding: 0.5rem 1rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-left: 0.5rem;
}

.artwork-actions .btn-assign:hover {
    background: var(--gold-dark);
}

/* No Image Placeholder */
.no-image {
    background: var(--bg-light);
    color: var(--text-light);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    width: 100%;
    height: 100%;
    min-height: 150px;
}

.no-image.large {
    min-height: 400px;
    font-size: 1.1rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    font-size: 0.9rem;
    text-decoration: none;
    border: none;
    cursor: pointer;
    font-family: inherit;
    letter-spacing: 0.05em;
    transition: all 0.2s;
}

.btn-primary {
    background: var(--gold);
    color: white;
}

.btn-primary:hover {
    background: var(--gold-dark);
}

.btn-primary:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.btn-secondary {
    background: var(--bg-light);
    color: var(--text-dark);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: var(--border);
}

.btn-edit {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
}

.btn-edit:hover {
    background: var(--gold);
    color: white;
}

.btn-nav {
    background: transparent;
    color: var(--text-dark);
    border: 1px solid var(--border);
    padding: 0.5rem 1rem;
}

.btn-nav:hover {
    border-color: var(--gold);
    color: var(--gold);
}

/* Forms */
.form-control {
    width: 100%;
    padding: 0.75rem;
    font-size: 1rem;
    font-family: inherit;
    border: 1px solid var(--border);
    background: var(--bg-white);
}

.form-control:focus {
    outline: none;
    border-color: var(--gold);
}

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

/* Edit Page */
.edit-container {
    max-width: 1200px;
}

.edit-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.edit-header h2 {
    font-weight: normal;
    font-size: 1.5rem;
}

.edit-layout {
    display: grid;
    grid-template-columns: 300px 1fr;
    gap: 3rem;
}

.edit-image-panel {
    position: sticky;
    top: 2rem;
}

.image-preview {
    margin-top: 1rem;
    background: var(--bg-light);
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
}

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

.edit-actions {
    margin-top: 2rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* Match Page */
.match-container {
    max-width: 1200px;
}

.match-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.match-header h2 {
    font-weight: normal;
    font-size: 1.5rem;
}

.match-stats {
    display: flex;
    gap: 2rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

.match-stats .remaining {
    color: var(--gold);
    font-weight: 500;
}

.match-content {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
}

.match-image-panel {
    text-align: center;
}

.match-image-container {
    background: var(--bg-light);
    padding: 1rem;
    margin-bottom: 1rem;
}

.match-image {
    max-width: 100%;
    max-height: 500px;
    object-fit: contain;
}

.match-filename {
    font-size: 0.9rem;
    color: var(--text-light);
    font-family: monospace;
}

.match-image-tools {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
}

.btn-search {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: transparent;
    color: var(--text-light);
    border: 1px solid var(--border);
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-search:hover {
    color: var(--gold);
    border-color: var(--gold);
}

.btn-search svg {
    flex-shrink: 0;
}

.match-form-panel {
    padding-top: 1rem;
}

.match-actions {
    margin-top: 2rem;
    display: flex;
    gap: 1rem;
}

.match-navigation {
    margin-top: 3rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
}

.match-complete {
    text-align: center;
    padding: 4rem 2rem;
}

.match-complete h3 {
    font-size: 1.5rem;
    font-weight: normal;
    margin-bottom: 1rem;
    color: var(--gold);
}

.match-complete p {
    margin-bottom: 2rem;
    color: var(--text-light);
}

.selected-info {
    margin-top: 1.5rem;
    padding: 1rem;
    background: var(--bg-light);
    border-left: 3px solid var(--gold);
}

.selected-info h4 {
    font-size: 0.85rem;
    font-weight: normal;
    color: var(--text-light);
    margin-bottom: 0.5rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
}

.selected-info #selected-title {
    font-size: 1.1rem;
    font-style: italic;
}

.selected-info #selected-year {
    font-size: 0.9rem;
    color: var(--text-light);
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-light);
}

/* Image Picker */
.image-picker-section {
    margin-bottom: 3rem;
}

.image-picker-section h3 {
    font-weight: normal;
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
}

.picker-help {
    color: var(--text-light);
    font-size: 0.9rem;
    margin-bottom: 1rem;
}

.current-selection {
    background: var(--bg-light);
    padding: 1rem;
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
}

.current-selection strong {
    color: var(--text-light);
    font-weight: normal;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
}

#current-selection-text {
    flex: 1;
    font-family: monospace;
}

.btn-small {
    padding: 0.4rem 0.75rem;
    font-size: 0.8rem;
}

.btn-remove {
    background: transparent;
    color: #c44;
    border: 1px solid #c44;
}

.btn-remove:hover {
    background: #c44;
    color: white;
}

.image-picker-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    gap: 1rem;
    max-height: 500px;
    overflow-y: auto;
    padding: 1rem;
    background: var(--bg-light);
    border: 1px solid var(--border);
}

.picker-item {
    cursor: pointer;
    background: white;
    border: 3px solid transparent;
    padding: 0.5rem;
    transition: all 0.2s;
    position: relative;
}

.picker-item:hover {
    border-color: var(--border);
    transform: translateY(-2px);
}

.picker-item.selected {
    border-color: var(--gold);
    box-shadow: 0 4px 12px rgba(196, 146, 46, 0.3);
}

.picker-item.assigned {
    border-color: var(--gold);
    opacity: 0.7;
}

.picker-item.assigned:hover {
    opacity: 1;
}

.picker-image {
    aspect-ratio: 1;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 0.5rem;
    position: relative;
    cursor: pointer;
}

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

.picker-zoom {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.2s;
    cursor: pointer;
}

.picker-item:hover .picker-zoom {
    opacity: 1;
}

.picker-zoom:hover {
    background: rgba(0, 0, 0, 0.8);
}

.picker-filename {
    font-size: 0.7rem;
    color: var(--text-light);
    font-family: monospace;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.picker-assigned-badge {
    position: absolute;
    top: 0.25rem;
    right: 0.25rem;
    background: var(--gold);
    color: white;
    font-size: 0.65rem;
    padding: 0.2rem 0.4rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.empty-picker {
    grid-column: 1 / -1;
    text-align: center;
    padding: 3rem;
    color: var(--text-light);
}

.empty-picker code {
    background: white;
    padding: 0.25rem 0.5rem;
    font-size: 0.9rem;
}

/* Edit Fields Section */
.edit-fields-section h3 {
    font-weight: normal;
    font-size: 1.25rem;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border);
}

.edit-fields-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem 2rem;
}

.edit-fields-grid .full-width {
    grid-column: 1 / -1;
}

/* Modal */
.modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background: white;
    padding: 2rem;
    max-width: 450px;
    width: 90%;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
}

.modal-content h3 {
    font-weight: normal;
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: var(--gold);
}

.modal-content p {
    margin-bottom: 1rem;
    color: var(--text-dark);
}

.modal-artwork-info {
    background: var(--bg-light);
    padding: 1rem;
    margin: 1rem 0;
}

.modal-artwork-info strong {
    font-style: italic;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 1.5rem;
}

/* Clickable No Image */
.no-image.clickable {
    cursor: pointer;
    transition: all 0.3s;
    border: 2px dashed var(--border);
}

.no-image.clickable:hover {
    border-color: var(--gold);
    background: #faf6f0;
}

.no-image-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
}

.no-image-content svg {
    opacity: 0.5;
}

.no-image.clickable:hover svg {
    opacity: 0.8;
    stroke: var(--gold);
}

.no-image-content span {
    font-size: 0.9rem;
}

/* Gallery Modal */
.gallery-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 2rem;
}

.gallery-modal-content {
    background: white;
    width: 100%;
    max-width: 1200px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.gallery-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border);
}

.gallery-modal-header h2 {
    font-weight: normal;
    font-size: 1.5rem;
    color: var(--text-dark);
}

.gallery-modal-close {
    background: none;
    border: none;
    font-size: 2rem;
    cursor: pointer;
    color: var(--text-light);
    line-height: 1;
    padding: 0;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.gallery-modal-close:hover {
    color: var(--text-dark);
}

.gallery-modal-filters {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem 2rem;
    background: var(--bg-light);
    border-bottom: 1px solid var(--border);
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-group label {
    font-size: 0.85rem;
    color: var(--text-light);
}

.filter-group select,
.filter-group input {
    padding: 0.5rem 0.75rem;
    font-size: 0.9rem;
    border: 1px solid var(--border);
    font-family: inherit;
}

.filter-group input {
    width: 200px;
}

.gallery-modal-stats {
    margin-left: auto;
    font-size: 0.85rem;
    color: var(--text-light);
}

.gallery-modal-grid {
    flex: 1;
    overflow-y: auto;
    padding: 1.5rem;
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 1rem;
    background: var(--bg-light);
}

.gallery-modal-item {
    background: white;
    cursor: pointer;
    border: 3px solid transparent;
    padding: 0.5rem;
    transition: all 0.2s;
    position: relative;
}

.gallery-modal-item:hover {
    border-color: var(--border);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.gallery-modal-item.selected {
    border-color: var(--gold);
    box-shadow: 0 4px 16px rgba(196, 146, 46, 0.4);
}

.gallery-modal-item.assigned {
    opacity: 0.6;
}

.gallery-modal-item.assigned:hover {
    opacity: 0.9;
}

.gallery-modal-thumb {
    aspect-ratio: 1;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 0.5rem;
    position: relative;
}

.gallery-modal-thumb .picker-zoom {
    position: absolute;
    top: 4px;
    right: 4px;
    background: rgba(0, 0, 0, 0.6);
    color: white;
    width: 24px;
    height: 24px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    opacity: 0;
    transition: opacity 0.2s;
    cursor: pointer;
    z-index: 5;
}

.gallery-modal-item:hover .picker-zoom {
    opacity: 1;
}

.gallery-modal-thumb .picker-zoom:hover {
    background: rgba(0, 0, 0, 0.8);
}

.gallery-modal-thumb img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.gallery-modal-name {
    font-size: 0.7rem;
    color: var(--text-light);
    font-family: monospace;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.gallery-modal-badge {
    position: absolute;
    top: 0.25rem;
    right: 0.25rem;
    background: var(--gold);
    color: white;
    font-size: 0.6rem;
    padding: 0.15rem 0.35rem;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.gallery-modal-empty {
    grid-column: 1 / -1;
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-light);
    font-size: 1.1rem;
}

.gallery-modal-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 2rem;
    border-top: 1px solid var(--border);
    background: white;
}

.selected-preview {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.selected-preview img {
    width: 50px;
    height: 50px;
    object-fit: contain;
    background: var(--bg-light);
}

.selected-preview span {
    font-family: monospace;
    font-size: 0.85rem;
    color: var(--text-dark);
}

.gallery-modal-actions {
    display: flex;
    gap: 1rem;
}

/* iPad Simulator Toggle Button */
.simulator-toggle {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    background: transparent;
    border: 1px solid var(--border);
    color: var(--text-light);
    cursor: pointer;
    transition: all 0.2s;
    padding: 0;
}

.simulator-toggle:hover {
    border-color: var(--gold);
    color: var(--gold);
}

.simulator-toggle.active {
    background: var(--gold);
    border-color: var(--gold);
    color: white;
}

.simulator-toggle svg {
    width: 20px;
    height: 20px;
}

/* Simulator Badge */
.simulator-badge {
    display: none;
    position: fixed;
    top: 10px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--gold);
    color: white;
    padding: 0.35rem 1rem;
    font-size: 0.75rem;
    font-weight: 500;
    letter-spacing: 0.05em;
    text-transform: uppercase;
    z-index: 9999;
    border-radius: 3px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

/* iPad Simulator Mode */
body.ipad-simulator {
    background: #e5e5e5;
}

body.ipad-simulator .simulator-badge {
    display: block;
}

body.ipad-simulator .site-header,
body.ipad-simulator .main-content,
body.ipad-simulator .site-footer {
    max-width: 1180px;
    margin-left: auto;
    margin-right: auto;
    background: white;
}

body.ipad-simulator .site-header {
    padding: 1.5rem 2.5rem;
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
}

body.ipad-simulator .main-content {
    padding: 2.5rem;
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
    min-height: calc(100vh - 180px);
}

body.ipad-simulator .site-footer {
    border-left: 1px solid var(--border);
    border-right: 1px solid var(--border);
}

body.ipad-simulator .footer-content {
    padding: 1.25rem 2.5rem;
}

/* Force iPad styles in simulator mode */
body.ipad-simulator .artwork-detail {
    grid-template-columns: 2fr 3fr;
    gap: 3.5rem;
    align-items: center;
    min-height: calc(100vh - 220px);
}

body.ipad-simulator .artist-name {
    font-size: 1.25rem;
}

body.ipad-simulator .artist-info {
    font-size: 0.875rem;
}

body.ipad-simulator .artwork-title {
    font-size: 1.5rem;
    margin-bottom: 1rem;
}

body.ipad-simulator .artwork-medium,
body.ipad-simulator .artwork-dimensions {
    font-size: 0.95rem;
}

body.ipad-simulator .artwork-description {
    font-size: 0.95rem;
    line-height: 1.8;
}

body.ipad-simulator .footer-nav {
    font-size: 0.8rem;
}

/* Hide simulator toggle on actual iPads */
@media (min-width: 1024px) and (max-width: 1366px) and (hover: none) and (pointer: coarse) {
    .simulator-toggle {
        display: none;
    }
}

/* Home Icon */
.home-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    color: var(--text-light);
    transition: color 0.2s;
}

.home-icon:hover {
    color: var(--gold);
}

.home-icon svg {
    width: 24px;
    height: 24px;
}

/* iPad 10" Landscape Optimized (1024px - 1366px) */
@media (min-width: 1024px) and (max-width: 1366px) {
    .site-header {
        padding: 1.5rem 2.5rem;
    }

    .main-content {
        padding: 2.5rem;
        max-width: 1100px;
    }

    .artwork-detail {
        grid-template-columns: 2fr 3fr;
        gap: 3.5rem;
        align-items: center;
        min-height: calc(100vh - 220px);
    }

    .artist-name {
        font-size: 1.25rem;
    }

    .artist-info {
        font-size: 0.875rem;
    }

    .artwork-title {
        font-size: 1.5rem;
        margin-bottom: 1rem;
    }

    .artwork-medium,
    .artwork-dimensions {
        font-size: 0.95rem;
    }

    .artwork-description {
        font-size: 0.95rem;
        line-height: 1.8;
    }

    .footer-content {
        padding: 1.25rem 2.5rem;
    }

    .footer-nav {
        font-size: 0.8rem;
    }
}

/* iPad Portrait */
@media (min-width: 768px) and (max-width: 1023px) {
    .artwork-detail {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .artwork-image-container {
        max-height: 50vh;
    }

    .artwork-image {
        max-height: 45vh;
    }
}

/* Review Page */
.review-container {
    max-width: 1400px;
}

.review-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.review-header h2 {
    font-weight: normal;
    font-size: 1.5rem;
}

.review-stats {
    display: flex;
    gap: 1.5rem;
    font-size: 0.9rem;
}

.review-stats .stat {
    color: var(--text-light);
}

.review-stats .stat strong {
    color: var(--text-dark);
}

.review-stats .excluded-stat strong {
    color: #c44;
}

.review-filters {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem;
    background: var(--bg-light);
    margin-bottom: 1.5rem;
    border: 1px solid var(--border);
}

.review-filters .filter-count {
    margin-left: auto;
    font-size: 0.85rem;
    color: var(--text-light);
}

.review-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 1.25rem;
}

.review-item {
    background: white;
    border: 2px solid var(--border);
    padding: 0.75rem;
    transition: all 0.2s;
    position: relative;
}

.review-item:hover {
    border-color: var(--gold);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.review-item.excluded {
    opacity: 0.6;
    border-color: #c44;
}

.review-item.excluded:hover {
    opacity: 1;
}

.review-item.assigned {
    border-color: var(--gold);
}

.review-image {
    aspect-ratio: 1;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    margin-bottom: 0.5rem;
    position: relative;
}

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

.excluded-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(204, 68, 68, 0.85);
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.9rem;
    font-weight: bold;
    letter-spacing: 0.1em;
    transition: opacity 0.2s;
}

.review-image:hover .excluded-overlay {
    opacity: 0;
}

.review-info {
    min-height: 3rem;
}

.review-filename {
    font-size: 0.75rem;
    color: var(--text-light);
    font-family: monospace;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    margin-bottom: 0.25rem;
}

.review-assigned {
    font-size: 0.7rem;
    color: var(--gold);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.review-actions {
    margin-top: 0.5rem;
}

.review-actions .btn {
    width: 100%;
    padding: 0.5rem;
    font-size: 0.8rem;
    text-align: center;
}

.btn-exclude {
    background: transparent;
    color: #c44;
    border: 1px solid #c44;
}

.btn-exclude:hover {
    background: #c44;
    color: white;
}

.btn-include {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
}

.btn-include:hover {
    background: var(--gold);
    color: white;
}

.review-stats .available-stat strong {
    color: #2a7;
}

.review-image {
    cursor: pointer;
}

/* Lightbox */
.lightbox {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 3000;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 2rem;
}

.lightbox.active {
    display: flex;
}

.lightbox-close {
    position: absolute;
    top: 1rem;
    right: 1.5rem;
    background: none;
    border: none;
    color: white;
    font-size: 2.5rem;
    cursor: pointer;
    opacity: 0.7;
    transition: opacity 0.2s;
    line-height: 1;
    padding: 0;
}

.lightbox-close:hover {
    opacity: 1;
}

.lightbox img {
    max-width: 90vw;
    max-height: 80vh;
    object-fit: contain;
}

.lightbox-caption {
    color: white;
    margin-top: 1rem;
    font-family: monospace;
    font-size: 0.9rem;
    opacity: 0.8;
}

/* User Menu */
.user-menu {
    position: relative;
    cursor: pointer;
}

.user-name {
    color: var(--text-dark);
    font-size: 0.85rem;
    padding: 0.5rem 0.75rem;
    background: var(--bg-light);
    border-radius: 3px;
}

.user-dropdown {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border: 1px solid var(--border);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    min-width: 150px;
    z-index: 100;
}

.user-menu:hover .user-dropdown {
    display: block;
}

.user-dropdown a {
    display: block;
    padding: 0.75rem 1rem;
    color: var(--text-dark);
    text-decoration: none;
    font-size: 0.85rem;
}

.user-dropdown a:hover {
    background: var(--bg-light);
    color: var(--gold);
}

.nav-admin {
    color: var(--gold) !important;
    font-weight: 500;
}

.nav-login {
    background: var(--gold);
    color: white !important;
    padding: 0.5rem 1rem;
    border-radius: 3px;
}

.nav-login:hover {
    background: var(--gold-dark);
}

/* Auth Pages */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 60vh;
}

.auth-box {
    background: white;
    border: 1px solid var(--border);
    padding: 2.5rem;
    width: 100%;
    max-width: 400px;
}

.auth-box h2 {
    font-weight: normal;
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    text-align: center;
}

.auth-box .form-actions {
    margin-top: 1.5rem;
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
}

/* Alerts */
.alert {
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 3px;
}

.alert-error {
    background: #fee;
    border: 1px solid #c44;
    color: #a33;
}

.alert-success {
    background: #efe;
    border: 1px solid #2a7;
    color: #185;
}

/* Admin Pages */
.admin-container {
    max-width: 1200px;
}

.admin-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border);
}

.admin-header h2 {
    font-weight: normal;
    font-size: 1.5rem;
}

.admin-section {
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--bg-light);
    border: 1px solid var(--border);
}

.admin-section h3 {
    font-weight: normal;
    font-size: 1.1rem;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border);
}

.add-user-form .form-row {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    align-items: flex-end;
}

.add-user-form .form-group {
    flex: 1;
    min-width: 150px;
}

.admin-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
}

.admin-table th,
.admin-table td {
    padding: 0.75rem 1rem;
    text-align: left;
    border-bottom: 1px solid var(--border);
}

.admin-table th {
    background: var(--bg-light);
    font-weight: normal;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-light);
}

.admin-table tr.inactive {
    opacity: 0.5;
}

.admin-table .actions-cell {
    white-space: nowrap;
}

.role-badge {
    display: inline-block;
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    border-radius: 3px;
}

.role-admin {
    background: var(--gold);
    color: white;
}

.role-user {
    background: var(--bg-light);
    color: var(--text-light);
}

.status-active {
    color: #2a7;
}

.status-inactive {
    color: #c44;
}

.btn-small {
    padding: 0.35rem 0.75rem;
    font-size: 0.8rem;
}

.btn-edit {
    background: transparent;
    color: var(--gold);
    border: 1px solid var(--gold);
}

.btn-danger {
    background: transparent;
    color: #c44;
    border: 1px solid #c44;
}

.btn-danger:hover {
    background: #c44;
    color: white;
}

/* Audit Log */
.audit-stats {
    display: flex;
    justify-content: space-between;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    color: var(--text-light);
}

.audit-table .timestamp {
    font-family: monospace;
    font-size: 0.85rem;
    white-space: nowrap;
}

.audit-table .details {
    max-width: 400px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.audit-table .ip {
    font-family: monospace;
    font-size: 0.85rem;
}

.audit-table .empty {
    text-align: center;
    color: var(--text-light);
    padding: 2rem;
}

.action-badge {
    display: inline-block;
    padding: 0.2rem 0.5rem;
    font-size: 0.75rem;
    border-radius: 3px;
    background: var(--bg-light);
}

.action-login, .action-logout {
    background: #e8f4fd;
    color: #1a6eb5;
}

.action-edit, .action-change {
    background: #fef3e8;
    color: #b56a1a;
}

.action-add, .action-assign, .action-match, .action-include {
    background: #e8fde8;
    color: #1a7a1a;
}

.action-delete, .action-unassign, .action-exclude {
    background: #fde8e8;
    color: #a33;
}

.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.page-info {
    font-size: 0.9rem;
    color: var(--text-light);
}

/* Mobile */
@media (max-width: 767px) {
    .artwork-detail,
    .edit-layout,
    .match-content {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .artwork-image-container {
        max-height: 40vh;
    }

    .artwork-image {
        max-height: 35vh;
    }

    .header-content {
        flex-direction: column;
        gap: 1rem;
    }

    .site-header,
    .main-content,
    .footer-content {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
    }

    .site-title {
        font-size: 1.2rem;
    }

    .artist-name {
        font-size: 1.15rem;
    }

    .artwork-title {
        font-size: 1.35rem;
    }

    .footer-nav {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
    }

    .nav-arrows {
        order: -1;
    }
}
