/* ==========================================================================
   uz-order.css — widok zamówienia: strona podziękowania (order-received) i zamówienie w Moim koncie.

   Wydzielone z account.css (sekcja 6). account.css ładuje się tylko na stronach konta, więc po
   złożeniu zamówienia (strona „Dziękujemy”, to nie strona konta) te style nie docierały i nagłówek
   „Szczegóły zamówienia” zostawał z jasnym tłem Astry pod białym tekstem. Ładowane w functions.php (sekcja 21).
   ========================================================================== */

/* ==========================================================================
   STRONA PODZIĘKOWANIA (THANK YOU PAGE) i WIDOK ZAMÓWIENIA
   ========================================================================== */

.woocommerce-order-details header, 
.woocommerce-customer-details header,
.woocommerce-order-details mark,
.woocommerce-customer-details mark {
    background: transparent !important;
    padding: 0 !important;
    margin: 0 !important;
}

.woocommerce-order-details, 
.woocommerce-customer-details,
.woocommerce-order-overview {
    background: #0c0c0c !important; 
    border: 1px solid #333 !important;
    border-left: 6px solid #7c28d5 !important; 
    padding: 30px !important;
    border-radius: 15px !important;
    box-shadow: 0 10px 30px rgba(0,0,0,0.8) !important;
    margin-bottom: 30px !important;
    color: #fff !important;
}

.woocommerce-order-overview {
    display: flex !important;
    justify-content: space-between !important;
    flex-wrap: wrap !important;
    list-style: none !important;
    border-left: 6px solid #5cde26 !important; 
}

.woocommerce-order-overview li {
    text-transform: uppercase !important;
    font-size: 11px !important;
    color: #888 !important;
    font-weight: 800 !important;
    letter-spacing: 1px !important;
}

.woocommerce-order-overview li strong {
    display: block !important;
    color: #5cde26 !important; 
    font-size: 18px !important;
    text-shadow: 0 0 10px rgba(92, 222, 38, 0.4) !important;
}

.woocommerce-order-details__title, 
.woocommerce-column__title,
.woocommerce-customer-details h2 {
    font-family: 'Sora', sans-serif !important;
    font-size: 24px !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    color: #fff !important;
    margin-bottom: 25px !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
}

.woocommerce-table--order-details {
    background: transparent !important;
    border: none !important;
}

.woocommerce-table--order-details thead th {
    background: #1a1a1a !important;
    color: #5cde26 !important;
    text-transform: uppercase !important;
    font-size: 12px !important;
}

.woocommerce-table--order-details td, 
.woocommerce-table--order-details th {
    border-top: 1px solid #222 !important;
    padding: 15px !important;
    color: #ccc !important;
}

.woocommerce-customer-details address {
    background: #111 !important;
    border: 1px solid #222 !important;
    color: #aaa !important;
    padding: 20px !important;
    border-radius: 10px !important;
    font-style: normal !important;
    text-transform: uppercase !important;
}

.woocommerce-table--order-details tfoot td span.woocommerce-Price-amount {
    color: #5cde26 !important;
    font-weight: 900 !important;
}

/* --------------------------------------------------------------------------
   Przyciski w wierszu „Działania” (Zapłać / Anuluj)

   To dwa zwykłe linki .order-actions-button bez własnego wyglądu — zlewały się w jeden blok.
   Zieleń tylko dla płatności (akcja końcowa), „Anuluj” neutralny.
   -------------------------------------------------------------------------- */
a.order-actions-button {
	display: inline-block !important;
	padding: 12px 24px !important;
	border-radius: 10px !important;
	font-size: 14px !important;
	font-weight: 800 !important;
	line-height: 1.2 !important;
	text-decoration: none !important;
	text-transform: none !important;
	box-shadow: none !important;
	cursor: pointer;
	transition: filter .15s, border-color .15s, color .15s;
}
a.order-actions-button + a.order-actions-button { margin-left: 10px !important; }

a.order-actions-button.pay {
	background: #5cde26 !important;
	border: 1px solid #5cde26 !important;
	color: #07230a !important;
}
a.order-actions-button.pay:hover,
a.order-actions-button.pay:focus { filter: brightness(1.08); }

a.order-actions-button.cancel {
	background: transparent !important;
	border: 1px solid #444 !important;
	color: #ccc !important;
}
a.order-actions-button.cancel:hover,
a.order-actions-button.cancel:focus { border-color: #8b5cf6 !important; color: #fff !important; }


/* ==========================================================================
   MOJE KONTO — ZAMÓWIENIA (lista i widok zamówienia)

   Wcześniej lista zamówień była surową tabelą Astry: białe obramowania, biały nagłówek pod białym tekstem,
   niebieskie linki i zielone, rozciągnięte przyciski. Tu ujednolicone z resztą sklepu: ciemne karty,
   fiolet jako akcent, zieleń tylko dla płatności („Zapłać”).
   ========================================================================== */

/* Nagłówek podstrony konta (np. „Zamówienia”) — domyślnie granatowy na czarnym tle. */
body.woocommerce-account .entry-title,
body.woocommerce-account h1.entry-title { color: #fff !important; }

/* --- Komunikat „Potwierdź adres email” (WooCommerce pokazuje go przy starszych zamówieniach na ten sam adres) --- */
body.woocommerce-account .woocommerce-MyAccount-content .woocommerce-info {
	padding: 16px 20px 16px 56px !important;
	text-transform: none !important;
	font-weight: 500 !important;
	font-size: 13px !important;
	line-height: 1.55 !important;
	color: #d4d4da !important;
	margin-bottom: 20px !important;
}
body.woocommerce-account .woocommerce-MyAccount-content .woocommerce-info .button {
	float: none !important;
	display: inline-block !important;
	width: auto !important;
	margin: 0 14px 6px 0 !important;
	padding: 8px 14px !important;
	background: transparent !important;
	border: 1px solid #8b5cf6 !important;
	border-radius: 10px !important;
	color: #fff !important;
	font-size: 12px !important;
	font-weight: 700 !important;
	letter-spacing: 0 !important;
	text-transform: none !important;
	box-shadow: none !important;
}
body.woocommerce-account .woocommerce-MyAccount-content .woocommerce-info .button:hover { background: #8b5cf6 !important; }

/* --- Lista zamówień --- */
body.woocommerce-account table.woocommerce-orders-table {
	width: 100% !important;
	border-collapse: separate !important;
	border-spacing: 0 !important;
	background: #0c0c0c !important;
	border: 1px solid #2c2c33 !important;
	border-radius: 16px !important;
	overflow: hidden;
	margin: 0 0 24px !important;
	color: #d4d4da !important;
}
body.woocommerce-account table.woocommerce-orders-table thead th {
	background: #17171a !important;
	color: #9a9aa6 !important;
	font-size: 11px !important;
	font-weight: 700 !important;
	letter-spacing: 1px !important;
	text-transform: uppercase !important;
	text-align: left !important;
	padding: 14px 18px !important;
	border: 0 !important;
	border-bottom: 1px solid #2c2c33 !important;
}
body.woocommerce-account table.woocommerce-orders-table tbody th,
body.woocommerce-account table.woocommerce-orders-table tbody td {
	background: transparent !important;
	border: 0 !important;
	border-top: 1px solid #222 !important;
	padding: 16px 18px !important;
	color: #d4d4da !important;
	font-size: 14px !important;
	font-weight: 400 !important;
	text-align: left !important;
	vertical-align: middle !important;
}
body.woocommerce-account table.woocommerce-orders-table tbody tr:first-child > * { border-top: 0 !important; }
body.woocommerce-account table.woocommerce-orders-table tbody tr:hover > * { background: #131316 !important; }

body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-number a {
	color: #a78bfa !important;
	font-weight: 800 !important;
	text-decoration: none !important;
}
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-number a:hover { color: #fff !important; }

body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-date { white-space: nowrap !important; }

/* Kropka statusu przy tekście */
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-status::before {
	content: "";
	display: inline-block;
	width: 8px; height: 8px;
	border-radius: 50%;
	margin-right: 8px;
	background: #9a9aa6;
}
body.woocommerce-account .woocommerce-orders-table__row--status-processing .woocommerce-orders-table__cell-order-status::before { background: #8b5cf6; }
body.woocommerce-account .woocommerce-orders-table__row--status-on-hold .woocommerce-orders-table__cell-order-status::before,
body.woocommerce-account .woocommerce-orders-table__row--status-pending .woocommerce-orders-table__cell-order-status::before { background: #ffb020; }
body.woocommerce-account .woocommerce-orders-table__row--status-cancelled .woocommerce-orders-table__cell-order-status::before,
body.woocommerce-account .woocommerce-orders-table__row--status-failed .woocommerce-orders-table__cell-order-status::before,
body.woocommerce-account .woocommerce-orders-table__row--status-refunded .woocommerce-orders-table__cell-order-status::before { background: #ef4444; }
body.woocommerce-account .woocommerce-orders-table__row--status-completed .woocommerce-orders-table__cell-order-status::before { background: #e5e5ea; }

/* Przyciski: „Zobacz” fioletowy kontur, „Zapłać” zielony, „Anuluj” szary */
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions .button {
	display: inline-block !important;
	margin: 4px 10px 4px 0 !important;
	padding: 9px 16px !important;
	background: transparent !important;
	border: 1px solid #8b5cf6 !important;
	border-radius: 10px !important;
	color: #fff !important;
	font-size: 13px !important;
	font-weight: 700 !important;
	line-height: 1.2 !important;
	letter-spacing: 0 !important;
	text-transform: none !important;
	text-decoration: none !important;
	box-shadow: none !important;
	width: auto !important;
	transition: background .15s, filter .15s;
}
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions .button:hover { background: #8b5cf6 !important; }
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions .button.pay {
	background: #5cde26 !important; border-color: #5cde26 !important; color: #07230a !important;
}
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions .button.pay:hover { filter: brightness(1.08); background: #5cde26 !important; }
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions .button.cancel { border-color: #444 !important; color: #ccc !important; }
body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions .button.cancel:hover { background: transparent !important; border-color: #ef4444 !important; color: #ef4444 !important; }

/* Stronicowanie listy („Poprzednie / Następne”) */
body.woocommerce-account .woocommerce-pagination .button {
	background: transparent !important; border: 1px solid #8b5cf6 !important; border-radius: 10px !important;
	color: #fff !important; text-transform: none !important; letter-spacing: 0 !important; box-shadow: none !important;
}

/* --- Widok pojedynczego zamówienia --- */
body.woocommerce-account .woocommerce-table--order-details th,
body.woocommerce-account .woocommerce-table--order-details td {
	border-left: 0 !important;
	border-right: 0 !important;
	border-bottom: 0 !important;
}
body.woocommerce-account .woocommerce-table--order-details td.product-name a {
	color: #fff !important; font-weight: 700 !important; text-decoration: none !important;
}
body.woocommerce-account .woocommerce-table--order-details td.product-name a:hover { color: #a78bfa !important; }
body.woocommerce-account .woocommerce-table--order-details td.product-name .product-quantity { color: #9a9aa6 !important; }
body.woocommerce-account .woocommerce-table--order-details thead th { color: #9a9aa6 !important; }
body .woocommerce-customer-details address {
	font-size: 13px !important;
	line-height: 1.7 !important;
}
body.woocommerce-account .woocommerce-MyAccount-content mark { background: transparent !important; color: #a78bfa !important; }

/* --- Telefon: wiersze tabeli jako karty --- */
@media (max-width: 768px) {
	body.woocommerce-account table.woocommerce-orders-table thead { display: none !important; }
	body.woocommerce-account table.woocommerce-orders-table,
	body.woocommerce-account table.woocommerce-orders-table tbody { display: block !important; background: transparent !important; border: 0 !important; }
	body.woocommerce-account table.woocommerce-orders-table tr {
		display: block !important;
		background: #0c0c0c !important;
		border: 1px solid #2c2c33 !important;
		border-radius: 16px !important;
		margin: 0 0 14px !important;
		padding: 6px 0 !important;
	}
	body.woocommerce-account table.woocommerce-orders-table tbody th,
	body.woocommerce-account table.woocommerce-orders-table tbody td {
		display: flex !important;
		justify-content: space-between !important;
		align-items: center !important;
		gap: 16px;
		border-top: 0 !important;
		padding: 10px 16px !important;
		text-align: right !important;
	}
	body.woocommerce-account table.woocommerce-orders-table tbody tr:hover > * { background: transparent !important; }
	body.woocommerce-account table.woocommerce-orders-table tbody th::before,
	body.woocommerce-account table.woocommerce-orders-table tbody td::before {
		content: attr(data-title) !important;
		float: none !important;
		color: #9a9aa6;
		font-size: 11px;
		font-weight: 700;
		letter-spacing: 1px;
		text-transform: uppercase;
		text-align: left;
	}
	/* kwota z dopiskiem „za 1 pozycję” — jeden blok, żeby tekst nie rozjeżdżał się we flexie */
	body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-total { display: block !important; }
	body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-total::before { float: left !important; }
	/* w widoku kart etykieta zastępuje kropkę statusu */
	body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-status::before { width: auto; height: auto; border-radius: 0; margin: 0; background: none !important; }
	body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions { justify-content: flex-start !important; }
	body.woocommerce-account table.woocommerce-orders-table .woocommerce-orders-table__cell-order-actions::before { display: none !important; }
}

/* ==========================================================================
   TELEFON — strona podziękowania i zamówienie w koncie (bez rozjeżdżania i bez wystawania poza ekran)
   ========================================================================== */
@media (max-width: 600px) {
	.woocommerce-order-details,
	.woocommerce-customer-details,
	.woocommerce-order-overview {
		padding: 22px 16px !important;
		box-sizing: border-box !important;
	}
	.woocommerce-order-details__title,
	.woocommerce-column__title,
	.woocommerce-customer-details h2 { font-size: 20px !important; margin-bottom: 16px !important; }

	/* podsumowanie na górze: jedna kolumna, bez kropkowanych kresek i schodków */
	.woocommerce-order-overview { display: block !important; }
	.woocommerce-order-overview li {
		float: none !important;
		display: block !important;
		margin: 0 0 14px !important;
		padding: 0 !important;
		border: 0 !important;
	}
	.woocommerce-order-overview li:last-child { margin-bottom: 0 !important; }
	.woocommerce-order-overview li strong { margin-top: 2px !important; overflow-wrap: anywhere; }

	/* tabela pozycji: bez dużego lewego marginesu, zawijanie zamiast wystawania */
	.woocommerce-table--order-details th,
	.woocommerce-table--order-details td {
		padding: 12px 0 !important;
		overflow-wrap: anywhere;
		white-space: normal !important;
		vertical-align: top !important;
	}
	.woocommerce-table--order-details td.product-name { padding-left: 0 !important; padding-right: 12px !important; }
	.woocommerce-table--order-details thead th.product-total,
	.woocommerce-table--order-details td.product-total { width: 1% !important; padding-left: 8px !important; white-space: nowrap !important; text-align: right !important; }
	.woocommerce-table--order-details thead th.product-name { width: auto !important; }
	.woocommerce-table--order-details tfoot th { padding-right: 12px !important; }
	.woocommerce-table--order-details tfoot td { text-align: right !important; overflow-wrap: normal !important; }
	.woocommerce-table--order-details tfoot .woocommerce-Price-amount { white-space: nowrap !important; }
	.woocommerce-table--order-details tfoot .shipped_via { display: block; font-size: 12px; color: #9a9aa6; }
	.woocommerce-table--order-details tfoot a.button,
	.woocommerce-table--order-details tfoot .button {
		max-width: 100% !important;
		box-sizing: border-box !important;
		white-space: normal !important;
		text-align: center !important;
	}
}
