/* Default styles for gollery */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: system-ui, -apple-system, sans-serif;
  line-height: 1.5;
  color: #333;
  background: #fafafa;
}

#app {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem;
}

/* Site navigation */
.site-nav {
  display: flex;
  align-items: center;
  padding: 0.5rem 0;
  margin-bottom: 1rem;
  border-bottom: 1px solid #eee;
}

.nav-home {
  font-weight: 600;
  color: #333;
  text-decoration: none;
  font-size: 1.1rem;
}

.nav-home:hover {
  color: #0066cc;
}

.nav-spacer {
  flex: 1;
}

.nav-user {
  color: #666;
  font-size: 0.875rem;
  margin-right: 0.75rem;
}

.nav-login,
.nav-logout {
  font-size: 0.8rem;
}

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

/* Page header */
.page-header {
  margin-bottom: 1.5rem;
}

.page-header h1 {
  font-size: 1.75rem;
  font-weight: 600;
}

.album-description {
  color: #666;
  margin-top: 0.25rem;
}

/* Breadcrumb */
.breadcrumb {
  margin-bottom: 1rem;
  font-size: 0.875rem;
  color: #666;
}

.breadcrumb a {
  color: #0066cc;
  text-decoration: none;
}

.breadcrumb a:hover {
  text-decoration: underline;
}

/* Album list */
.album-children {
  margin-bottom: 1.5rem;
}

.album-children h2 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
}

.album-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.album-list-item .album-link {
  display: block;
  padding: 0.5rem 1rem;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
  color: #0066cc;
  text-decoration: none;
}

.album-list-item .album-link:hover {
  background: #f0f0f0;
}

/* Asset grid */
.asset-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 0.5rem;
}

.asset-thumb {
  display: block;
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 4px;
  background: #eee;
}

.asset-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Asset viewer */
.asset-viewer {
  max-width: 900px;
  margin: 0 auto;
}

.asset-nav {
  display: flex;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.asset-nav a {
  color: #0066cc;
  text-decoration: none;
}

.asset-nav a:hover {
  text-decoration: underline;
}

.asset-nav .disabled {
  color: #ccc;
}

.asset-figure {
  text-align: center;
  margin-bottom: 1rem;
}

.asset-preview {
  max-width: 100%;
  max-height: 80vh;
  border-radius: 4px;
}

.asset-figure figcaption {
  color: #666;
  font-size: 0.875rem;
  margin-top: 0.5rem;
}

.asset-actions {
  text-align: center;
  margin-bottom: 1rem;
}

/* Discussion links */
.discussion-links {
  margin-top: 1.5rem;
  border-top: 1px solid #eee;
  padding-top: 1rem;
}

.discussion-links h3 {
  font-size: 1rem;
  margin-bottom: 0.5rem;
}

.discussion-links ul {
  list-style: none;
  display: flex;
  gap: 1rem;
}

.discussion-link {
  color: #0066cc;
  text-decoration: none;
}

.discussion-link:hover {
  text-decoration: underline;
}

/* Login page */
.login-page {
  max-width: 400px;
  margin: 4rem auto;
}

.login-page h1 {
  margin-bottom: 1.5rem;
}

.login-form label {
  display: block;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  font-weight: 500;
}

.login-form input {
  display: block;
  width: 100%;
  margin-top: 0.25rem;
  padding: 0.5rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 1rem;
}

.login-error {
  color: #c00;
  font-size: 0.875rem;
  margin-bottom: 0.5rem;
}

/* Buttons */
.btn {
  display: inline-block;
  padding: 0.5rem 1rem;
  background: #0066cc;
  color: #fff;
  border: none;
  border-radius: 4px;
  font-size: 0.875rem;
  text-decoration: none;
  cursor: pointer;
}

.btn:hover {
  background: #0055aa;
}

/* Error pages */
.error-page {
  text-align: center;
  margin-top: 4rem;
}

.error-page h1 {
  font-size: 3rem;
  color: #999;
}

.error-page p {
  color: #666;
  margin: 1rem 0;
}

/* Asset metadata */
.asset-meta {
  text-align: center;
  margin-bottom: 1rem;
}

.asset-title {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.asset-description {
  color: #666;
  margin-bottom: 0.5rem;
}

/* Edit forms (album and asset metadata) */
.asset-edit-form,
.album-edit-form {
  max-width: 500px;
  margin: 1rem auto;
  padding: 1rem;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 4px;
}

.asset-edit-form label,
.album-edit-form label {
  display: block;
  margin-bottom: 0.75rem;
  font-size: 0.875rem;
  font-weight: 500;
}

.asset-edit-form input,
.asset-edit-form textarea,
.album-edit-form input,
.album-edit-form textarea {
  display: block;
  width: 100%;
  margin-top: 0.25rem;
  padding: 0.5rem;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-size: 0.875rem;
  font-family: inherit;
}

.edit-actions {
  margin-top: 0.75rem;
}

/* Mastodon share button */
.asset-share-mastodon {
  background: #6364ff;
}

.asset-share-mastodon:hover {
  background: #5253dd;
}

/* Loading state */
.loading {
  text-align: center;
  color: #999;
  padding: 4rem;
}

/* Empty state */
.empty-state {
  text-align: center;
  color: #999;
  padding: 2rem;
}
/* perri.to theme override for gollery
 * Matches the Hugo site at perri.to
 * Palette: http://paletton.com/#uid=70n0u0kexvf5cQS9LFMjdqpnolR
 */

@import url('https://fonts.googleapis.com/css2?family=Raleway:ital,wght@0,400;0,600;1,600&family=Roboto:wght@400;500&display=swap');

/* ── Base ─────────────────────────────────────────────────────────── */

body {
  font-family: 'Roboto', sans-serif;
  background-color: rgb(237, 236, 234);
  color: #333;
  line-height: 1.6;
}

#app {
  max-width: 1200px;
  padding: 10px;
}

/* ── Navigation ───────────────────────────────────────────────────── */

.site-nav {
  background-color: #fff;
  padding: 0.75rem 1rem;
  margin-bottom: 1rem;
  border-bottom: none;
  border-bottom-right-radius: 25px;
}

.nav-home {
  font-family: 'Raleway', sans-serif;
  font-style: italic;
  font-weight: 600;
  font-size: 1.25rem;
  color: rgb(26, 94, 187);
}

.nav-home:hover {
  color: #264673;
}

.nav-user {
  font-family: 'Roboto', sans-serif;
  color: rgb(128, 128, 128);
}

.nav-logout,
.nav-login {
  font-family: 'Raleway', sans-serif;
}

/* ── Buttons ──────────────────────────────────────────────────────── */

.btn {
  background: #607CA4;
  border-radius: 4px;
  color: #fff;
  font-family: 'Raleway', sans-serif;
  font-weight: 600;
}

.btn:hover {
  background: #3F5E8A;
}

/* ── Page headers ─────────────────────────────────────────────────── */

.page-header h1 {
  font-family: 'Raleway', sans-serif;
  font-weight: 600;
  color: #333;
}

.album-description {
  font-family: 'Roboto', sans-serif;
  color: rgb(128, 128, 128);
}

/* ── Breadcrumb ───────────────────────────────────────────────────── */

.breadcrumb {
  font-family: 'Raleway', sans-serif;
  font-style: italic;
  color: rgb(128, 128, 128);
}

.breadcrumb a {
  color: rgb(26, 94, 187);
}

.breadcrumb a:hover {
  color: #264673;
}

/* ── Album list ───────────────────────────────────────────────────── */

.album-children h2 {
  font-family: 'Raleway', sans-serif;
  font-weight: 600;
  background-color: rgba(147, 147, 147, 0.7);
  padding: 3px 10px;
  color: #fff;
  font-size: 1.2rem;
}

.album-list-item .album-link {
  font-family: 'Raleway', sans-serif;
  font-style: italic;
  font-weight: 600;
  color: rgb(26, 94, 187);
  background: rgba(247, 247, 247, 0.7);
  border: 1px solid rgba(227, 227, 227, 0.7);
  border-bottom-right-radius: 25px;
}

.album-list-item .album-link:hover {
  background: rgba(227, 227, 227, 0.7);
}

/* ── Asset grid ───────────────────────────────────────────────────── */

.asset-thumb {
  border-radius: 4px;
  background: rgba(227, 227, 227, 0.7);
  transition: transform 0.15s ease;
}

.asset-thumb:hover {
  transform: scale(1.03);
}

/* ── Asset viewer ─────────────────────────────────────────────────── */

.asset-nav a {
  font-family: 'Raleway', sans-serif;
  font-style: italic;
  color: rgb(26, 94, 187);
}

.asset-nav a:hover {
  color: #264673;
}

.asset-nav .disabled {
  color: rgba(147, 147, 147, 0.5);
}

.asset-preview {
  border-radius: 4px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.asset-figure figcaption {
  font-family: 'Roboto', sans-serif;
  color: rgb(128, 128, 128);
}

/* ── Discussion links ─────────────────────────────────────────────── */

.discussion-links {
  border-top: 1px solid rgba(227, 227, 227, 0.7);
}

.discussion-links h3 {
  font-family: 'Raleway', sans-serif;
  font-weight: 600;
  color: #333;
}

.discussion-link {
  color: rgb(26, 94, 187);
}

.discussion-link:hover {
  color: #264673;
}

/* ── Login page ───────────────────────────────────────────────────── */

.login-page h1 {
  font-family: 'Raleway', sans-serif;
  font-weight: 600;
}

.login-form label {
  font-family: 'Roboto', sans-serif;
}

.login-form input {
  border: 1px solid rgba(147, 147, 147, 0.5);
  border-radius: 4px;
  font-family: 'Roboto', sans-serif;
}

.login-form input:focus {
  outline: none;
  border-color: #607CA4;
  box-shadow: 0 0 0 2px rgba(96, 124, 164, 0.25);
}

/* ── Error pages ──────────────────────────────────────────────────── */

.error-page h1 {
  font-family: 'Raleway', sans-serif;
  color: rgba(147, 147, 147, 0.7);
}

.error-page p {
  font-family: 'Roboto', sans-serif;
  color: rgb(128, 128, 128);
}

/* ── Loading & empty states ───────────────────────────────────────── */

.loading,
.empty-state {
  font-family: 'Roboto', sans-serif;
  color: rgb(128, 128, 128);
}
