/*
 * Make the logout form/button inside #nav look identical to nav link <a> tags.
 * The theme's main.css applies button styles with !important, so we must
 * override with !important here. This file loads after main.css in base.html.
 */

/* Remove form margins/padding so the <li> layout is unaffected */
#nav ul.links li form {
    margin: 0;
    padding: 0;
}

/* Style the button to match #nav ul.links li a exactly (from main.css lines 3707-3716, 3649-3651) */
#nav ul.links li button {
    -moz-appearance: none !important;
    -webkit-appearance: none !important;
    appearance: none !important;
    background: none !important;
    box-shadow: none !important;
    color: #ffffff !important;
    border: none !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.5) !important;
    display: block;
    font-size: 0.8rem;
    font-family: inherit;
    font-weight: inherit;
    letter-spacing: inherit;
    text-transform: uppercase;
    height: auto;
    line-height: 4rem;
    padding: 0 2rem;
    cursor: pointer;
    outline: none;
    transition: background-color 0.2s ease-in-out, color 0.2s ease-in-out;
}

#nav ul.links li button:hover {
    color: inherit !important;
    background-color: rgba(255, 255, 255, 0.1);
    border-bottom-color: transparent !important;
}

/* Artist card header: tighten spacing, and inherit color so hover works */
.artist-card header h2 {
    margin-bottom: 0.25rem;
    color: inherit;
}

.artist-card .artist-name {
    display: block;
    font-family: "Merriweather", Georgia, serif;
    font-size: 0.8rem;
    margin: 0 0 1.5rem 0;
}

/* Reduce static header height on non-homepage pages (theme default is 20rem).
   The homepage uses #intro + #header with a matching negative margin,
   so we restore the original height when #intro is present. */
#header {
    height: 13rem;
    padding-bottom: 5rem;
}

#intro + #header {
    height: 20rem;
    padding-bottom: 8rem;
}

/* Artist card: make entire card a clickable block link */
a.artist-card {
    display: block;
    text-decoration: none;
    color: inherit;
}

a.artist-card:hover {
    opacity: 0.85;
}

/* Lock icon for private content visible only to the owner */
.fas.fa-lock {
    color: #f56a6a;
    font-size: 0.8em;
    opacity: 0.85;
}

/* Section headers and footers that span the full width inside a .posts flexbox grid */
section.posts > header.section-header,
section.posts > footer {
    width: 100%;
    flex: 0 0 100%;
}

/* Artist detail page: tighten the profile section sizing */
#main > .artist-profile {
    padding: 5rem 8rem 3rem 8rem;
}

#main > .compact-cards > * {
    padding: 2rem;
}

#main > .compact-cards > header.section-header {
    margin-bottom: 0;
}

.artist-profile header.major {
    margin-bottom: 2rem;
}

.artist-profile header.major h1 {
    font-size: 2.5rem;
}

.artist-profile .image.main {
    margin: 1.5rem auto;
    max-width: 400px;
}

.artist-profile h2 {
    font-size: 1.3rem;
    margin-top: 1.5rem;
}

/* Compact card grid for art/inspiration on artist detail page */
.compact-cards article {
    font-size: 0.85rem;
}

.compact-cards article .image.fit {
    margin-bottom: 0.75rem;
}

.compact-cards article h3 {
    font-size: 1rem;
}

/* Three-column grid: override the theme's 50% width on .posts children */
#main > .three-col > * {
    width: 33.333%;
}

/* Homepage art carousel */
.art-carousel,
.artist-carousel {
    position: relative;
}

.art-carousel .carousel-slide.hidden,
.artist-carousel .carousel-slide.hidden {
    display: none;
}

.art-carousel .carousel-controls,
.artist-carousel .carousel-controls {
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
    display: flex;
    justify-content: space-between;
    pointer-events: none;
}

.art-carousel .carousel-controls button,
.artist-carousel .carousel-controls button {
    pointer-events: auto;
    background: rgba(0, 0, 0, 0.5) !important;
    color: #fff !important;
    border: none !important;
    box-shadow: none !important;
    width: 2.5rem;
    height: 2.5rem;
    font-size: 1rem;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 0.5rem;
    transition: background 0.2s;
}

.art-carousel .carousel-controls button:hover,
.artist-carousel .carousel-controls button:hover {
    background: rgba(0, 0, 0, 0.75) !important;
}

/* Standardize headline height: 3 lines max with ellipsis, reserve space so cards align */
.artist-headline {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    min-height: 3em;
}
