/* ==========================================================
   Monthly giving card
   ----------------------------------------------------------
   Goes with resources/views/partials/monthly-giving.blade.php.
   Every page that includes that partial pushes this file in
   @push('styles'), so it lands after site.css and is loaded
   only where the card actually appears.
   ========================================================== */


/* ----------------------------------------------------------
   MONTHLY GIVING CARD: amount tiles
   ----------------------------------------------------------
   Each tile is a radio input stretched over its label at 1%
   opacity and sitting above it, so the whole tile is clickable
   and :checked + label paints the selection.
   ---------------------------------------------------------- */
.donate-now {
    list-style-type: none;
    padding: 0;
}

.donate-now li {
    float: left;
    margin: 5px 5px 0 0;
    width: 100%;
    height: 50px;
    position: relative;
    background-color: #e9eae4;
    border-color: #e9eae4;
    color: grey;
}

.donate-now label,
.donate-now input {
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
}

.donate-now input[type="radio"] {
    opacity: 0.01;
    z-index: 100;
}

.donate-now input[type="radio"]:checked + label,
.Checked + label {
    background: #ff6400;
    color: white;
}

.donate-now label {
    padding: 15px;
    cursor: pointer;
    z-index: 90;
    height: 50px;
    border-radius: 5px;
}

.donate-now label:hover {
    background: #ddd;
}


/* ----------------------------------------------------------
   MONTHLY GIVING CARD: "Other amount"
   ---------------------------------------------------------- */
.oa-btn {
    background-color: #e9eae4;
    border: #e9eae4;
    outline: 0;
    color: grey;
    font-size: 18px;
}

.oa-btn:focus,
.oa-btn:active {
    background: #ff6400;
    color: white;
    border: #ff6400;
    outline: 0;
}

.oa-btn,
#amountentry {
    margin: 5px 5px 0 0;
    width: 100%;
    height: 50px;
}

#amountentry input {
    height: 50px;
}

/* Tighter gutters so the four amount tiles sit close together */
.col-md-4,
.col-md-8 {
    padding-left: 5px !important;
    padding-right: 5px !important;
}

input:focus,
input.form-control:focus {
    outline: none !important;
    outline-width: 0 !important;
    box-shadow: none;
    -moz-box-shadow: none;
    -webkit-box-shadow: none;
}

/* The amount field is type=number; the spinners would overlap the Rs./$ suffix */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type="number"] {
    -moz-appearance: textfield;
}


/* ----------------------------------------------------------
   TYPOGRAPHY
   ---------------------------------------------------------- */
h5:after {
    background: transparent !important;
}

h3 {
    text-transform: capitalize !important;
}

.donate-now label,
a {
    text-transform: capitalize;
}


/* ----------------------------------------------------------
   SMALL SCREENS
   ----------------------------------------------------------
   Below 992px the monthly card sits on white instead of the
   photograph, so its heading and SSL note switch to dark.
   ---------------------------------------------------------- */
@media only screen and (max-width: 600px) {
    .aos-animate h2 {
        font-size: 1.5rem;
    }

    .donate-now .btn {
        line-height: 1;
    }
}

@media only screen and (max-width: 992px) {
    .secure-pay {
        color: #000 !important;
    }
}

/* The photograph is set on the element in index.blade.php; below 767px the
   card goes full width and covers it, so it is dropped here. */
@media only screen and (max-width: 767px) {
    .membership-sec {
        background-image: none !important;
    }
}


/* ==========================================================
   THEMED PAGES ONLY
   ----------------------------------------------------------
   This card is included by the home page and by School Reform,
   and both set body-class in their own Blade file, so removing
   those lines returns the card as it was on each.

   The giving panel on /donate answers a pointer in the theme's
   language, and this is the same panel in different clothes --
   its options are grey fills rather than outlined pills, and
   its submit carries its colour inline. Said in its own terms
   here, so the two behave alike.
   ========================================================== */


/* ----------------------------------------------------------
   THE AMOUNTS
   ----------------------------------------------------------
   An amount answered with a grey wash, #ddd. It warms instead:
   a tenth of the accent in the fill, the figure in accent, and
   an accent hairline drawn with an inset shadow -- these
   options have no border of their own to colour.

   The chosen one is immune, as on /donate: a hovered option
   must never look more selected than the selection.
   ---------------------------------------------------------- */
body.home-premium .donate-now li:hover {
    background-color: rgba(255, 96, 21, 0.10);
    box-shadow: inset 0 0 0 1px var(--accent);
}

body.home-premium .donate-now li:hover label {
    background: transparent;
    color: var(--accent);
}

body.home-premium .donate-now input[type="radio"]:checked + label,
body.home-premium .donate-now li:hover input[type="radio"]:checked + label {
    background: #ff6400;
    color: #fff;
}

body.home-premium .donate-now li:has(input[type="radio"]:checked):hover {
    box-shadow: none;
}

/* "Other amount" is an option of the same kind. Its colour needs
   !important: the markup also carries Bootstrap's .text-muted,
   and every Bootstrap utility is !important, so without it the
   label stayed grey while everything round it warmed. */
body.home-premium .oa-btn:hover {
    background-color: rgba(255, 96, 21, 0.10);
    box-shadow: inset 0 0 0 1px var(--accent);
    color: var(--accent) !important;
}


/* ----------------------------------------------------------
   DONATE MONTHLY
   ----------------------------------------------------------
   The same gesture the submit on /donate makes: a light sweep
   travels across the face, the button lifts 3px and the glow
   deepens. The sweep is a background-image that is always
   there, parked off the right-hand side at rest, because an
   image that appears only on hover has nowhere to travel from.

   The colour needs !important: the button carries
   background-color: #ff6400 inline, and nothing in a
   stylesheet outranks that without it.
   ---------------------------------------------------------- */
body.home-premium .membership-sec button[type="submit"] {
    border: 0;
    border-radius: 999px;
    overflow: hidden;
    font-weight: 700;
    background-color: var(--accent) !important;
    background-image:
        linear-gradient(120deg, transparent 36%, rgba(255, 255, 255, 0.30) 50%, transparent 64%);
    background-size: 220% 100%;
    background-position: 160% 0;
    background-repeat: no-repeat;
    box-shadow: 0 10px 26px -10px rgba(255, 96, 21, 0.75);
    transition:
        background-color 0.525s var(--ease),
        background-position 1.125s var(--ease),
        transform 0.525s var(--ease),
        box-shadow 0.525s var(--ease);
}

body.home-premium .membership-sec button[type="submit"]:hover,
body.home-premium .membership-sec button[type="submit"]:focus-visible {
    background-color: var(--accent-deep) !important;
    background-position: -60% 0;
    color: #fff;
    transform: translateY(-3px);
    box-shadow: 0 18px 38px -12px rgba(255, 96, 21, 0.8);
}
