/* Posao Theme: the account area. Shared look of HivePress's account pages, its forms and tables,
   and WooCommerce's orders, cart and checkout. Loaded for logged-in users and on the shop pages. */

/* The side menu stays in view through CSS. HivePress's script did it with fixed positions
   and ran over the footer on long pages; its inline values are overruled here. */
@media (min-width: 48em) {
	.pt-acctrail__btn { display: none; }
	.hp-page__sidebar[data-component="sticky"] > div { height: 100%; }
	.hp-page__sidebar[data-component="sticky"] .inner-wrapper-sticky { position: sticky !important; top: calc(var(--pt-header-h) + 16px) !important; left: auto !important; width: auto !important; transform: none !important; }
}
.pt-account-page .hp-row { row-gap: 16px; }
.pt-account-page .hp-widget--user-account-menu { margin: 0; }
.pt-account-page .hp-page__content { min-width: 0; }
.pt-account-page .hp-page__title { margin: 0 0 16px; }

/* The applications plugin's pages inside the account frame: they fill the column */
.pt-account-page .hp-page__content .pea-dash, .pt-account-page .hp-page__content .pea-ca, .pt-account-page .hp-page__content .pea-cp { max-width: none; margin: 0; }

/* The applications plugin's pages take the theme's colours through the plugin's own variables
   (it sets them on these three elements; under another theme its own values stay). */
.pt-site .pea-dash, .pt-site .pea-ca, .pt-site .pea-cp {
	--pea-orange: var(--pt-orange-600); --pea-orange-dark: var(--pt-orange-700); --pea-orange-tint: var(--pt-orange-50);
	--pea-ink: var(--pt-text); --pea-text: var(--pt-text); --pea-muted: var(--pt-muted);
	--pea-line: var(--pt-border); --pea-bg: var(--pt-surface-2); --pea-white: var(--pt-surface);
	--pea-new: var(--pt-orange-600); --pea-ok: var(--pt-ok); --pea-prog: var(--pt-navy);
}
.pt-site .pea-dash-title, .pt-site .pea-ca-head h2 { font-size: clamp(24px, 3vw, 34px); letter-spacing: -.02em; line-height: var(--pt-leading-tight); margin: 0 0 16px; }
.pt-site .pea-avatar { background: var(--pt-navy); }
.pt-site .pea-detail-btn { background: var(--pt-navy); border-radius: var(--pt-pill); }
.pt-site .pea-detail-btn:hover { background: var(--pt-navy-700); }

/* Tables of ads, packages, messages */
.pt-site .hp-table td.hp-listing__title { word-break: normal; overflow-wrap: break-word; }
@media (min-width: 48em) {
	.hp-listings.hp-table { table-layout: fixed; }
	.hp-listings.hp-table .hp-listing__title { width: 38%; }
	.hp-listings.hp-table .hp-listing__categories { width: 21%; }
	.hp-listings.hp-table .hp-listing__created-date { width: 14%; }
	.hp-listings.hp-table .hp-listing__status { width: 16%; }
	.hp-listings.hp-table .hp-listing__actions { width: 11%; }
}
.hp-table .hp-listing__created-date { white-space: nowrap; }
.hp-table .hp-status span { white-space: normal; text-align: center; }
.hp-table .hp-link--wrap { display: flex; align-items: flex-start; gap: 8px; font-size: 15px; }
.hp-table .hp-link--wrap .hp-icon { flex: none; margin-top: 4px; color: var(--pt-muted); font-size: 13px; }
.hp-table .hp-listing__actions { white-space: nowrap; text-align: right; }
.hp-table .hp-listing__action { display: inline-grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; color: var(--pt-muted); }
.hp-table .hp-listing__action:hover { background: var(--pt-surface-2); color: var(--pt-text); text-decoration: none; }

/* Paketi and Poruke: small notes inside a cell */
.hp-table .pt-cellnote { display: block; margin-top: 2px; color: var(--pt-muted); font-size: 13px; font-weight: 400; }
.hp-table .pt-cellmuted { color: var(--pt-muted); font-weight: 600; }
.hp-user-listing-package__submit-limit { text-align: right; }
.hp-user-listing-package__submit-limit .pt-cellnum { font-size: 20px; letter-spacing: -.02em; }
.hp-user-listing-package__submit-limit .pt-celllabel { color: var(--pt-muted); font-size: 14px; }
.hp-user-listing-package__categories:empty { display: none; }
.pt-acctnext { display: flex; flex-wrap: wrap; gap: 10px; margin: 16px 0 0; }
.hp-messages .hp-link { display: inline-flex; align-items: center; gap: 8px; }
.hp-messages .hp-link .hp-icon { color: var(--pt-muted); }
.hp-message__sender.pt-unread .hp-link { font-weight: 800; }
.hp-message__sender.pt-unread .hp-icon { color: var(--pt-orange-600); }
.pt-newmark { font-style: normal; background: var(--pt-orange-600); color: #fff; border-radius: var(--pt-pill); padding: 2px 8px; font-size: 11px; font-weight: 700; }
.hp-message__date { color: var(--pt-muted); font-size: 14px; white-space: nowrap; text-align: right; }

/* Status labels */
.hp-status span { border: 0; border-radius: var(--pt-pill); padding: 5px 10px; font-size: 12px; font-weight: 700; line-height: 1.2; background: var(--pt-surface-2); color: var(--pt-muted); }
.hp-status--publish span, .hp-status--wc-completed span { background: #e4f4ec; color: #0b6b4a; }
.hp-status--pending span, .hp-status--wc-on-hold span, .hp-status--wc-processing span { background: #fff1cc; color: #7a4f00; }
.hp-status--draft span, .hp-status--trash span, .hp-status--wc-refunded span { background: #fde7eb; color: #a8203a; }
[data-theme="dark"] .hp-status--publish span, [data-theme="dark"] .hp-status--wc-completed span { background: #123a2c; color: #6fdcb0; }
[data-theme="dark"] .hp-status--pending span, [data-theme="dark"] .hp-status--wc-on-hold span, [data-theme="dark"] .hp-status--wc-processing span { background: #3d3010; color: #ffd66b; }
[data-theme="dark"] .hp-status--draft span, [data-theme="dark"] .hp-status--trash span, [data-theme="dark"] .hp-status--wc-refunded span { background: #42151f; color: #ff9aac; }

/* Page numbers under a table */
.hp-pagination .nav-links { display: flex; flex-wrap: wrap; gap: 6px; justify-content: center; margin-top: 20px; }
.hp-pagination .page-numbers { display: grid; place-items: center; min-width: 38px; height: 38px; padding: 0 10px; border: 1px solid var(--pt-border); border-radius: var(--pt-pill); background: var(--pt-surface); color: var(--pt-text); font-weight: 600; font-size: var(--pt-text-sm); text-decoration: none; }
.hp-pagination .page-numbers.current { background: var(--pt-navy); border-color: var(--pt-navy); color: #fff; }
.hp-pagination .page-numbers.dots { border: 0; background: none; }

/* Forms: the ad form, profile and settings */
.hp-template--listing-edit-page .hp-page__content, .hp-template--listing-submit-details-page .hp-page__content, .hp-template--listing-submit-profile-page .hp-page__content { max-width: 820px; margin-inline: auto; }
.hp-form .hp-field--checkboxes ul, .hp-form .hp-field--radio ul { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 8px 16px; }
.hp-form .hp-field--checkboxes li, .hp-form .hp-field--radio li { margin: 0; }
.hp-form label.hp-field--checkbox, .hp-form .hp-field--radio label { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 500; cursor: pointer; }
.hp-form input[type="checkbox"], .hp-form input[type="radio"] { flex: none; width: 18px; height: 18px; margin: 0; accent-color: var(--pt-navy); }
.hp-form textarea { min-height: 200px; }
.hp-form .hp-field__description, .hp-form .hp-form__description { color: var(--pt-muted); font-size: 13px; }
.hp-form .hp-form__label small, .hp-form .hp-field__label small { color: var(--pt-muted); font-weight: 500; }

/* Sections of the long forms (headings added by account.js) */
.pt-formsec { margin: 32px 0 16px; padding-top: 24px; border-top: 1px solid var(--pt-border); }
.pt-formsec--first { margin-top: 0; padding-top: 0; border-top: 0; }
.pt-formsec__title { margin: 0; font-size: 19px; letter-spacing: -.02em; }
/* Required choice questions left without an answer (assets/js/account.js). */
.pt-form__missing { margin: 0 0 16px; padding: 12px 16px; border: 1px solid #f3b4b4; border-left: 4px solid #c62828; border-radius: var(--pt-radius-sm); background: #fdf3f3; color: #7a1c1c; font-size: var(--pt-text-sm); }
.pt-form__missing p { margin: 0 0 6px; font-weight: 700; }
.pt-form__missing ul { margin: 0; padding-left: 18px; }
.pt-form__field--missing { outline: 2px solid #c62828; outline-offset: 8px; border-radius: 6px; }
.pt-formsec__note { margin: 4px 0 0; color: var(--pt-muted); font-size: var(--pt-text-sm); }
.pt-form--sections { background: var(--pt-surface); border: 1px solid var(--pt-border); border-radius: var(--pt-radius); box-shadow: var(--pt-shadow); padding: 24px; }
.pt-form--sections .hp-form__footer { margin-top: 28px; padding-top: 20px; border-top: 1px solid var(--pt-border); }
@media (max-width: 47.99em) {
	.pt-form--sections { padding: 16px; }
}

/* WooCommerce: buttons */
.pt-site .woocommerce a.button, .pt-site .woocommerce button.button, .pt-site .woocommerce input.button {
	display: inline-flex; align-items: center; justify-content: center; border: 1px solid var(--pt-border); border-radius: var(--pt-pill); padding: 10px 18px;
	font: inherit; font-weight: 700; font-size: var(--pt-text-sm); line-height: 1.2; background: var(--pt-surface); color: var(--pt-text);
}
.pt-site .woocommerce a.button:hover, .pt-site .woocommerce button.button:hover, .pt-site .woocommerce input.button:hover { background: var(--pt-surface-2); color: var(--pt-text); }
.pt-site .woocommerce a.button.alt, .pt-site .woocommerce button.button.alt, .pt-site .woocommerce input.button.alt, .pt-site .woocommerce #payment #place_order { background: var(--pt-orange-600); border-color: var(--pt-orange-600); color: #fff; padding: 13px 22px; font-size: 15px; }
.pt-site .woocommerce a.button.alt:hover, .pt-site .woocommerce button.button.alt:hover, .pt-site .woocommerce input.button.alt:hover, .pt-site .woocommerce #payment #place_order:hover { background: var(--pt-orange-700); border-color: var(--pt-orange-700); color: #fff; }
.pt-site .woocommerce button.button:disabled, .pt-site .woocommerce button.button:disabled[disabled] { padding: 10px 18px; color: var(--pt-muted); opacity: .6; }

/* WooCommerce: tables (orders, one order, cart, order summary) */
.pt-site .woocommerce table.shop_table { border: 1px solid var(--pt-border); border-radius: var(--pt-radius); border-collapse: separate; border-spacing: 0; overflow: hidden; background: var(--pt-surface); box-shadow: var(--pt-shadow); font-size: 15px; margin: 0 0 24px; }
.pt-site .woocommerce table.shop_table th, .pt-site .woocommerce table.shop_table td { padding: 12px 14px; border-top: 1px solid var(--pt-border); vertical-align: middle; }
.pt-site .woocommerce table.shop_table thead th { border-top: 0; background: var(--pt-surface-2); font-size: 13px; }
.pt-site .woocommerce table.shop_table a:not(.button) { color: var(--pt-text); font-weight: 600; }
.pt-site .woocommerce mark { background: none; color: inherit; font-weight: 700; }
.pt-site .woocommerce h2, .pt-site .woocommerce h3 { font-size: 20px; letter-spacing: -.02em; margin: 0 0 12px; }
.pt-site .woocommerce .woocommerce-customer-details address { border: 1px solid var(--pt-border); border-radius: var(--pt-radius); background: var(--pt-surface); padding: 14px; }
.pt-site .woocommerce .cart_totals, .pt-site .woocommerce-checkout-review-order { font-size: 15px; }
.pt-site .woocommerce a.remove { color: var(--pt-muted) !important; }
.pt-site .woocommerce a.remove:hover { background: var(--pt-orange-600); color: #fff !important; }

/* WooCommerce: form fields (cart, checkout) */
.pt-site .woocommerce form .form-row label { font-size: var(--pt-text-sm); font-weight: 600; margin-bottom: 6px; line-height: 1.4; }
.pt-site .woocommerce form .form-row input.input-text, .pt-site .woocommerce form .form-row textarea, .pt-site .woocommerce form .form-row select, .pt-site .woocommerce .quantity .qty, .pt-site .woocommerce table.cart td.actions .coupon .input-text {
	min-height: 44px; padding: 10px 12px; border: 1px solid var(--pt-border); border-radius: var(--pt-radius-sm); font: inherit; background: var(--pt-surface); color: var(--pt-text);
}
.pt-site .woocommerce form .form-row input.input-text:focus, .pt-site .woocommerce form .form-row textarea:focus { outline: 0; border-color: var(--pt-navy); box-shadow: 0 0 0 3px var(--pt-navy-50); }
.pt-site .woocommerce .quantity .qty { width: 76px; }
.pt-site .woocommerce table.cart td.actions .coupon .input-text { width: 170px; margin-right: 8px; }
.pt-site .woocommerce form.checkout_coupon, .pt-site .woocommerce form.login { border: 1px solid var(--pt-border); border-radius: var(--pt-radius); background: var(--pt-surface); }

/* WooCommerce: notices and the payment box */
.pt-site .woocommerce-info, .pt-site .woocommerce-message, .pt-site .woocommerce-error { border-top: 0; border-left: 4px solid var(--pt-navy); border-radius: var(--pt-radius-sm); background: var(--pt-surface); color: var(--pt-text); box-shadow: var(--pt-shadow); }
.pt-site .woocommerce-info::before { color: var(--pt-navy); }
.pt-site .woocommerce-message { border-left-color: var(--pt-ok); }
.pt-site .woocommerce-message::before { color: var(--pt-ok); }
.pt-site .woocommerce-error { border-left-color: #b4233c; }
.pt-site .woocommerce-info a, .pt-site .woocommerce-message a { color: var(--pt-link); }
.pt-site .woocommerce #payment { background: var(--pt-surface-2); border-radius: var(--pt-radius); }
.pt-site .woocommerce #payment div.payment_box { background: var(--pt-surface); color: var(--pt-text); border-radius: var(--pt-radius-sm); }
.pt-site .woocommerce #payment div.payment_box::before { border-bottom-color: var(--pt-surface); }
.pt-site .woocommerce #payment ul.payment_methods { border-bottom-color: var(--pt-border); }

@media (max-width: 47.99em) {
	/* Stacked table rows: one row is one block with a single line under it */
	.pt-site .hp-table.hp-table--stack, .pt-site .hp-table.hp-table--stack tbody { display: block; }
	.pt-site .hp-table.hp-table--stack tr { align-items: center; gap: 6px 12px; padding: 12px 14px; border-bottom: 1px solid var(--pt-border); }
	.pt-site .hp-table.hp-table--stack tr:last-child { border-bottom: 0; }
	.pt-site .hp-table.hp-table--stack td, .pt-site .hp-table.hp-table--stack th, .pt-site .hp-table.hp-table--stack td:not(:first-child):not(:last-child) { width: auto; padding: 0; border: 0; }

	/* Poruke: sender and time on one line, the ad under them */
	.pt-site .hp-messages, .pt-site .hp-messages tbody { display: block; overflow: visible; }
	.pt-site .hp-messages tr { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: 4px 12px; padding: 12px 14px; border-bottom: 1px solid var(--pt-border); }
	.pt-site .hp-messages tr:last-child { border-bottom: 0; }
	.pt-site .hp-messages td { display: block; padding: 0; border: 0; }
	.pt-site .hp-messages .hp-message__listing { grid-column: 1 / -1; grid-row: 2; }

	/* The chips sit close to the page title */
	.hp-template--user-account-page .hp-page__sidebar, .pt-account-page .hp-page__sidebar { margin-bottom: 0; }

	/* Arrows and fading edges on the row of chips (added by account.js), as on the row of trades */
	.pt-acctrail { position: relative; }
	.pt-acctrail ul { scroll-behavior: smooth; }
	.pt-acctrail::before, .pt-acctrail::after { content: ""; position: absolute; top: 1px; bottom: 1px; width: 64px; pointer-events: none; opacity: 0; transition: opacity .15s; z-index: 1; }
	.pt-acctrail::before { left: 1px; border-radius: var(--pt-radius) 0 0 var(--pt-radius); background: linear-gradient(90deg, var(--pt-surface) 45%, transparent); }
	.pt-acctrail::after { right: 1px; border-radius: 0 var(--pt-radius) var(--pt-radius) 0; background: linear-gradient(270deg, var(--pt-surface) 45%, transparent); }
	.pt-acctrail--start::before, .pt-acctrail--end::after { opacity: 1; }
	.pt-acctrail__btn { position: absolute; top: 50%; z-index: 2; width: 34px; height: 34px; margin-top: -17px; display: grid; place-items: center; padding: 0; border: 1px solid var(--pt-border); border-radius: 50%; background: var(--pt-surface); color: var(--pt-navy); box-shadow: var(--pt-shadow); cursor: pointer; }
	.pt-acctrail__btn[hidden] { display: none; }
	.pt-acctrail__btn .pt-icon { width: 18px; height: 18px; }
	.pt-acctrail__btn--prev { left: 6px; }
	.pt-acctrail__btn--next { right: 6px; }

	/* WooCommerce account pages get the same chips as HivePress's */
	.pt-account-page .hp-button--user-account-menu { display: none !important; }
	.pt-account-page .hp-widget--user-account-menu, .pt-account-page #user_account_menu_modal { display: block !important; }

	/* Orders: each order is a block that starts with its number */
	.pt-site .woocommerce table.shop_table_responsive tbody tr { display: block; border-top: 1px solid var(--pt-border); }
	.pt-site .woocommerce table.shop_table_responsive tbody tr:first-child { border-top: 0; }
	.pt-site .woocommerce table.shop_table_responsive tbody th { display: block; border: 0; padding: 12px 14px 4px; }
	.pt-site .woocommerce table.shop_table_responsive tbody td { border: 0; padding: 6px 14px; background: none; }
	.pt-site .woocommerce table.shop_table_responsive tbody td:last-child { padding-bottom: 12px; }
	.pt-site .woocommerce table.cart td.actions .coupon .input-text { width: 100%; margin: 0 0 8px; }
}

/* The package step of the posting form (and "Paketi i cijene"): each package as a card, like
   the price cards on "Za poslodavce". HivePress's markup; the texts come from the packages. */
.hp-template--listing-submit-package-page .hp-row, .hp-listing-packages .hp-row { align-items: stretch; }
.hp-listing-package--view-block { display: flex; flex-direction: column; height: 100%; text-align: left; background: var(--pt-surface); border: 1px solid var(--pt-border); border-radius: var(--pt-radius); box-shadow: var(--pt-shadow); padding: 22px 20px 20px; margin-bottom: 16px; }
.hp-listing-package--view-block .hp-listing-package__header { margin: 0 0 12px; padding: 0; text-align: left; }
.hp-listing-package--view-block .hp-listing-package__name { margin: 0 0 8px; font-size: 17px; text-align: left; }
.hp-listing-package--view-block .hp-listing-package__price { font-size: 34px; font-weight: 800; letter-spacing: -.03em; line-height: 1; color: var(--pt-text); text-align: left; }
.hp-listing-package--view-block .hp-listing-package__content { flex: 1; margin: 0 0 18px; }
.hp-listing-package--view-block .hp-listing-package__description p { margin: 0 0 12px; color: var(--pt-muted); font-size: 13.5px; text-align: left; }
.hp-listing-package--view-block .hp-listing-package__description ul { list-style: none; margin: 0; padding: 0; }
.hp-listing-package--view-block .hp-listing-package__description li { position: relative; padding-left: 26px; margin-bottom: 8px; font-size: 14.5px; }
.hp-listing-package--view-block .hp-listing-package__description li::before { content: ""; position: absolute; left: 3px; top: 5px; width: 11px; height: 6px; border-left: 2px solid var(--pt-ok); border-bottom: 2px solid var(--pt-ok); transform: rotate(-45deg); }
.hp-listing-package--view-block .hp-listing-package__footer { margin: 0; padding: 0; }
.hp-listing-package--view-block .hp-listing-package__button { width: 100%; }
